%PDF- %PDF-
Direktori : /usr/local/share/emacs/27.2/lisp/eshell/ |
Current File : //usr/local/share/emacs/27.2/lisp/eshell/esh-cmd.elc |
;ELC ;;; Compiled ;;; in Emacs version 27.2 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. ;;; This file does not contain utf-8 non-ASCII characters, ;;; and so can be loaded in Emacs versions earlier than 23. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (byte-code "\300\301!\210\300\302!\210\300\303!\210\300\304!\210\300\305!\210\300\306!\210\300\307!\210\310\311\312\313\314\315\316\317&\210\320\321\322\323\324DD\325\326\327%\210\320\330\322\323\331DD\332\326\333%\210\320\334\322\323\335DD\336\326\337%\210\320\340\322\323\341DD\342\326\337%\210\320\343\322\323\344DD\345\326\337%\210\320\346\322\323\347DD\350\326\337%\210\320\351\322\323\352DD\353\326\337%\210\320\354\322\323\355DD\356\326\337%\207" [require esh-util eldoc esh-arg esh-proc esh-module esh-io esh-ext custom-declare-group eshell-cmd nil "Executing an Eshell command is as simple as typing it in and\npressing <RET>. There are several different kinds of commands,\nhowever." :tag "Command invocation" :group eshell custom-declare-variable eshell-prefer-lisp-functions funcall function #[0 "\300\207" [nil] 1] "If non-nil, prefer Lisp functions to external commands." :type boolean eshell-lisp-regexp #[0 "\300\207" [#1="\\([(`]\\|#'\\)"] 1 #1#] "A regexp which, if matched at beginning of an argument, means Lisp.\nSuch arguments will be passed to `read', and then evaluated." regexp eshell-pre-command-hook #[0 "\300\207" [nil] 1] "A hook run before each interactive command is invoked." hook eshell-post-command-hook #[0 "\300\207" [nil] 1] "A hook run after each interactive command is invoked." eshell-prepare-command-hook #[0 "\300\207" [nil] 1] "A set of functions called to prepare a named command.\nThe command name and its argument are in `eshell-last-command-name'\nand `eshell-last-arguments'. The functions on this hook can change\nthe value of these symbols if necessary.\n\nTo prevent a command from executing at all, set\n`eshell-last-command-name' to nil." eshell-named-command-hook #[0 "\300\207" [nil] 1] "A set of functions called before a named command is invoked.\nEach function will be passed the command name and arguments that were\npassed to `eshell-named-command'.\n\nIf any of the functions returns a non-nil value, the named command\nwill not be invoked, and that value will be returned from\n`eshell-named-command'.\n\nIn order to substitute an alternate command form for execution, the\nhook function should throw it using the tag `eshell-replace-command'.\nFor example:\n\n (add-hook \\='eshell-named-command-hook #\\='subst-with-cd)\n (defun subst-with-cd (command args)\n (throw \\='eshell-replace-command\n (eshell-parse-command \"cd\" args)))\n\nAlthough useless, the above code will cause any non-glob, non-Lisp\ncommand (i.e., `ls' as opposed to `*ls' or `(ls)') to be replaced by a\ncall to `cd' using the arguments that were passed to the function." eshell-pre-rewrite-command-hook #[0 "\300\207" [(eshell-no-command-conversion eshell-subcommand-arg-values)] 1] "A hook run before command rewriting begins.\nThe terms of the command to be rewritten is passed as arguments, and\nmay be modified in place. Any return value is ignored." eshell-rewrite-command-hook #[0 "\300\207" [(eshell-rewrite-for-command eshell-rewrite-while-command eshell-rewrite-if-command eshell-rewrite-sexp-command eshell-rewrite-initial-subcommand eshell-rewrite-named-command)] 1] "A set of functions used to rewrite the command argument.\nOnce parsing of a command line is completed, the next step is to\nrewrite the initial argument into something runnable.\n\nA module may wish to associate special behavior with certain argument\nsyntaxes at the beginning of a command line. They are welcome to do\nso by adding a function to this hook. The first function to return a\nsubstitute command form is the one used. Each function is passed the\ncommand's full argument list, which is a list of sexps (typically\nforms or strings)."] 8) #@152 Function run after command rewriting is finished. Takes the (rewritten) command, modifies it as it sees fit and returns the new result to use instead. (defvar eshell-post-rewrite-command-function 'identity (#$ . 4092)) #@180 A hook run after command rewriting is finished. Each function is passed the symbol containing the rewritten command, which may be modified directly. Any return value is ignored. (defvar eshell-post-rewrite-command-hook nil (#$ . 4318)) (byte-code "\300\301\302\303#\210\304\305\306\307\310DD\311\312\313%\210\304\314\306\307\315DD\316\317\320\312\321&\210\304\322\306\307\323DD\324\325\326\327\330\312\331& \210\304\332\306\307\333DD\334\312\335%\210\304\336\306\307\337DD\340\312\341%\210\342\343\336\344#\207" [make-obsolete-variable eshell-post-rewrite-command-hook eshell-post-rewrite-command-function "24.4" custom-declare-variable eshell-complex-commands funcall function #[0 "\300\207" [("ls")] 1] "A list of commands names or functions, that determine complexity.\nThat is, if a command is defined by a function named eshell/NAME,\nand NAME is part of this list, it is invoked as a complex command.\nComplex commands are always correct, but run much slower. If a\ncommand works fine without being part of this list, then it doesn't\nneed to be.\n\nIf an entry is a function, it will be called with the name, and should\nreturn non-nil if the command is complex." :type (repeat :tag "Commands" (choice (string :tag "Name") (function :tag "Predicate"))) eshell-cmd-load-hook #[0 "\300\207" [nil] 1] "A hook that gets run when `eshell-cmd' is loaded." :version "24.1" hook eshell-debug-command #[0 "\300\207" [nil] 1] "If non-nil, enable Eshell debugging code.\nThis is slow, and only useful for debugging problems with Eshell.\nIf you change this without using customize after Eshell has loaded,\nyou must re-load `esh-cmd.el'." :initialize custom-initialize-default :set #[514 "L\210\300\301!\207" [load "esh-cmd"] 4 "\n\n(fn SYMBOL VALUE)"] boolean eshell-deferrable-commands #[0 "\300\207" [(eshell-named-command eshell-lisp-command eshell-process-identity)] 1] "A list of functions which might return an asynchronous process.\nIf they return a process object, execution of the calling Eshell\ncommand will wait for completion (in the background) before finishing\nthe command." (repeat function) eshell-subcommand-bindings #[0 "\300\207" [((eshell-in-subcommand-p t) (default-directory default-directory) (process-environment (eshell-copy-environment)))] 1] "A list of `let' bindings for subcommand environments." sexp put risky-local-variable t] 10) #@148 If non-nil, ensure that a newline is emitted after a Lisp form. This can be changed by Lisp forms that are evaluated from the Eshell command line. (defvar eshell-ensure-newline-p nil (#$ . 6691)) (defvar eshell-current-command nil) (defvar eshell-command-name nil) (defvar eshell-command-arguments nil) #@142 Internal Eshell variable, non-nil inside a pipeline. Has the value `first', `last' for the first/last commands in the pipeline, otherwise t. (defvar eshell-in-pipeline-p nil (#$ . 7001)) (defvar eshell-in-subcommand-p nil) (defvar eshell-last-arguments nil) (defvar eshell-last-command-name nil) #@68 When this foreground process completes, resume command evaluation. (defvar eshell-last-async-proc nil (#$ . 7303)) #@56 Return currently running command process, if non-Lisp. (defalias 'eshell-interactive-process #[0 "\207" [eshell-last-async-proc] 1 (#$ . 7424)]) (put 'eshell-interactive-process 'byte-optimizer 'byte-compile-inline-expand) #@50 Initialize the Eshell command processing module. (defalias 'eshell-cmd-initialize #[0 "\306\300!\210\307\306\301!\210\307\306\302!\210\307\306\303!\210\307\306\304!\210\307\306\305!\210\307\310\311\312\307\313$\210\310\314\315\307\313$\210\310\316\317\307\313$\210\310\316\320\307\313$\210\321\211>\262\205P \310\322\323\307\313$\207" [eshell-current-command eshell-command-name eshell-command-arguments eshell-last-arguments eshell-last-command-name eshell-last-async-proc make-local-variable nil add-hook eshell-kill-hook eshell-resume-command t eshell-post-command-hook #[0 "\302\211\211\207" [eshell-current-command eshell-last-async-proc nil] 3] eshell-parse-argument-hook eshell-parse-subcommand-argument eshell-parse-lisp-argument eshell-cmpl pcomplete-try-first-hook eshell-complete-lisp-symbols eshell-modules-list] 5 (#$ . 7654)]) #@44 If there is a user reference, complete it. (defalias 'eshell-complete-lisp-symbols #[0 "\304\211\305\"`{\266\202\306\307P\"\205# \310\311\225\"\312\313\314\315 \316#\"\207" [eshell-lisp-regexp pcomplete-stub pcomplete-last-completion-raw obarray nil pcomplete-begin string-match "\\`" substring 0 t throw pcomplete-completions all-completions boundp] 7 (#$ . 8512)]) #@336 Parse the COMMAND, adding ARGS if given. COMMAND can either be a string, or a cons cell demarcating a buffer region. TOPLEVEL, if non-nil, means that the outermost command (the user's input command) is being parsed, and that pre and post command hooks should be run before and after the command. (fn COMMAND &optional ARGS TOPLEVEL) (defalias 'eshell-parse-command #[769 "\305\306:\203 \307@A\"\2029 `\310\311 \310\211\310\312\313\314\315\316!\317\"\320$\216c\210\307`\"`|\210,\262)\262\"\321\322\323\324\305\300$\"\211\211\203\\ \211A\203U \211\325@D\240\210\211A\262\202E \210\203s \325\326\327\330\331\326BE\332BBBD\202v \333!)\207" [eshell--sep-terms inhibit-point-motion-hooks buffer-undo-list inhibit-read-only inhibit-modification-hooks nil append eshell-parse-arguments t buffer-modified-p make-byte-code 0 "\300?\205 \301\302!\207" vconcat vector [restore-buffer-modified-p nil] 2 mapcar #[257 "@\203\f @\302\230\203 \303!\202 \304\305\303!DD\262A \203# \207\306D\207" [eshell--sep-terms eshell-in-pipeline-p ";" eshell-parse-pipeline eshell-do-subjob list eshell-trap-errors] 5 "\n\n(fn CMD)"] eshell-separate-commands "[&;]" eshell-commands progn (run-hooks 'eshell-pre-command-hook) catch 'top-level ((run-hooks 'eshell-post-command-hook)) macroexp-progn] 13 (#$ . 8894)]) #@70 Output a debugging message to `*eshell last cmd*'. (fn TAG SUBFORM) (defalias 'eshell-debug-command #[514 "\301\302!\303!rq\210\204 \304 \202( \305\306\203% \306\303!P\202&