unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Luc Teirlinck <teirllm@dms.auburn.edu>
Cc: abraham@dina.kvl.dk, emacs-devel@gnu.org
Subject: Re: Defcustom write-file-functions and write-contents-functions?
Date: Tue, 6 Jan 2004 21:03:54 -0600 (CST)	[thread overview]
Message-ID: <200401070303.i0733sc09973@raven.dms.auburn.edu> (raw)
In-Reply-To: <200401070207.i0727vh09877@raven.dms.auburn.edu> (message from Luc Teirlinck on Tue, 6 Jan 2004 20:07:57 -0600 (CST))

Avtually, in my previous files.texi diff, I forgot to make a relevant
change: make the defvar's for `before-save-hook' and `after-save-hook'
into defopt's:

===File ~/files.texi-newdiff================================
*** files.texi.~1.60.~	Mon Jan  5 12:46:02 2004
--- files.texi	Tue Jan  6 20:50:23 2004
***************
*** 404,428 ****
  This works just like @code{write-file-functions}, but it is intended for
  hooks that pertain to the contents of the file, as opposed to hooks that
  pertain to where the file came from.  Such hooks are usually set up by
! major modes, as buffer-local bindings for this variable.
  
  This variable automatically becomes buffer-local whenever it is set;
! switching to a new major mode always resets this variable.
  @end defvar
  
! @defvar before-save-hook
! This normal hook runs before a buffer has been saved in its visited
! file.  One use of this hook is for the Copyright package; it uses this
! hook to make sure the file has the current year in the copyright
! header.
! @end defvar
  
  @c Emacs 19 feature
! @defvar after-save-hook
  This normal hook runs after a buffer has been saved in its visited file.
  One use of this hook is in Fast Lock mode; it uses this hook to save the
  highlighting information in a cache file.
! @end defvar
  
  @defvar file-precious-flag
  If this variable is non-@code{nil}, then @code{save-buffer} protects
--- 404,432 ----
  This works just like @code{write-file-functions}, but it is intended for
  hooks that pertain to the contents of the file, as opposed to hooks that
  pertain to where the file came from.  Such hooks are usually set up by
! major modes, as buffer-local bindings for this variable.  If any of the
! functions in this hook returns non-@code{nil}, @code{write-file-functions}
! is not run.
  
  This variable automatically becomes buffer-local whenever it is set;
! switching to a new major mode always resets this variable, but
! calling @code{set-visited-file-name} does not.
  @end defvar
  
! @defopt before-save-hook
! This normal hook runs before a buffer is saved in its visited file,
! regardless of whether that is done normally or by one of the hooks
! described above.  One use of this hook is for the Copyright package;
! it uses this hook to make sure the file has the current year in the
! copyright header.
! @end defopt
  
  @c Emacs 19 feature
! @defopt after-save-hook
  This normal hook runs after a buffer has been saved in its visited file.
  One use of this hook is in Fast Lock mode; it uses this hook to save the
  highlighting information in a cache file.
! @end defopt
  
  @defvar file-precious-flag
  If this variable is non-@code{nil}, then @code{save-buffer} protects
============================================================

  reply	other threads:[~2004-01-07  3:03 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-31 14:38 Defcustom write-file-functions and write-contents-functions? Simon Josefsson
2003-12-31 16:57 ` Luc Teirlinck
2003-12-31 17:26   ` Simon Josefsson
2003-12-31 19:27     ` Luc Teirlinck
2003-12-31 19:56       ` Simon Josefsson
2003-12-31 20:10         ` Luc Teirlinck
2004-01-01  5:52         ` Eli Zaretskii
2004-01-01 12:22           ` Simon Josefsson
2004-01-01 14:45             ` Eli Zaretskii
2004-01-04 23:33         ` Stefan Monnier
2004-01-05  0:14           ` Luc Teirlinck
2004-01-05  0:31             ` Miles Bader
2004-01-05  0:46           ` Simon Josefsson
2004-01-05 17:56             ` Richard Stallman
2004-01-05 18:38               ` Simon Josefsson
2004-01-04 14:54   ` Per Abrahamsen
2004-01-05  4:41     ` Luc Teirlinck
2004-01-07  2:07     ` Luc Teirlinck
2004-01-07  3:03       ` Luc Teirlinck [this message]
2004-01-07 15:05       ` Richard Stallman

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=200401070303.i0733sc09973@raven.dms.auburn.edu \
    --to=teirllm@dms.auburn.edu \
    --cc=abraham@dina.kvl.dk \
    --cc=emacs-devel@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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).