From: "François Fleuret" <francois.fleuret@noos.fr>
Subject: Re: How to test if a directory is under version control ?
Date: 06 Nov 2003 12:30:59 +0100 [thread overview]
Message-ID: <87znf991jg.fsf@noos.fr> (raw)
In-Reply-To: jwvy8uudid4.fsf-monnier+gnu.emacs.help@vor.iro.umontreal.ca
Hi,
Stefan Monnier wrote on 05 Nov 2003 15:15:07 MET:
> VC has two related operations: `responsible-p' and `could-register'.
> [ ... snip snip ...]
Thanks Stefan.
I finally wrote the following:
>> ;; This function displays an alarm if the file we are editing is not
>> ;; under CVS while the directory is.
>>
>> (require 'vc-cvs)
>>
>> (defun check-under-cvs ()
>> (when (and buffer-file-name
>> (not (vc-cvs-registered buffer-file-name))
>> (vc-cvs-responsible-p buffer-file-name))
>> (message "*Warning* %s is not under CVS" buffer-file-name)
>> ))
>>
>> (add-hook 'find-file-hooks 'check-under-cvs)
Which seems to work fine.
Regards,
--
François Fleuret
prev parent reply other threads:[~2003-11-06 11:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-05 12:11 How to test if a directory is under version control ? François Fleuret
2003-11-05 14:15 ` Stefan Monnier
2003-11-06 11:30 ` François Fleuret [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87znf991jg.fsf@noos.fr \
--to=francois.fleuret@noos.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).