Showing posts with label vcs. Show all posts
Showing posts with label vcs. Show all posts

Sunday, February 24, 2008

Vim and Perforce

My employer has used Perforce as a VCS for several years now. Perforce itself maintains integration plugins for Eclipse, but of course not for editors like Vim so it's up to the community to do so. Lucky for me, extremely capable Vim scripters like Hari Krishna Dara also use Perforce from time to time :). This is the same author who brought us the genutils.vim plugin as well as many other powerful scripts as his vim profile lists. Among these is a fantastic perforce script set that I downloaded to try about a week ago. It was more than I'd hoped for.

This is a very featureful Perforce integration script with a complete set of menus (although I have menus hidden in my vim) and commands. I'm not sure whether the author still uses it or not however because there was a bug in spec-based commands that broke it pretty badly. Of course, there is the possibility that I'm using it incorrectly too. Regardless, I've "fixed" a couple of these bugs and emailed the author with a patch. I also uncovered a bug in the genutils.vim script that it depends on. The author also mentions this in the script page for the Perforce plugin:

--------------------------------------------------------------------------------
Lately, I am not finding enough time to add features to this, so if anybody is
interested to help me add new features or even take over the responsibility, you
are very much welcome.
--------------------------------------------------------------------------------

Although I sent him a small patch in his Inbox, he may not have the time to make a bug fix release, so I've made a little bazaar branch of the complete script on my own little server here for the time being. This branch includes the fixes for a couple of little bugs, and some extra syntax hinting for pending changelists and closed jobs. Aside from that, it's unaltered. You can get it using this command, assuming you have bzr installed.

$ bzr branch http://arker.homelinux.org/~dcraven/bazaar/vim-perforce vim-perforce

I might add a few features or commands that have been included in the p4 client since his last release of the script at some point too. Depending on his email reply (if he replies) we'll see if he'd like my changes included in his next release or not. My additions unfortunately won't be of the same quality as the stuff he's already written. I'm not exactly a seasoned vim-scriptor...

All in all, it's a fantastic script. Check it out if you use Vim with the Perforce VCS, and big kudos and thanks go out to the original author!

Wednesday, December 20, 2006

Now Using Bazaar for a VCS

In order to hang with the cool crowd, I've decided to fall for the hype and jump ship (at least for now) to a distributed version control system. The one I've chosen is bazaar, mostly because it's written purely in Python. I like playing with new things from time to time, and bazaar commands are a pretty smooth transition from their Subversion equivalents.

So, in order to get the latest and greatest unreleased code for td or vim-blogger, you can use bazaar and grab the source from here and here respectively.

If need a quick learning reference, have a look at the bazaar tutorial. It seems the User Manual link on the website points to the tutorial as well.. Hmm. To find out more about the program, the official website can be found here.