annotate lisp/play/meese.el @ 659:505130d1ddf8

*** empty log message ***
author Eric S. Raymond <esr@snark.thyrsus.com>
date Sat, 30 May 1992 22:12:04 +0000
parents d2f6c32ff984
children 203c23c9f22c
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
659
505130d1ddf8 *** empty log message ***
Eric S. Raymond <esr@snark.thyrsus.com>
parents: 14
diff changeset
1 ;; meese.el --- protect the impressionable young minds of America...NOT!
505130d1ddf8 *** empty log message ***
Eric S. Raymond <esr@snark.thyrsus.com>
parents: 14
diff changeset
2
14
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
3 (defun protect-innocence-hook ()
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
4 (if (and (equal (file-name-nondirectory buffer-file-name) "sex.6")
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
5 (not (y-or-n-p "Are you over 18? ")))
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
6 (progn
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
7 (clear-visited-file-modtime)
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
8 (setq buffer-file-name (concat (file-name-directory buffer-file-name)
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
9 "celibacy.1"))
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
10 (let (buffer-read-only) ; otherwise (erase-buffer) may bomb.
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
11 (erase-buffer)
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
12 (insert-file-contents buffer-file-name t))
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
13 (rename-buffer (file-name-nondirectory buffer-file-name)))))
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
14
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
15 (or (memq 'protect-innocence-hook find-file-hooks)
d2f6c32ff984 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
16 (setq find-file-hooks (cons 'protect-innocence-hook find-file-hooks)))
659
505130d1ddf8 *** empty log message ***
Eric S. Raymond <esr@snark.thyrsus.com>
parents: 14
diff changeset
17
505130d1ddf8 *** empty log message ***
Eric S. Raymond <esr@snark.thyrsus.com>
parents: 14
diff changeset
18 ;;; meese.el ends here