diff options
| -rw-r--r-- | lisp/files.el | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lisp/files.el b/lisp/files.el index eb6d1635fc9..fd97afa3073 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -3454,6 +3454,19 @@ and second, t if reading the auto-save file. | |||
| 3454 | 3454 | ||
| 3455 | The function you specify is responsible for updating (or preserving) point.") | 3455 | The function you specify is responsible for updating (or preserving) point.") |
| 3456 | 3456 | ||
| 3457 | (defvar buffer-stale-function nil | ||
| 3458 | "Function to check whether a non-file buffer needs reverting. | ||
| 3459 | This should be a function with one optional argument NOCONFIRM. | ||
| 3460 | Auto Revert Mode sets NOCONFIRM to t. The function should return | ||
| 3461 | non-nil if the buffer should be reverted. The buffer is current | ||
| 3462 | when this function is called. | ||
| 3463 | |||
| 3464 | The idea behind the NOCONFIRM argument is that the same function | ||
| 3465 | can also be used to ask the user whether the buffer should be | ||
| 3466 | reverted. In such a situation one has to be less careful about, | ||
| 3467 | say, reverting remote files, than if the function is called at | ||
| 3468 | regular intervals by Auto Revert Mode.") | ||
| 3469 | |||
| 3457 | (defvar before-revert-hook nil | 3470 | (defvar before-revert-hook nil |
| 3458 | "Normal hook for `revert-buffer' to run before reverting. | 3471 | "Normal hook for `revert-buffer' to run before reverting. |
| 3459 | If `revert-buffer-function' is used to override the normal revert | 3472 | If `revert-buffer-function' is used to override the normal revert |