bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: alert user the NEWS file has changed


From: Dan Jacobson
Subject: Re: alert user the NEWS file has changed
Date: Fri, 25 Apr 2003 05:39:23 +0800
User-agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.2 (i386-pc-linux-gnu)

Marco sent this to me.  As it has a spam status rating of -37.7, it
must be good stuff.  Hence I will share it here. 

--- Begin Message --- Date: 23 Apr 2003 14:32:37 +0200
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dan Jacobson <address@hidden> writes:

> >> There should be a device to make sure the user knows the NEWS file
> >> has changed, saving a timestamp in his .emacs.

[...]

> Hmmm, I bet if I make the NEWS file one of the mailboxes tracked by
> gnus, that would be an interesting way of being aware if it changed...

[...]

You can download checkurls [1] version 0.5.0-alpha1 [2] [3], install
it, and put the following in your ~/.emacs:

  (shell-command "checkurl 
file_in_subdir_n_from_the_end:///usr/local/share/emacs:2:etc/NEWS &" 
"*checkurl*")

or

   checkurl file_in_subdir_n_from_the_end:///usr/local/share/emacs:2:etc/NEWS

in your ~/.profile.

This may send you and email a) the first time you run it, with the
full NEWS file, and b) each time you run it and the file is changed,
with a the differences from the previous version.

See `info checkurls' and `info checkurl' for more infos.

The URL can change depending on where you installed Emacs.

file_in_subdir_n_from_the_end://PATH:N:PATH2

This means the PATH2 file in the Nth subdir (counting from the end) in
the PATH directory.

So if you have

   address@hidden:~/web/marc0$ ls /usr/local/share/emacs/
   21.3.50  site-lisp
   address@hidden:~/web/marc0$ 

then

   file_in_subdir_n_from_the_end:///usr/local/share/emacs:2:etc/NEWS

will expand to

   /usr/local/share/emacs/21.3.50/etc/NEWS

And then in the future if you have

   address@hidden:~/web/marc0$ ls /usr/local/share/emacs/
   21.3.50  24.5.40 site-lisp
   address@hidden:~/web/marc0$ 

then

   file_in_subdir_n_from_the_end:///usr/local/share/emacs:2:etc/NEWS

will expand to

   /usr/local/share/emacs/24.5.40/etc/NEWS

1. http://www.autistici.org/marc0/CheckurlsHomepage.html
2. http://www.autistici.org/marc0/src/checkurls/checkurls-0.5.0-alpha1.tar.gz
3. http://www.autistici.org/marc0/src/checkurls/checkurls-0.5.0-alpha1.tar.gz

- -- 
Marco Parrone - address@hidden
www.autistici.org/marc0
2143 9E77 D5E6 115A 48AD  A170 D0EE F736 (4E88 99C2)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8 <http://mailcrypt.sourceforge.net/>

iD8DBQE+poed0O73Nk6ImcIRAs6aAJ9CYCS8YB++x4QkoJICRwaABu3/gQCeMGtB
PNmJ1/OmVTf03e11ALqlVLM=
=RqoB
-----END PGP SIGNATURE-----


--- End Message ---

-- 
http://jidanni.org/ Taiwan(04)25854780

reply via email to

[Prev in Thread] Current Thread [Next in Thread]