From: Ben Key <bkey76@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Read-only warning message
Date: Sat, 28 May 2011 06:04:29 -0500 [thread overview]
Message-ID: <BANLkTimvQ5o-VVMBkJPFawoLqiUrWELkbg@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1452 bytes --]
Hello,
sdn.gnuem@mailnull.com writes:
> When you make a buffer read-only (via C-x C-q toggle-read-only), and the
file
> in the buffer is under version control, you get a warning message: "File
is
> under version-control; use C-x v v to check in/out".
> Anyone have any idea why?
I can see one possible reason for this warning message. Some version
control systems, Perforce is one example, set all files that are under
version control read only by default. If you want to modify a given file,
you are supposed to Check Out or Open the File For Edit first. When you use
this command, it toggles the read only state of the file off. When you are
done with the file you are supposed to submit the change.
Perforce, unlike Subversion and Bazaar, by default does not automatically
notice files that you have modified on disk. It only knows about files you
have first checked out. So, if you manually toggle the read only state of
the file off, Perforce has absolutely no idea that it has changed; the
submit command will only submit files you first checked out with the edit
command. Thus, by manually toggling the read only state of the file you run
the risk of confusing any version control systems that work like this, and,
as a result, changes you made may not be submitted as you expect.
This possibility is most likely what lead to the warning message being
added.
I hope this information helps.
Note: I happen to use Perforce at work.
[-- Attachment #2: Type: text/html, Size: 1616 bytes --]
next reply other threads:[~2011-05-28 11:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-28 11:04 Ben Key [this message]
-- strict thread matches above, loose matches on Subject: below --
2011-05-17 17:34 Read-only warning message sdn.gnuem
2011-05-17 18:30 ` Memnon Anon
2011-05-17 19:06 ` Perry Smith
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=BANLkTimvQ5o-VVMBkJPFawoLqiUrWELkbg@mail.gmail.com \
--to=bkey76@gmail.com \
--cc=help-gnu-emacs@gnu.org \
/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).