Mercurial > hg > xemacs-beta
comparison lisp/packages/time-stamp.el @ 134:34a5b81f86ba r20-2b1
Import from CVS: tag r20-2b1
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:30:11 +0200 |
parents | b9518feda344 |
children |
comparison
equal
deleted
inserted
replaced
133:b27e67717092 | 134:34a5b81f86ba |
---|---|
50 ;;; Change Log: | 50 ;;; Change Log: |
51 | 51 |
52 ;; Originally based on the 19 Dec 88 version of | 52 ;; Originally based on the 19 Dec 88 version of |
53 ;; date.el by John Sturdy <mcvax!harlqn.co.uk!jcgs@uunet.uu.net> | 53 ;; date.el by John Sturdy <mcvax!harlqn.co.uk!jcgs@uunet.uu.net> |
54 ;; version 2, January 1995: replaced functions with %-escapes | 54 ;; version 2, January 1995: replaced functions with %-escapes |
55 ;; $Id: time-stamp.el,v 1.1.1.2 1996/12/18 22:50:44 steve Exp $ | 55 ;; $Id: time-stamp.el,v 1.2 1997/04/19 23:21:12 steve Exp $ |
56 | 56 |
57 ;;; Code: | 57 ;;; Code: |
58 | 58 |
59 (defvar time-stamp-active t | 59 (defgroup time-stamp nil |
60 "Maintain last change time stamps in files edited by Emacs." | |
61 :group 'data | |
62 :group 'extensions) | |
63 | |
64 | |
65 (defcustom time-stamp-active t | |
60 "*Non-nil to enable time-stamping of buffers by \\[time-stamp]. | 66 "*Non-nil to enable time-stamping of buffers by \\[time-stamp]. |
61 Can be toggled by \\[time-stamp-toggle-active]. | 67 Can be toggled by \\[time-stamp-toggle-active]. |
62 See also the variable time-stamp-warn-inactive.") | 68 See also the variable time-stamp-warn-inactive." |
63 | 69 :type 'boolean |
64 (defvar time-stamp-warn-inactive t | 70 :group 'time-stamp) |
71 | |
72 (defcustom time-stamp-warn-inactive t | |
65 "*Non-nil to have \\[time-stamp] warn if a buffer did not get time-stamped. | 73 "*Non-nil to have \\[time-stamp] warn if a buffer did not get time-stamped. |
66 A warning is printed if time-stamp-active is nil and the buffer contains | 74 A warning is printed if time-stamp-active is nil and the buffer contains |
67 a time stamp template that would otherwise have been updated.") | 75 a time stamp template that would otherwise have been updated." |
68 | 76 :type 'boolean |
69 (defvar time-stamp-format "%02y/%02m/%02d %02H:%02M:%02S %u" | 77 :group 'time-stamp) |
78 | |
79 (defcustom time-stamp-format "%02y/%02m/%02d %02H:%02M:%02S %u" | |
70 "*Template for the string inserted by \\[time-stamp]. | 80 "*Template for the string inserted by \\[time-stamp]. |
71 Value may be a string or a list. (Lists are supported only for | 81 Value may be a string or a list. (Lists are supported only for |
72 backward compatibility.) A string is used verbatim except | 82 backward compatibility.) A string is used verbatim except |
73 for character sequences beginning with %: | 83 for character sequences beginning with %: |
74 | 84 |
95 Decimal digits between the % and the type character specify the | 105 Decimal digits between the % and the type character specify the |
96 field width. Strings are truncated on the right; numbers on the left. | 106 field width. Strings are truncated on the right; numbers on the left. |
97 A leading zero causes numbers to be zero-filled. | 107 A leading zero causes numbers to be zero-filled. |
98 | 108 |
99 For example, to get the format used by the `date' command, | 109 For example, to get the format used by the `date' command, |
100 use \"%3a %3b %2d %02H:%02M:%02S %Z %y\"") | 110 use \"%3a %3b %2d %02H:%02M:%02S %Z %y\"" |
111 :type 'string | |
112 :group 'time-stamp) | |
101 | 113 |
102 | 114 |
103 ;;; Do not change time-stamp-line-limit, time-stamp-start, or | 115 ;;; Do not change time-stamp-line-limit, time-stamp-start, or |
104 ;;; time-stamp-end in your .emacs or you will be incompatible | 116 ;;; time-stamp-end in your .emacs or you will be incompatible |
105 ;;; with other people's files! If you must change them, | 117 ;;; with other people's files! If you must change them, |