;ELC   
;;; Compiled
;;; in Emacs version 29.4
;;; with all optimizations.



(byte-code "\300\301!\210\302\303\304\305\306\307\310\311&\210\312\313\314\315\316DD\317\320\321\322\323&\210\312\324\314\315\325DD\326\322\327\330\331&\210\312\332\314\315\333DD\334\322\335\330\331&\207" [require esh-mode custom-declare-group eshell-pred nil "This module allows for predicates to be applied to globbing\npatterns (similar to zsh), in addition to string modifiers which can\nbe applied either to globbing results, variable references, or just\nordinary strings." :tag "Value modifiers and predicates" :group eshell-module custom-declare-variable eshell-pred-load-hook funcall function #[0 "\300\207" [nil] 1 #1=""] "A list of functions to run when `eshell-pred' is loaded." :version "24.1" :type hook eshell-predicate-alist #[0 "\300\207" [((47 eshell-pred-file-type 100) (46 eshell-pred-file-type 45) (61 eshell-pred-file-type 115) (112 eshell-pred-file-type 112) (64 eshell-pred-file-type 108) (37 eshell-pred-file-type 37) (114 eshell-pred-file-mode 256) (119 eshell-pred-file-mode 128) (120 eshell-pred-file-mode 64) (65 eshell-pred-file-mode 32) (73 eshell-pred-file-mode 16) (69 eshell-pred-file-mode 8) (82 eshell-pred-file-mode 4) (87 eshell-pred-file-mode 2) (88 eshell-pred-file-mode 1) (115 eshell-pred-file-mode 2048) (83 eshell-pred-file-mode 1024) (116 eshell-pred-file-mode 512) (85 lambda (file) (if (file-exists-p file) (= (file-attribute-user-id (file-attributes file)) (user-uid)))) (71 lambda (file) (if (file-exists-p file) (= (file-attribute-group-id (file-attributes file)) (group-gid)))) (42 lambda (file) (and (file-regular-p file) (not (file-symlink-p file)) (file-executable-p file))) (108 eshell-pred-file-links) (117 eshell-pred-user-or-group 117 "user" 2 #'eshell-user-id) (103 eshell-pred-user-or-group 103 "group" 3 #'eshell-group-id) (97 eshell-pred-file-time 97 "access" 4) (109 eshell-pred-file-time 109 "modification" 5) (99 eshell-pred-file-time 99 "change" 6) (76 eshell-pred-file-size))] 1 #1#] "A list of predicates than can be applied to a globbing pattern.\nThe format of each entry is\n\n  (CHAR . PREDICATE-FUNC-SEXP)" (repeat (cons character sexp)) :risky t eshell-modifier-alist #[0 "\300\207" [((69 lambda (lst) (mapcar #'eshell-eval-argument lst)) (76 lambda (lst) (mapcar #'downcase lst)) (85 lambda (lst) (mapcar #'upcase lst)) (67 lambda (lst) (mapcar #'capitalize lst)) (104 lambda (lst) (mapcar #'file-name-directory lst)) (105 eshell-include-members 105) (120 eshell-include-members 120 t) (114 lambda (lst) (mapcar #'file-name-sans-extension lst)) (101 lambda (lst) (mapcar #'file-name-extension lst)) (116 lambda (lst) (mapcar #'file-name-nondirectory lst)) (113 lambda (lst) (mapcar #'eshell-escape-arg lst)) (117 lambda (lst) (seq-uniq lst)) (111 lambda (lst) (sort lst #'string-lessp)) (79 lambda (lst) (sort lst #'string-greaterp)) (106 eshell-join-members) (83 eshell-split-members) (82 function reverse) (103 progn (forward-char) (if (eq (char-before) 115) (eshell-pred-substitute t) (error "`g' modifier cannot be used alone"))) (115 eshell-pred-substitute))] 1 #1#] "A list of modifiers than can be applied to an argument expansion.\nThe format of each entry is\n\n  (CHAR . MODIFIER-FUNC-SEXP)" (repeat (cons character sexp))] 8)
(defvar eshell-predicate-help-string "Eshell predicate quick reference:\n\n  -  follow symbolic references for predicates after the `-'\n  ^  invert sense of predicates after the `^'\n\nFILE TYPE:\n  /  directories              s  sockets\n  .  regular files            p  named pipes\n  *  executable (files only)  @  symbolic links\n\n  %x  file type == `x' (as by ls -l; so `c' = char device, etc.)\n\nPERMISSION BITS (for owner/group/world):\n  r/A/R  readable    s  setuid\n  w/I/W  writable    S  setgid\n  x/E/X  executable  t  sticky bit\n\nOWNERSHIP:\n  U               owned by effective uid\n  G               owned by effective gid\n  u(UID|\\='user\\=')   owned by UID/user\n  g(GID|\\='group\\=')  owned by GID/group\n\nFILE ATTRIBUTES:\n  l[+-]N                 +/-/= N links\n  a[Mwhms][+-](N|\\='FILE\\=') access time +/-/= N months/weeks/hours/mins/secs\n			 (days if unspecified) if FILE specified,\n			 use as comparison basis; so a+\\='file.c\\='\n			 shows files accessed before file.c was\n			 last accessed\n  m[Mwhms][+-](N|\\='FILE\\=') modification time...\n  c[Mwhms][+-](N|\\='FILE\\=') change time...\n  L[kmp][+-]N            file size +/-/= N Kb/Mb/blocks\n\nEXAMPLES:\n  *(^@)         all non-dot files which are not symlinks\n  .#*(^@)       all files which are not symbolic links\n  **/.#*(*)     all executable files, searched recursively\n  ***/*~f*(-/)  recursively (though not traversing symlinks),\n		find all directories (or symlinks referring to\n		directories) whose names do not begin with f.\n  e*(*Lk+50)    executables 50k or larger beginning with `e'")
(defvar eshell-modifier-help-string "Eshell modifier quick reference:\n\nFOR SINGLE ARGUMENTS, or each argument of a list of strings:\n  E  evaluate again\n  L  lowercase\n  U  uppercase\n  C  capitalize\n  h  dirname\n  t  basename\n  e  file extension\n  r  strip file extension\n  q  escape special characters\n\n  S       split string at any whitespace character\n  S/PAT/  split string at each occurrence of PAT\n\nFOR LISTS OF ARGUMENTS:\n  o  sort alphabetically\n  O  reverse sort alphabetically\n  u  uniq list (typically used after :o or :O)\n  R  reverse list\n\n  j       join list members, separated by a space\n  j/PAT/  join list members, separated by PAT\n  i/PAT/  exclude all members not matching PAT\n  x/PAT/  exclude all members matching PAT\n\n  s/pat/match/   substitute PAT with MATCH\n  gs/pat/match/  substitute PAT with MATCH for all occurrences\n\nEXAMPLES:\n  *.c(:o)  sorted list of .c files")#@220 A list of delimiter pairs that can be used in argument predicates/modifiers.
Each element is of the form (OPEN . CLOSE), where OPEN and CLOSE
are characters representing the opening and closing delimiter,
respectively.
(defvar eshell-pred-delimiter-pairs '((40 . 41) (91 . 93) (60 . 62) (123 . 125) (39 . 39) (34 . 34) (47 . 47) (124 . 124)) (#$ . 5825))
(defvar eshell-pred-mode-map (define-keymap "C-c M-q" 'eshell-display-predicate-help "C-c M-m" 'eshell-display-modifier-help))
(defalias 'eshell-display-predicate-help #[0 "\300\301!\207" [with-electric-help #[0 "c\207" [eshell-predicate-help-string] 1]] 2 nil nil])
(defalias 'eshell-display-modifier-help #[0 "\300\301!\207" [with-electric-help #[0 "c\207" [eshell-modifier-help-string] 1]] 2 nil nil])#@101 Non-nil if Eshell-Pred mode is enabled.
Use the command `eshell-pred-mode' to change this variable.
(defvar eshell-pred-mode nil (#$ . 6593))
(make-variable-buffer-local 'eshell-pred-mode)#@621 Minor mode for the eshell-pred module.

\{eshell-pred-mode-map}

This is a minor mode.  If called interactively, toggle the
`Eshell-Pred mode' mode.  If the prefix argument is positive,
enable the mode, and if it is zero or negative, disable the mode.

If called from Lisp, toggle the mode if ARG is `toggle'.  Enable
the mode if ARG is nil, omitted, or is a positive number.
Disable the mode if ARG is a negative number.

To check whether the minor mode is enabled in the current buffer,
evaluate `eshell-pred-mode'.

The mode's hook is called both when the mode is enabled and when
it is disabled.

(fn &optional ARG)
(defalias 'eshell-pred-mode #[256 "\302 \303=\203 ?\202 \247\203 \304W\203 \305\202 \306\307\301!\2031 \310\300	\"\2031 \300	B\311\312\203; \313\202< \314\"\210\315\316!\203_ \302 \203P \211\302 \232\203_ \317\320\321\203[ \322\202\\ \323\324$\210\210\325 \210\207" [eshell-pred-mode local-minor-modes current-message toggle 1 nil t boundp delq run-hooks eshell-pred-mode-hook eshell-pred-mode-on-hook eshell-pred-mode-off-hook called-interactively-p any message "%s %sabled%s" "Eshell-Pred mode" "en" "dis" " in current buffer" force-mode-line-update] 7 (#$ . 6788) (byte-code "\203\n \301!\202 \302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)])
(defvar eshell-pred-mode-hook nil)
(byte-code "\301\302N\204\f \303\301\302\304#\210\303\301\305\306#\210\303\301\307\310C#\210\311\312\310\310\211%\207" [eshell-pred-mode-map eshell-pred-mode-hook variable-documentation put "Hook run after entering or leaving `eshell-pred-mode'.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it.  (This is true for all hook variables.)" custom-type hook standard-value nil add-minor-mode eshell-pred-mode] 6)#@41 Initialize the predicate/modifier code.
(defalias 'eshell-pred-initialize #[0 "\300\301\302\303\211$\210\304 \207" [add-hook eshell-parse-argument-hook eshell-parse-arg-modifier t eshell-pred-mode] 5 (#$ . 8575)])#@176 Apply to list LST a series of PREDICATES and MODIFIERS.
STRING-DESC is the original string defining these predicates and
modifiers.

(fn LST PREDICATES MODIFIERS STRING-DESC)
(defalias 'eshell-apply-modifiers #[1028 "\301;\203 C\262\302\262<\205I \203) \303\301#\206' \205' \304\305\"\262\203: @!\262A\262\202) \211\203H G\306U\203H @\207\207" [eshell-error-if-no-glob nil t eshell-winnow-list error "No matches found: (%s)" 1] 9 (#$ . 8795)])#@134 Parse a modifier that has been specified after an argument.
This function is specially for adding onto `eshell-parse-argument-hook'.
(defalias 'eshell-parse-arg-modifier #[0 "\302f\303=\205\\ \302u\210\304\303\305\"\211\204 \306\307\303\"\202Z \211T\211\206  `\211dU\206* \211f>\266\202\205Z \214`}\210\310 \311 \211@A\204D \211\203Q \312	\313\314	$C\")\266\211Tb\210\315 \262\207" [eshell-delimiter-argument-list eshell-current-modifiers nil 40 eshell-find-delimiter 41 throw eshell-incomplete buffer-string eshell-parse-modifiers append make-closure #[257 "\303\301\300\302$\207" [V0 V1 V2 eshell-apply-modifiers] 6 "\n\n(fn LST)"] eshell-finish-arg] 12 (#$ . 9267)])#@387 Parse value modifiers and predicates at point.
Return a cons cell of the form

  (PRED-FUNC-LIST . MOD-FUNC-LIST)

PRED-FUNC-LIST is a list of predicate functions.  MOD-FUNC-LIST
is a list of result modifier functions.  PRED-FUNCS take a
filename and return t if the test succeeds; MOD-FUNCS take any
list of strings and perform a modification, returning the
resultant list of strings.
(defalias 'eshell-parse-modifiers #[0 "\302\211\211\211\3031\351 m?\205\344 \302f\211\304\267\202\276 \302u\210\305\306!\203H \307p!\211\203= \310!\203= \311\312\313\"$\262\266\202 \314\315\316!\"\266\202 \314\317!\266\202 \302u\210?\262\210\202 \302u\210?\262\210\202 \302u\210\305\306!\203\222 \307p!\211\203\207 \310!\203\207 \320\321\"B\266\203\202 \314\322\316!\"\266\202 \314\323!\266\202 \302u\210\302f\236\211\204\257 \314\324\302f\"\266\202 \302u\210\312A\313\"B\266\203\202 \211	\236\211\204\316 \314\325\"\266\202 \302u\210\311\312A\313\"$\262\266\202 0\210\202\356 \210\314\326!\210\237\237B\207" [eshell-modifier-alist eshell-predicate-alist nil (end-of-buffer) #s(hash-table size 5 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (39 21 94 80 45 91 124 102 58 154)) looking-at "[^|':]" read functionp eshell-add-pred-func eval t error "Invalid function predicate `%s'" eshell-stringify "Invalid function predicate" make-closure #[257 "\301\300\"\207" [V0 mapcar] 4 "\n\n(fn LST)"] "Invalid function modifier `%s'" "Invalid function modifier" "Unknown modifier character `%c'" "Unknown predicate character `%c'" "Predicate or modifier ended prematurely"] 11 (#$ . 9956)])#@74 Add the predicate function PRED to FUNCS.

(fn PRED FUNCS NEGATE FOLLOW)
(defalias 'eshell-add-pred-func #[1028 "\203 \300\301\"\262\262\211\203 \300\302\"\262\262B\207" [make-closure #[257 "\300!?\207" [V0] 3 "\n\n(fn FILE)"] #[257 "\300\301!!\207" [V0 file-truename] 4 "\n\n(fn FILE)"]] 8 (#$ . 11599)])#@325 Starting at point, get the comparison modifier argument, if any.
These are the -/+ characters, corresponding to `<' and `>',
respectively.  If no comparison modifier is at point, return `='.

FUNCTIONS, if non-nil, is a list of comparison functions,
specified as (LESS-THAN GREATER-THAN EQUAL-TO).

(fn &optional FUNCTIONS)
(defalias 'eshell-get-comparison-modifier-argument #[256 "\211\206 \300\301\302E\303f\304>\203\" \303f\305=\203 \211@\202 \211A@\303u\210\207\3068\207" [< > = nil (45 43) 45 2] 4 (#$ . 11926)])#@124 Starting at point, get the numeric modifier argument, if any.
If a number is found, update point to just after the number.
(defalias 'eshell-get-numeric-modifier-argument #[0 "\300\301!\205 \302\303\304!!\304\225b\210\207" [looking-at "[0-9]+" string-to-number match-string 0] 3 (#$ . 12454)])#@563 Starting at point, get the delimited modifier argument, if any.
If the character after point is a predicate/modifier
delimiter (see `eshell-pred-delimiter-pairs', read the value of
the argument and update point to be just after the closing
delimiter.

If CHAINED-P is true, then another delimited modifier argument
will immediately follow this one.  In this case, when the opening
and closing delimiters are the same, update point to be just
before the closing delimiter. This allows modifiers like
`:s/match/repl' to work as expected.

(fn &optional CHAINED-P)
(defalias 'eshell-get-delimited-modifier-argument #[256 "\301f\211\205 \302\"A\211\205 \303\301\211\304%\211\205B \305\306\307\310\311\312\310		FDE!\313\314`T\"#\203> =\203> \202@ Tb\210\207" [eshell-pred-delimiter-pairs nil assoc eshell-find-delimiter t replace-regexp-in-string rx-to-string seq "\\" group or "\\1" buffer-substring-no-properties] 13 (#$ . 12755)])#@119 Return a predicate to test whether a file match a given user/group id.

(fn MOD-CHAR MOD-TYPE ATTR-INDEX GET-ID-FUNC)
(defalias 'eshell-pred-user-or-group #[1028 "\300 C\211\242\204 \301 \206 \302\303#!\240\266\211\242\204& \302\304#\210\305\306#\207" [eshell-get-numeric-modifier-argument eshell-get-delimited-modifier-argument error "Malformed %s name string for modifier `%c'" "Unknown %s name specified for modifier `%c'" make-closure #[257 "\302!\211\205 \3018\300\242U\207" [V0 V1 file-attributes] 4 "\n\n(fn FILE)"]] 9 (#$ . 13704)])#@102 Return a predicate to test whether a file matches a certain time.

(fn MOD-CHAR MOD-TYPE ATTR-INDEX)
(defalias 'eshell-pred-file-time #[771 "\300\301C\301C\301f\302>\2034 \301f\262\303\267\2021 \304\262\2021 \305\262\2021 \306\262\2021 \307\262\2021 \310\262\301u\210\311\312\313\314E!\240\210\315 \211\203P \316_!\240\266\202n \317 \206\\ \320\321	#\322!\206f \320\323\"8\240\266\324\325$\207" [86400 nil (77 119 104 109 115) #s(hash-table size 5 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (77 22 119 28 104 34 109 40 115 46)) 2592000 604800 3600 60 1 eshell-get-comparison-modifier-argument time-less-p #[514 "\300\"\207" [time-less-p] 5 "\n\n(fn A B)"] time-equal-p eshell-get-numeric-modifier-argument time-since eshell-get-delimited-modifier-argument error "Malformed %s time modifier `%c'" file-attributes "Cannot stat file `%s'" make-closure #[257 "\303!\211\205 \301\242\300\242\3028\"\207" [V0 V1 V2 file-attributes] 6 "\n\n(fn FILE)"]] 12 (#$ . 14268)])#@201 Return a test which tests that the file is of a certain TYPE.
TYPE must be a character, and should be one of the possible options
that `ls -l' will show in the first column of its display.

(fn TYPE)
(defalias 'eshell-pred-file-type #[257 "\211\300=\203 \301f\262\211\302>\203 \301u\210\202 \300\262\211\300=\203# \303\202% \211C\304\305\"\207" [37 nil (98 99) (98 99) make-closure #[257 "\301\302!!\211\205 \211\3038\262\304H\300>\207" [V0 eshell-file-attributes directory-file-name 8 0] 5 "\n\n(fn FILE)"]] 5 (#$ . 15291)])#@70 Return a test which tests that MODE pertains to the file.

(fn MODE)
(defalias 'eshell-pred-file-mode #[257 "\300\301\"\207" [make-closure #[257 "\301\302\"\211\205 \303\300\"\304U?\207" [V0 file-modes nofollow logand 0] 5 "\n\n(fn FILE)"]] 4 (#$ . 15832)])
(byte-code "\300\301\302\303#\304\301\305\306#\207" [function-put eshell-pred-file-mode speed -1 put byte-optimizer byte-compile-inline-expand] 5)#@72 Return a predicate to test whether a file has a given number of links.
(defalias 'eshell-pred-file-links #[0 "\300 \301 \206\n \302\303!\304\305#\207" [eshell-get-comparison-modifier-argument eshell-get-numeric-modifier-argument error "Invalid file link count modifier `l'" make-closure #[257 "\302!\211\205 \301\211A@\262\300\"\207" [V0 V1 eshell-file-attributes] 5 "\n\n(fn FILE)"]] 6 (#$ . 16246)])#@63 Return a predicate to test whether a file is of a given size.
(defalias 'eshell-pred-file-size #[0 "\300\301C\301C\301f\227\302>\203: \301f\227\240\210\242\303=\203  \304\262\2027 \242\305=\203- \306\262\2027 \242\307=\2037 \310\262\301u\210\311 \240\210\211\312 \206H \313\314!_\240\210\315\316#\207" [1 nil (107 109 112) 107 1024 109 1048576 112 512 eshell-get-comparison-modifier-argument eshell-get-numeric-modifier-argument error "Invalid file size modifier `L'" make-closure #[257 "\302!\211\205 \301\242\3038\262\300\242\"\207" [V0 V1 eshell-file-attributes 7] 6 "\n\n(fn FILE)"]] 7 (#$ . 16659)])#@81 Return a modifier function that will substitute matches.

(fn &optional REPEAT)
(defalias 'eshell-pred-substitute #[256 "\300\301!\206	 \302\303!\300 \206 \302\304!\203 \305\306#\202\" \305\307#\305\310\"\207" [eshell-get-delimited-modifier-argument t error "Malformed pattern string for modifier `s'" "Malformed replace string for modifier `s'" make-closure #[257 "\302\301\300\303$\207" [V0 V1 replace-regexp-in-string t] 6 "\n\n(fn STR)"] #[257 "\302\301\"\203 \303\300\304\305$\207\306\307P!\207" [V0 V1 string-match replace-match t nil error ": substitution failed"] 6 "\n\n(fn STR)"] #[257 "\301\300\"\207" [V0 mapcar] 4 "\n\n(fn LST)"]] 7 (#$ . 17285)])#@148 Include only Lisp members matching a regexp.
If INVERT-P is non-nil, include only members not matching a regexp.

(fn MOD-CHAR &optional INVERT-P)
(defalias 'eshell-include-members #[513 "\300 \206	 \301\302\"\203 \303\304\"\202 \303\305\"C\303\306\"\207" [eshell-get-delimited-modifier-argument error "Malformed pattern string for modifier `%c'" make-closure #[257 "\301\300\"?\207" [V0 string-match] 4 "\n\n(fn ELEM)"] #[257 "\301\300\"\207" [V0 string-match] 4 "\n\n(fn ELEM)"] #[257 "\301\302\300#\207" [V0 eshell-winnow-list nil] 5 "\n\n(fn LST)"]] 7 (#$ . 17966)])#@47 Return a modifier function that join matches.
(defalias 'eshell-join-members #[0 "\300 \206 \301\302\303\"\207" [eshell-get-delimited-modifier-argument " " make-closure #[257 "\301\302\300#\207" [V0 mapconcat identity] 5 "\n\n(fn LST)"]] 4 (#$ . 18552)])#@49 Return a modifier function that splits members.
(defalias 'eshell-split-members #[0 "\300 \301\302\"\207" [eshell-get-delimited-modifier-argument make-closure #[257 "\301\302\303\300\"\"\207" [V0 mapcar make-closure #[257 "\301\300\"\207" [V0 split-string] 4 "\n\n(fn STR)"]] 5 "\n\n(fn LST)"]] 4 (#$ . 18815)])
(provide 'em-pred)
