mirror of https://github.com/Chizi123/.emacs.d.git

Chizi123
2018-11-18 76bbd07de7add0f9d13c6914f158d19630fe2f62
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
;ELC
;;; Compiled
;;; in Emacs version 26.1
;;; 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!\207" [require ob shell cl-lib] 2)
(defvar org-babel-default-header-args:shell nil)
#@164 Define execution functions associated to shell names.
This function has to be called whenever `org-babel-shell-names'
is modified outside the Customize interface.
(defalias 'org-babel-shell-initialize #[0 "\211\205:\211@\301\302\303\304P!\305\306\307\"\310\311DC\312BB\257!\210\301\313\314\303\315P!D\316\306\317\"F!\210A\266\202\202\207" [org-babel-shell-names eval defun intern "org-babel-execute:" (body params) format "Execute a block of %s commands with Babel." let shell-file-name ((org-babel-execute:shell body params)) defalias quote "org-babel-variable-assignments:" 'org-babel-variable-assignments:shell "Return list of %s statements assigning to the block's variables."] 10 (#$ . 540) nil])
(byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313&    \207" [custom-declare-variable org-babel-shell-names funcall function #[0 "\300\207" [("sh" "bash" "csh" "ash" "dash" "ksh" "mksh" "posh")] 1] "List of names of shell supported by babel shell code blocks.\nCall `org-babel-shell-initialize' when modifying this variable\noutside the Customize interface." :group org-babel :type (repeat (string :tag "Shell name: ")) :set #[514 "\300\"\210\301 \207" [set-default org-babel-shell-initialize] 5 "\n\n(fn SYMBOL VALUE)"]] 10)
#@123 Execute a block of Shell commands with Babel.
This function is called by `org-babel-execute-src-block'.
 
(fn BODY PARAMS)
(defalias 'org-babel-execute:shell #[514 "\300\301\236A!\302\236A\211\205\303\304!!\262\305\236A\306\307!#\310\311%\312\313\236A\314    \236A\"\312\315    \236A\316\n\236A\"#\207" [org-babel-sh-initiate-session :session :stdin org-babel-sh-var-to-string org-babel-ref-resolve :cmdline org-babel-expand-body:generic org-babel-variable-assignments:shell org-babel-reassemble-table org-babel-sh-evaluate org-babel-pick-name :colname-names :colnames :rowname-names :rownames] 13 (#$ . 1800)])
#@93 Prepare SESSION according to the header arguments specified in PARAMS.
 
(fn SESSION PARAMS)
(defalias 'org-babel-prep-session:shell #[514 "\301!\302!\303!\204\304\305\"\210\306 \307\310\311\312\313!\314\"\315$\216rq\210\212\316\317\307\320\321\312\313!\322\"\323\324%\"\210,\210\207" [comint-input-filter org-babel-sh-initiate-session org-babel-variable-assignments:shell org-babel-comint-buffer-livep error "Buffer %s does not exist or has no process" match-data make-byte-code 0 "\301\300\302\"\207" vconcat vector [set-match-data evaporate] 3 #[257 "\300\207" [nil] 2 "\n\n(fn INPUT)"] mapc 257 "\211c\210\301\302\303\"\210\304\300!\207" [comint-send-input nil t org-babel-comint-wait-for-output] 4 "\n\n(fn VAR)"] 12 (#$ . 2435)])
#@51 Load BODY into SESSION.
 
(fn SESSION BODY PARAMS)
(defalias 'org-babel-load-session:shell #[771 "\300 \301\302\303\304\305!\306\"\307$\216\310\"r\211q\210\311\312p!!b\210\313!c\210)\211\262)\207" [current-window-configuration make-byte-code 0 "\301\300!\207" vconcat vector [set-window-configuration] 2 org-babel-prep-session:shell process-mark get-buffer-process org-babel-chomp] 10 (#$ . 3189)])
#@115 Returns a list of statements declaring the values as a generic variable.
 
(fn VARNAME VALUES &optional SEP HLINE)
(defalias 'org-babel--variable-assignments:sh-generic #[1026 "\300\301\302##\207" [format "%s=%s" org-babel-sh-var-to-sh] 11 (#$ . 3599)])
#@109 Returns a list of statements declaring the values as a bash array.
 
(fn VARNAME VALUES &optional SEP HLINE)
(defalias 'org-babel--variable-assignments:bash_array #[1026 "\300\301\211\302\303\304\305\306\307  \"\310\"\311\312%\313#$\207" [format "unset %s\ndeclare -a %s=( %s )" mapconcat make-byte-code 257 "\302\300\301#\207" vconcat vector [org-babel-sh-var-to-sh] 5 "\n\n(fn VALUE)" " "] 16 (#$ . 3866)])
#@119 Returns a list of statements declaring the values as bash associative array.
 
(fn VARNAME VALUES &optional SEP HLINE)
(defalias 'org-babel--variable-assignments:bash_assoc #[1026 "\300\301\211\302\303\304\305\306\307 \f\f#\310\"\311\312%\313#$\207" [format "unset %s\ndeclare -A %s\n%s" mapconcat make-byte-code 257 "\303\304\300\305@\301\302#\305A\301\302#$\207" vconcat vector [format "%s[%s]=%s" org-babel-sh-var-to-sh] 9 "\n\n(fn ITEMS)" "\n"] 17 (#$ . 4287)])
#@100 Represents the parameters as useful Bash shell variables.
 
(fn VARNAME VALUES &optional SEP HLINE)
(defalias 'org-babel--variable-assignments:bash #[1026 ":\2036@\211:\203/\211A\211:\203 \300$\202*\301$\262\2025\301$\207\302$\207" [org-babel--variable-assignments:bash_assoc org-babel--variable-assignments:bash_array org-babel--variable-assignments:sh-generic] 11 (#$ . 4767)])
#@79 Return list of shell statements assigning the block's variables.
 
(fn PARAMS)
(defalias 'org-babel-variable-assignments:shell #[257 "\300\236A\301\236A\302\230\205\303\236A\206\304\305\306\307\310\311\312\"\313\"\314\315%\316!\"\207" [:separator :hlines "yes" :hline-string "hline" mapcar make-byte-code 257 "\303\304\n\"\203\305@A\300\301$\207\306@A\300\301$\207" vconcat vector [shell-file-name string-suffix-p "bash" org-babel--variable-assignments:bash org-babel--variable-assignments:sh-generic] 6 "\n\n(fn PAIR)" org-babel--get-vars] 11 (#$ . 5184)])
#@164 Convert an elisp value to a shell variable.
Convert an elisp var into a string of shell commands specifying a
var of the same value.
 
(fn VAR &optional SEP HLINE)
(defalias 'org-babel-sh-var-to-sh #[769 "\300\301\300\302\303##\300Q\207" ["'" replace-regexp-in-string "'\"'\"'" org-babel-sh-var-to-string] 11 (#$ . 5766)])
#@67 Convert an elisp value to a string.
 
(fn VAR &optional SEP HLINE)
(defalias 'org-babel-sh-var-to-string #[769 "\300<\203&@<\204@\301=\203&\302\303\206\304\305\306\257\"\2026<\2033\307\310#\2026\211!\207" [#[257 "\211;\203\207\300\301\"\207" [format "%S"] 4 "\n\n(fn V)"] hline orgtbl-to-generic :sep "    " :fmt :hline mapconcat "\n"] 12 (#$ . 6100)])
#@86 Initiate a session named SESSION according to PARAMS.
 
(fn &optional SESSION PARAMS)
(defalias 'org-babel-sh-initiate-session #[512 "\205.\301\230?\205.\302 \303\304\305\306\307!\310\"\311$\216\312!\206+\313!\210`\314\223\210\315p!)\262\207" [comint-last-output-start "none" current-window-configuration make-byte-code 0 "\301\300!\207" vconcat vector [set-window-configuration] 2 org-babel-comint-buffer-livep shell nil get-buffer] 9 (#$ . 6480)])
#@51 String to indicate that evaluation has completed.
(defvar org-babel-sh-eoe-indicator "echo 'org_babel_sh_eoe'" (#$ . 6945))
#@51 String to indicate that evaluation has completed.
(defvar org-babel-sh-eoe-output "org_babel_sh_eoe" (#$ . 7075))
#@268 Pass BODY to the Shell process in BUFFER.
If RESULT-TYPE equals `output' then return a list of the outputs
of the statements in BODY, if RESULT-TYPE equals `value' then
return the value of the last statement in BODY.
 
(fn SESSION BODY &optional PARAMS STDIN CMDLINE)
(defalias 'org-babel-sh-evaluate #[1282 "\204\211\203\301\306\307!\306\310!\311\236A\312\236A\313\230?\314\315\316!!\317\320\321\322\323!\324\"\325$\216r\211q\210\2039\326Pc\210\203@\326c\210    c\210)r\211q\210\327\330\211\330\320%\210*\266\331\332\"\210\314\315\316!!\317\320\321\322\323!\333\"\325$\216r\211q\210\206u\334c\210)r\211q\210\327\330\211\330\320%\210*\266\335\336!r\211q\210\317\320\321\322\323!\337\"\325$\216\340\203\243\202\251\341\342#\205\262\343PPp#\210\344 *\262\266\204\202\375\203\211\345\346\347\350\351\352\n!\204\327\353\354 \"\210\355 \317\320\356\322\323!\357\"\360$\216r\nq\210\212\361\334C\317\362\363\322\323!\364\"\365\366%\nB\330\367\370p!!b\210`d{\262|\266\371\372\373\374\350!\326\" C\"\"\210\fb\210\212\375\376 !\330\377#\2055\375@\330\377#)\204D\201A\370p!!\210\202!\367\370p!!b\210\211c\210 \203u\201B\201C\326\201D\376\206d\334!#\242\"\203u\211\242\320\225\330O\240\210\374\242@\")\266\202,\262\325\"\"\326#\202\375\311\236A\203\364\311\236AG\320V\203\364\306\307!\311\236A\312\236A\313\232?\314\315\316!!\317\320\321\322\323!\201E\"\325$\216r\211q\210\203\311\326Pc\210\203\320\326c\210c\210)r\211q\210\327\330\211\330\320%\210*\266\331\332\"\210\201F\334\"\266\203\202\375\201F\350!\"\211\205\250\201G\236A\211\201H\235?\205\244\201I\235\204i\201J\235\204i\201K\235\204i\201L\235\204i\201M\235\204i\201N\235\204i\201O\235\204a\201P\235\204a\201Q\235\204a\201R\235\203m\201S\235\204m\202\244\306\201T!\211\314\315\316!!\317\320\321\322\323!\201U\"\325$\216r\211q\210c\210)r\211q\210\327\330\211\330\320%\210*\266\201V!\262\262\262\207" [shell-file-name comint-input-filter comint-output-filter-functions org-babel-sh-eoe-indicator comint-last-input-end org-babel-sh-eoe-output org-babel-temp-file "sh-script-" "sh-stdin-" :shebang :padline "no" get-buffer-create generate-new-buffer-name " *temp file*" make-byte-code 0 "\301\300!\205    \302\300!\207" vconcat vector [buffer-name kill-buffer] 2 "\n" write-region nil set-file-modes 493 [buffer-name kill-buffer] "" generate-new-buffer " *temp*" [buffer-name kill-buffer] call-process-shell-command format "%s %s" " " buffer-string mapconcat org-babel-sh-strip-weird-long-prompt mapcar org-trim butlast org-babel-comint-buffer-livep error "Buffer %s does not exist or has no process" match-data "\301\300\302\"\207" [set-match-data evaporate] 3 #[257 "\300\207" [nil] 2 "\n\n(fn INPUT)"] 257 "\300\211\242P\240\207" [] 4 "\n\n(fn TEXT)" process-mark get-buffer-process mapc #[257 "\211c\210\302\303\304\"\210\212b\210\305    \303\304#)?\205\306\307p!!\210\202\207" [comint-last-input-end comint-prompt-regexp comint-send-input nil t re-search-forward accept-process-output get-buffer-process] 5 "\n\n(fn LINE)"] append split-string re-search-forward regexp-quote t comint-prompt-regexp accept-process-output string-match replace-regexp-in-string "[ \n]+" [buffer-name kill-buffer] org-babel-eval :result-params "none" "scalar" "verbatim" "html" "code" "pp" "file" "output" "raw" "org" "drawer" "table" "sh-" [buffer-name kill-buffer] org-babel-import-elisp-from-file] 19 (#$ . 7196)])
#@65 Remove prompt cruft from a string of shell output.
 
(fn STRING)
(defalias 'org-babel-sh-strip-weird-long-prompt #[257 "\300\301\"\203\211\302\225\303O\262\202\207" [string-match "^% +[ \n$]+ *" 0 nil] 4 (#$ . 10700)])
(provide 'ob-shell)