Mercurial > hg > xemacs-beta
annotate lisp/blessmail.el @ 4568:1d74a1d115ee
Add #'query-coding-region tests; do the work necessary to get them running.
lisp/ChangeLog addition:
2008-12-28 Aidan Kehoe <kehoea@parhasard.net>
* coding.el (default-query-coding-region):
Declare using defun*, so we can #'return-from to it on
encountering a safe-charsets value of t. Comment out a few
debug messages.
(query-coding-region):
Correct the docstring, it deals with a region, not a string.
(unencodable-char-position):
Correct the implementation for non-nil COUNT, special-case a zero
value for count, treat it as one. Don't rely on dynamic scope when
calling the main lambda.
* unicode.el (unicode-query-coding-region):
Comment out some debug messages here.
* mule/mule-coding.el (8-bit-fixed-query-coding-region):
Comment out some debug messages here.
* code-init.el (raw-text):
Add a safe-charsets property to this coding system.
* mule/korean.el (iso-2022-int-1):
* mule/korean.el (euc-kr):
* mule/korean.el (iso-2022-kr):
Add safe-charsets properties for these coding systems.
* mule/japanese.el (iso-2022-jp):
* mule/japanese.el (jis7):
* mule/japanese.el (jis8):
* mule/japanese.el (shift-jis):
* mule/japanese.el (iso-2022-jp-1978-irv):
* mule/japanese.el (euc-jp):
Add safe-charsets properties for all these coding systems.
* mule/iso-with-esc.el:
Add safe-charsets properties to all the coding systems in
here. Comment on the downside of a safe-charsets value of t for
iso-latin-1-with-esc.
* mule/hebrew.el (ctext-hebrew):
Add a safe-charsets property for this coding system.
* mule/devanagari.el (in-is13194-devanagari):
Add a safe-charsets property for this coding system.
* mule/chinese.el (cn-gb-2312):
* mule/chinese.el (hz-gb-2312):
* mule/chinese.el (big5):
Add safe-charsets properties for these coding systems.
* mule/latin.el (iso-8859-14):
Add an implementation for this, using #'make-8-bit-coding-system.
* mule/mule-coding.el (ctext):
* mule/mule-coding.el (iso-2022-8bit-ss2):
* mule/mule-coding.el (iso-2022-7bit-ss2):
* mule/mule-coding.el (iso-2022-jp-2):
* mule/mule-coding.el (iso-2022-7bit):
* mule/mule-coding.el (iso-2022-8):
* mule/mule-coding.el (escape-quoted):
* mule/mule-coding.el (iso-2022-lock):
Add safe-charsets properties for all these coding systems.
src/ChangeLog addition:
2008-12-28 Aidan Kehoe <kehoea@parhasard.net>
* file-coding.c (Fmake_coding_system):
Document our use of the safe-chars and safe-charsets properties,
and the differences compared to GNU.
(make_coding_system_1): Don't drop the safe-chars and
safe-charsets properties.
(Fcoding_system_property): Return the safe-chars and safe-charsets
properties when asked for them.
* file-coding.h (CODING_SYSTEM_SAFE_CHARSETS):
* coding-system-slots.h:
Make the safe-chars and safe-charsets slots available in these
headers.
tests/ChangeLog addition:
2008-12-28 Aidan Kehoe <kehoea@parhasard.net>
* automated/query-coding-tests.el:
New file, testing the functionality of #'query-coding-region and
#'query-coding-string.
author | Aidan Kehoe <kehoea@parhasard.net> |
---|---|
date | Sun, 28 Dec 2008 14:46:24 +0000 |
parents | d44af0c54775 |
children | 308d34e9f07d |
rev | line source |
---|---|
217 | 1 ;;; blessmail.el --- Decide whether movemail needs special privileges. |
2 | |
3 ;; Copyright (C) 1994 Free Software Foundation, Inc. | |
4 | |
5 ;; Maintainer: FSF | |
6 ;; Keywords: internal | |
7 | |
8 ;; This file is part of XEmacs. | |
9 | |
10 ;; XEmacs is free software; you can redistribute it and/or modify it | |
11 ;; under the terms of the GNU General Public License as published by | |
12 ;; the Free Software Foundation; either version 2, or (at your option) | |
13 ;; any later version. | |
14 | |
15 ;; XEmacs is distributed in the hope that it will be useful, but | |
16 ;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
18 ;; General Public License for more details. | |
19 | |
20 ;; You should have received a copy of the GNU General Public License | |
21 ;; along with XEmacs; see the file COPYING. If not, write to the Free | |
22 ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA | |
23 ;; 02111-1307, USA. | |
24 | |
25 ;;; Synched up with: FSF 19.34. | |
26 | |
27 ;;; Commentary: | |
28 | |
29 ;; This is loaded into a bare Emacs to create the blessmail script, | |
30 ;; which (on systems that need it) is used during installation | |
31 ;; to give appropriate permissions to movemail. | |
32 ;; | |
33 ;; It has to be done from lisp in order to be sure of getting the | |
34 ;; correct value of rmail-spool-directory. | |
35 | |
36 ;;; Code: | |
37 | |
38 ;; These are no longer needed because we run this in emacs instead of temacs. | |
39 ;; (message "Using load-path %s" load-path) | |
40 ;; (load "paths.el") | |
41 ;; It is not safe to load site-init.el here, because it might have things in it | |
42 ;; that won't load properly unless all the rest of Emacs is loaded. | |
43 | |
44 (let ((dirname (directory-file-name rmail-spool-directory)) | |
45 linkname attr modes) | |
46 ;; Check for symbolic link | |
47 (while (setq linkname (file-symlink-p dirname)) | |
48 (setq dirname (if (file-name-absolute-p linkname) | |
49 linkname | |
50 (concat (file-name-directory dirname) linkname)))) | |
51 (insert "#!/bin/sh\n") | |
52 (setq attr (file-attributes dirname)) | |
53 (if (not (eq t (car attr))) | |
54 (insert (format "echo %s is not a directory\n" rmail-spool-directory)) | |
55 (setq modes (nth 8 attr)) | |
56 (cond ((= ?w (aref modes 8)) | |
57 ;; Nothing needs to be done. | |
58 ) | |
59 ((= ?w (aref modes 5)) | |
60 (insert "chgrp " (number-to-string (nth 3 attr)) | |
61 " $* && chmod g+s $*\n")) | |
62 ((= ?w (aref modes 2)) | |
63 (insert "chown " (number-to-string (nth 2 attr)) | |
64 " $* && chmod u+s $*\n")) | |
65 (t | |
66 (insert "chown root $* && chmod u+s $*\n")))) | |
67 (insert "echo mail directory = " dirname "\n")) | |
68 (write-region (point-min) (point-max) "blessmail") | |
69 (kill-emacs) | |
70 | |
71 ;;; blessmail.el ends here |