* lisp/eshell/esh-util.el (eshell-private-file-modes)
(eshell-private-directory-modes):
* lisp/gnus/mail-source.el (mail-source-default-file-modes):
* lisp/printing.el (pr-file-modes):
* lisp/gnus/mm-decode.el (mm-attachment-file-modes):
* lisp/gnus/nnmail.el (nnmail-default-file-modes):
* lisp/recentf.el (recentf-save-file-modes):
* lisp/vc/ediff-init.el (ediff-temp-file-mode):
* lisp/vc/emerge.el (emerge-temp-file-mode): Better document the fact
that these are integer and not octal values.
* lisp/epg.el (epg--start):
* lisp/emacs-lisp/package.el (package-import-keyring): Use octal values
to make the code more self-documenting.
(cherry picked from commit
da5df90fadbec9db692ff34abcd28ce5a5b29c2a)
(setq file (expand-file-name file))
(let ((context (epg-make-context 'OpenPGP)))
(when package-gnupghome-dir
- (with-file-modes 448
+ (with-file-modes #o700
(make-directory package-gnupghome-dir t))
(setf (epg-context-home-directory context) package-gnupghome-dir))
(message "Importing %s..." (file-name-nondirectory file))
:noquery t))
(setf (epg-context-error-buffer context) (process-buffer error-process))
(with-existing-directory
- (with-file-modes 448
+ (with-file-modes #o700
(setq process (make-process :name "epg"
:buffer buffer
:command (cons (epg-context-program context)
:type 'boolean)
(defcustom eshell-private-file-modes #o600 ; umask 177
- "The file-modes value to use for creating \"private\" files."
+ "The file-modes value to use for creating \"private\" files.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:type 'integer)
(defcustom eshell-private-directory-modes #o700 ; umask 077
- "The file-modes value to use for creating \"private\" directories."
+ "The file-modes value to use for creating \"private\" directories.
+This is decimal, not octal. The default is 448 (0700 in octal)."
:type 'integer)
(defcustom eshell-tar-regexp
"Directory where incoming mail source files (if any) will be stored."
:type 'directory)
-(defcustom mail-source-default-file-modes 384
- "Set the mode bits of all new mail files to this integer."
+(defcustom mail-source-default-file-modes #o600
+ "Set the mode bits of all new mail files to this integer.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:type 'integer)
(defcustom mail-source-delete-incoming
:type '(choice directory (const :tag "Default" nil))
:group 'mime-display)
-(defcustom mm-attachment-file-modes 384
- "Set the mode bits of saved attachments to this integer."
+(defcustom mm-attachment-file-modes #o600
+ "Set the mode bits of saved attachments to this integer.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:version "22.1"
:type 'integer
:group 'mime-display)
:group 'nnmail-files
:type 'boolean)
-(defcustom nnmail-default-file-modes 384
- "Set the mode bits of all new mail files to this integer."
+(defcustom nnmail-default-file-modes #o600
+ "Set the mode bits of all new mail files to this integer.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:group 'nnmail-files
:type 'integer)
;; It uses 0600 as default instead of (default-file-modes).
;; So, by default, only the session owner have permission to deal with files
;; generated by `printing'.
-(defcustom pr-file-modes ?\600
+(defcustom pr-file-modes #o600
"Specify the file permission bits for newly created files.
-
+This is decimal, not octal. The default is 384 (0600 in octal).
It should be an integer; only the low 9 bits are used.
See also `pr-temp-dir' and `pr-ps-temp-file'."
(defcustom recentf-save-file-modes #o600
"Mode bits of recentf save file, as an integer, or nil.
-If non-nil, after writing `recentf-save-file', set its mode bits to
-this value. By default give R/W access only to the user who owns that
-file. See also the function `set-file-modes'."
+If non-nil, after writing `recentf-save-file', set its mode bits to this
+value. This is decimal, not octal. The default is 384 (0600 in octal),
+which gives R/W access only to the user who owns that file. See also
+the function `set-file-modes'."
:group 'recentf
:type '(choice (const :tag "Don't change" nil)
integer))
(define-obsolete-variable-alias 'ediff-temp-file-prefix
'temporary-file-directory "28.1")
-(defcustom ediff-temp-file-mode 384 ; u=rw only
- "Mode for Ediff temporary files."
+(defcustom ediff-temp-file-mode #o0600
+ "Mode for Ediff temporary files.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:type 'integer
:group 'ediff)
"customize `temporary-file-directory' instead."
"24.4" 'set)
-(defcustom emerge-temp-file-mode 384 ; u=rw only
- "Mode for Emerge temporary files."
+(defcustom emerge-temp-file-mode #o600
+ "Mode for Emerge temporary files.
+This is decimal, not octal. The default is 384 (0600 in octal)."
:type 'integer)
(make-obsolete-variable 'emerge-temp-file-mode