]> git.eshelyaron.com Git - emacs.git/commitdiff
; Be more strict with command arguments for a few Eshell commands
authorJim Porter <jporterbugs@gmail.com>
Wed, 16 Aug 2023 01:52:11 +0000 (18:52 -0700)
committerEshel Yaron <me@eshelyaron.com>
Wed, 31 Jan 2024 20:10:38 +0000 (21:10 +0100)
* lisp/eshell/em-dirs.el (eshell/pwd):
* lisp/eshell/em-unix.el (eshell/whoami):
* lisp/eshell/esh-proc.el (eshell/jobs): Don't accept arguments.

(cherry picked from commit c4d16909fa4c30fd5f11bd66de7936790349cb7d)

lisp/eshell/em-dirs.el
lisp/eshell/em-unix.el
lisp/eshell/esh-proc.el

index cf90a8bb23076bd4375085b44db7e2efcbb63b80..85036620c5714f8f2e6fdee3becd63e6dde37a42 100644 (file)
@@ -316,7 +316,7 @@ Thus, this does not include the current directory.")
                    (`(boundaries . ,suffix)
                     `(boundaries 0 . ,(string-search "/" suffix))))))))))
 
-(defun eshell/pwd (&rest _args)
+(defun eshell/pwd ()
   "Change output from `pwd' to be cleaner."
   (let* ((path default-directory)
         (len (length path)))
index dad02206759bb35413aa09291c8f36ea3c680eac..c3c3fea691af9777ac425ba5f0afe626f65f28ec 100644 (file)
@@ -1018,7 +1018,7 @@ Show wall-clock time elapsed during execution of COMMAND.")
                                  (eshell-stringify-list
                                   (flatten-tree (cdr time-args))))))))
 
-(defun eshell/whoami (&rest _args)
+(defun eshell/whoami ()
   "Make \"whoami\" Tramp aware."
   (eshell-user-login-name))
 
index 2bb0043bddb63f18b10fe0fd44cb252fbfa74ff4..35c81f6a4b2491d0bbef503726f17f02e91878d7 100644 (file)
@@ -193,7 +193,7 @@ This is like `process-live-p', but additionally checks whether
 
 (defalias 'eshell/wait #'eshell-wait-for-process)
 
-(defun eshell/jobs (&rest _args)
+(defun eshell/jobs ()
   "List processes, if there are any."
   (and (fboundp 'process-list)
        (process-list)