Re: Linux 2.4 and BitKeeper

Andreas Dilger (adilger@clusterfs.com)
Fri, 15 Mar 2002 18:02:36 -0700


On Mar 16, 2002 01:31 +0100, Andreas Ferber wrote:
> I'm certainly not a "vim genius", but somehow I managed to write some
> vim autocmds that do this ;-)
>
> You can get the vim script from
>
> http://www.myipv6.de/vim/extensions/bk.vim
>
> Simply source it from your .vimrc. I tested it with vim 6.0 only,
> although it should also work with prior versions.
>
> On open, it tries to checkout a file from bitkeeper if it isn't
> already checked out (doing "bk get" if you open it readonly and "bk
> edit" otherwise), and it "bk edit"s the file if you start making
> changes to a readonly bitkeeper controlled file.
>
> Unfortunately, vim doesn't trigger the FileChangedRO autocmd if you do
> a ":set readonly!" to go from readonly to read/write, so it doesn't
> handle this case (AFAIK there is no way to intercept this command).

Well, you shouldn't be going from read-write to readonly in this way
anyways, so I don't think it is a problem.

Cheers, Andreas

--
Andreas Dilger  \ "If a man ate a pound of pasta and a pound of antipasto,
                 \  would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/               -- Dogbert

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/