;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\207" [require json helm-system-packages] 2) #@17 (fn PACKAGES) (defalias 'helm-system-packages-brew-transformer #[257 "\302\303!\211\211\203'\211@\304\305!\"A\211\204 \203B\262\210A\266\202\202\207" [helm-system-packages--display-lists helm-system-packages--show-uninstalled-p nil reverse assoc helm-system-packages-extract-name] 8 (#$ . 166)]) #@37 List explicitly installed packages. (defalias 'helm-system-packages-brew-list-explicit #[0 "\300\301\302\303\"r\211q\210\304\305\"\216\306\307\310\303\310\311%\210\312 *\262!\207" [split-string generate-new-buffer " *temp*" t make-closure #[0 "\301\300!\205 \302\300!\207" [V0 buffer-name kill-buffer] 2] call-process "brew" nil "list" buffer-string] 8 (#$ . 485)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311&\207" [custom-declare-variable helm-system-packages-brew-column-width funcall function #[0 "\300\207" [40] 1] "Column at which descriptions are aligned, excluding a double-space gap.\nIf nil, then use `helm-system-packages-column-width'." :group helm-system-packages :type integer] 8) #@44 Cache all package names with descriptions. (defalias 'helm-system-packages-brew-cache #[0 "\300\211\301\302\303\"r\211q\210\304\305\"\216\306\307\300\310\300\311\312\313&\210\314 *\262\262\315\316\313#\262\317\320\321\322\"\322#\262\323\300\307$\207" [nil generate-new-buffer " *temp*" t make-closure #[0 "\301\300!\205 \302\300!\207" [V0 buffer-name kill-buffer] 2] call-process "brew" (t nil) "desc" "-s" "" buffer-string replace-regexp-in-string ":.*" mapconcat #[257 "\301\302\"\211@A@\303\304\"\303#\207" [helm-system-packages-column-width split-string ": " format "%%-%ds %%s"] 9 "\n\n(fn PACKAGE-FROM-LIST)"] split-string "\n" helm-system-packages--cache-set] 11 (#$ . 1201)]) #@27 Refresh the package list. (defalias 'helm-system-packages-brew-refresh #[0 "\306 \206\n\307 \211@\211A\210\310\211\207" [helm-system-packages--source-name helm-system-packages-brew-column-width helm-system-packages-column-width helm-system-packages--names helm-system-packages--descriptions helm-system-packages--display-lists "brew source" helm-system-packages-brew-cache nil] 2 (#$ . 1909) nil]) #@166 Print information about the selected packages. With prefix argument, insert the output at point. Otherwise display in `helm-system-packages-buffer'. (fn CANDIDATE) (defalias 'helm-system-packages-brew-info #[257 "\300\301\302\303\"r\211q\210\304\305\"\216\306\307\310\311\303\311\312\313\314 &\210\315 *\262!\311\211\211\316\314 \211\203\206\211@H\262\317\320\321\"\322\320\323\320\324 \"\"\325\320\326 \"\327\330\331\320\332\"\333#\334\330\331\320\335\"\333#\336\330\337\320\340\"\341#\342\320\343\"\341\260\262\344BDB\262T\262A\266\202\202'\210\345!\207" [json-read-from-string generate-new-buffer " *temp*" t make-closure #[0 "\301\300!\205 \302\300!\207" [V0 buffer-name kill-buffer] 2] apply call-process "brew" nil "info" "--json=v1" helm-marked-candidates buffer-string 0 "* Description: " alist-get desc "\n* Version: " stable versions "\n* URL: " homepage "\n\n* Dependencies:\n " mapconcat identity dependencies "\n " "\n\n* Optional dependencies:\n " optional_dependencies "\n\n* Options:\n" #[257 "\300\301\"\302\300\303\"\304R\207" [alist-get option "\n " description "\n"] 6 "\n\n(fn PKG-OPTION)"] options "\n" "\n\n* Caveats: " caveats uninstalled helm-system-packages-show-information] 24 (#$ . 2321)]) #@18 (fn CANDIDATE) (defalias 'helm-system-packages-brew-browse-url #[257 "\300\301\302\303\"r\211q\210\304\305\"\216\306\307\310\311\303\311\312\313\314 &\210\315 *\262!\316\317\320\"!\207" [json-read-from-string generate-new-buffer " *temp*" t make-closure #[0 "\301\300!\205 \302\300!\207" [V0 buffer-name kill-buffer] 2] apply call-process "brew" nil "info" "--json=v1" helm-marked-candidates buffer-string helm-system-packages-browse-url mapcar #[257 "\300\301\"\207" [alist-get homepage] 4 "\n\n(fn PKG)"]] 12 (#$ . 3591)]) #@18 (fn CANDIDATE) (defalias 'helm-system-packages-brew-link-app #[257 "\300\301\302\"\207" [helm-system-packages-brew-run "brew" "link"] 4 (#$ . 4130)]) #@18 (fn CANDIDATE) (defalias 'helm-system-packages-brew-unlink-app #[257 "\300\301\302\"\207" [helm-system-packages-brew-run "brew" "unlink"] 4 (#$ . 4288)]) #@222 COMMAND to run over `helm-marked-candidates'. COMMAND will be run in an Eshell buffer `helm-system-packages-eshell-buffer'. COMMAND is run without sudo as macOS brew does not require sudo rights. (fn COMMAND &rest ARGS) (defalias 'helm-system-packages-brew-run #[385 "\303\304!\210\305\306 \"B\262\307 \210\310 \203\311\312!\202<\313\314\315\316\317$\210\313\314\320\317\211$\210db\210\321\322\323#c\210\n\205<\324 )\207" [helm-system-packages-shell-buffer-name eshell-buffer-name helm-system-packages-auto-send-commandline-p require esh-mode append helm-marked-candidates eshell eshell-interactive-process message "A process is already running" add-hook eshell-post-command-hook helm-system-packages-refresh nil t #[0 "\300\301\302\303#\207" [remove-hook eshell-post-command-hook helm-system-packages-refresh t] 4] mapconcat identity " " eshell-send-input] 8 (#$ . 4451)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311&\207" [custom-declare-variable helm-system-packages-brew-actions funcall function #[0 "\300\207" [(("Show package(s)" . helm-system-packages-brew-info) ("Install (`C-u' to reinstall)" lambda (_) (if helm-current-prefix-arg (helm-system-packages-brew-run "brew" "reinstall") (helm-system-packages-brew-run "brew" "install"))) ("Uninstall (`C-u' to uninstall all versions)" lambda (_) (helm-system-packages-brew-run "brew" "uninstall" (when helm-current-prefix-arg "--force"))) ("Browse homepage URL" . helm-system-packages-brew-browse-url) ("Link application" . helm-system-packages-brew-link-app) ("Unlink application" . helm-system-packages-brew-unlink-app))] 1] "Actions for Helm brew." :group helm-system-packages :type (alist :key-type string :value-type function)] 8) #@29 Build Helm source for brew. (defalias 'helm-system-packages-brew-build-source #[0 "\302\303 \304\"\206 \305\306\307\310\311\312\313\314\315\316\317\320\321 &\207" [helm-system-packages-candidate-limit helm-system-packages-brew-actions plist-get helm-system-packages--cache-get :title "package manager" helm-make-source helm-source-in-buffer :init helm-system-packages-init :candidate-transformer helm-system-packages-brew-transformer :candidate-number-limit :display-to-real helm-system-packages-extract-name :persistent-help "Show package description" :action] 16 (#$ . 6172)]) #@32 Preconfigured `helm' for brew. (defalias 'helm-system-packages-brew #[0 "\301\302\303 \304\305\306\307\310\205\311\312\313!\206\314!&\207" [helm-system-packages-use-symbol-at-point-p helm :sources helm-system-packages-brew-build-source :buffer "*helm brew*" :truncate-lines t :input substring-no-properties thing-at-point symbol ""] 11 (#$ . 6761)]) (provide 'helm-system-packages-brew)