From: Eli Zaretskii Date: Sat, 23 Sep 2023 13:41:11 +0000 (-0400) Subject: Merge from origin/emacs-29 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6d8801ee739a3ddb51effa177822ea2e0d7c73fc;p=emacs.git Merge from origin/emacs-29 476933b2356 ; * lisp/simple.el (shell-command-to-string): Fix quotation. e27ec0e4144 Improve remote-file-name-inhibit-cache :type --- 6d8801ee739a3ddb51effa177822ea2e0d7c73fc diff --cc lisp/files.el index b67482a2f74,b72f141c0ee..9d766683d26 --- a/lisp/files.el +++ b/lisp/files.el @@@ -1319,31 -1316,14 +1319,31 @@@ consecutive checks. For example (< 0 (file-attribute-size (file-attributes (file-chase-links file)))))))" :group 'files + :group 'tramp :version "24.1" :type '(choice - (const :tag "Do not inhibit file name cache" nil) - (const :tag "Do not use file name cache" t) - (integer :tag "Do not use file name cache" - :format "Do not use file name cache older then %v seconds" + (const :tag "Do not cache remote file attributes" t) + (const :tag "Cache remote file attributes" nil) + (integer :tag "Cache remote file attributes with expiration" + :format "Cache expiry in seconds: %v" :value 10))) +(defcustom remote-file-name-access-timeout nil + "Timeout (in seconds) for `access-file'. +This timeout limits the time to check, whether a remote file is +accessible. `access-file' returns an error after that time. If +the value is 0 or nil, no timeout is used. + +This applies only when there isn't time spent for other actions, +like reading passwords." + :group 'files + :group 'tramp + :version "30.1" + ;;:type '(choice :tag "Timeout (seconds)" natnum (const nil))) + :type '(choice + (natnum :tag "Timeout (seconds)") + (const :tag "Do not use timeout" nil))) + (defun file-local-name (file) "Return the local name component of FILE. This function removes from FILE the specification of the remote host