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



(byte-code "\300\301!\210\302 \303\232\204 \304\305\306\"\210\300\307!\210\300\301!\210\300\310!\207" [require org-macs org-release "9.6.15" warn "Org version mismatch.\nThis warning usually appears when a built-in Org version is loaded\nprior to the more recent Org version.\n\nVersion mismatch is commonly encountered in the following situations:\n\n1. Emacs is loaded using literate Org config and more recent Org\n   version is loaded inside the file loaded by `org-babel-load-file'.\n   `org-babel-load-file' triggers the built-in Org version clashing\n   the newer Org version attempt to be loaded later.\n\n   It is recommended to move the Org loading code before the\n   `org-babel-load-file' call.\n\n2. New Org version is loaded manually by setting `load-path', but some\n   other package depending on Org is loaded before the `load-path' is\n   configured.\n   This \"other package\" is triggering built-in Org version, again\n   causing the version mismatch.\n\n   It is recommended to set `load-path' as early in the config as\n   possible.\n\n3. New Org version is loaded using straight.el package manager and\n   other package depending on Org is loaded before straight triggers\n   loading of the newer Org version.\n\n   It is recommended to put\n\n    %s\n\n   early in the config.  Ideally, right after the straight.el\n   bootstrap.  Moving `use-package' :straight declaration may not be\n   sufficient if the corresponding `use-package' statement is\n   deferring the loading.\n\n4. A new Org version is synchronized with Emacs git repository and\n   stale .elc files are still left from the previous build.\n\n   It is recommended to remove .elc files from lisp/org directory and\n   re-compile." "(straight-use-package 'org)" cl-lib org-compat] 3)#@295 Alist containing all macro templates in current buffer.
Associations are in the shape of (NAME . TEMPLATE) where NAME
stands for macro's name and template for its replacement value,
both as strings.  This is an internal variable.  Do not set it
directly, use instead:

  #+MACRO: name template
(defvar org-macro-templates nil (#$ . 1856))
(make-variable-buffer-local 'org-macro-templates)#@64 Compute the formal arglist to use for TEMPLATE.

(fn TEMPLATE)
(defalias 'org-macro--makeargs #[257 "\300\211\301\302#\203 \300\225\262\303\304\305\"!]\262\202 \306\305W\203$ \207\300V\203; \307\310\311\"!B\262S\262\202$ \312B\207" [0 string-match "\\$\\([0-9]+\\)" string-to-number match-string 1 (&rest _) intern format "$%d" &optional] 8 (#$ . 2250)])#@175 Set template for the macro NAME.
VALUE is the template of the macro.  The new value override the
previous one, unless VALUE is nil.  Return the updated list.

(fn TEMPLATES)
(defalias 'org-macro--set-templates #[257 "\300\211\203l \211@\211\242\243\211\301\";\203C \302\300\303\304$\266\203\203C \305!\30615 \307!A@0\202; \210\310\311\"\312E\262\266\203S \211\203S \211\241\266\202e \211\204c \206] \313BB\262\266A\266\202\202 \210\207" [nil assoc "\\`(eval\\>" string-match t org-macro--makeargs (error) read user-error "Invalid definition for macro %S" lambda ""] 16 (#$ . 2628)])#@116 Collect macro definitions in current buffer and setup files.
Return an alist containing all macro templates found.
(defalias 'org-macro--collect-macros #[0 "\300\301\302\303\"B\304\301\305!B\306\301\307\303\"B\310\311 BF\312\313!\211:\203b \211\242\211:\203a \211\242\211\314\232\203` \243\243\211\204^ \211\203] \211@\315\316\"\203V \317\320\"\321\225\322OB\nB\262\n\266A\266\202\2026 \210\266\210\210\210\207" ["author" org-macro--find-keyword-value "AUTHOR" t "email" "EMAIL" "title" "TITLE" "date" org-macro--find-date org-collect-keywords ("MACRO") "MACRO" string-match "^\\(\\S-+\\)[ 	]*" match-string 1 0 nil] 12 (#$ . 3246)])#@416 Collect macro templates defined in current buffer.

DEFAULT is a list of globally available templates.

Templates are stored in buffer-local variable `org-macro-templates'.

In addition to buffer-defined macros, the function installs the
following ones: "n", "author", "email", "keyword",
"time", "property", and, if the buffer is associated to
a file, "input-file" and "modification-time".

(fn &optional DEFAULT)
(defalias 'org-macro-initialize-templates #[256 "\301\302!\210\303 \210\304\305\306 \"!\307\310 !\211\2054 \311!\2054 \312\313!B\314\315!\3168\262\317\320#\262BD\262\244\321\244\211\207" [org-macro-templates require org-element org-macro--counter-initialize org-macro--set-templates append org-macro--collect-macros buffer-file-name buffer-base-buffer file-exists-p "input-file" file-name-nondirectory "modification-time" file-attributes 5 make-closure #[641 "\302\303!\203 \304\301!\206 \300\"\207" [V0 V1 format-time-string org-string-nw-p org-macro--vc-modified-time] 7 "\n\n(fn ARG1 &optional ARG2 &rest _)"] (("keyword" lambda (arg1 &rest _) (org-macro--find-keyword-value arg1 t)) ("n" lambda (&optional arg1 arg2 &rest _) (org-macro--counter-increment arg1 arg2)) ("property" lambda (arg1 &optional arg2 &rest _) (org-macro--get-property arg1 arg2)) ("time" lambda (arg1 &rest _) (format-time-string arg1)))] 10 (#$ . 3898)])#@285 Return expanded MACRO, as a string.
MACRO is an object, obtained, for example, with
`org-element-context'.  TEMPLATES is an alist of templates used
for expansion.  See `org-macro-templates' for a buffer-local
default value.  Return nil if no template was found.

(fn MACRO TEMPLATES)
(defalias 'org-macro-expand #[514 "\300\301\302\"\303#A\211\2053 \304!\203 \305\301\306\"\"\202) \307\310\311\312\"\313\314%\315\316\2060 \317\"\262\207" [assoc-string org-element-property :key t functionp apply :args replace-regexp-in-string "\\$[0-9]+" make-closure #[257 "\301\302\303O!S\304\305\300\"8\206 \306\207" [V0 string-to-number 1 nil org-element-property :args #1=""] 5 "\n\n(fn M)"] nil literal format "%s" #1#] 9 (#$ . 5268)])#@414 Replace all macros in current buffer by their expansion.

TEMPLATES is an alist of templates used for expansion.  See
`org-macro-templates' for a buffer-local default value.

Optional argument KEYWORDS, when non-nil is a list of keywords,
as strings, where macro expansion is allowed.

Return an error if a macro in the buffer cannot be associated to
a definition in TEMPLATES.

(fn TEMPLATES &optional KEYWORDS)
(defalias 'org-macro-replace-all #[513 "\212\214~\210eb\210\300\301\302!\"\303\304\305\303\306#\205\330 \307 \310\311\"\216\312 )\262\204 \307 \310\313\"\216\314 )\262\315!\211\316=\203> \202l \211\317=\203M \320\321\"\235\204d \211\322=\205l \320\321\"\303\323\306$\266\203\205l \212\324\224b\210\325 )\211\203\323 \326!\262\327\330\303#\210\320\321\"\331	\"\320\332\"\211\320\333\"E\211\235\203\240 \334\335\"\266\202 \203\302 \211B\262\320\336\"b\210\337\303x\210`|\210\212c)\266\202 \340\232\204\321 \334\341\320\321\"\"\210\266\266\202 \266\202*\207" [format "\\`EXPORT_%s\\+?\\'" regexp-opt nil re-search-forward "{{{[-A-Za-z0-9_]" t match-data make-closure #[0 "\301\300\302\"\207" [V0 set-match-data t] 3] org-in-commented-heading-p #[0 "\301\300\302\"\207" [V0 set-match-data t] 3] org-element-context org-element-type macro keyword org-element-property :key node-property string-match 0 org-element-macro-parser cl-copy-list org-element-put-property :parent org-macro-expand :begin :args error "Circular macro expansion: %s" :end " 	" "results" "Undefined Org macro: %s; aborting"] 16 (#$ . 6014)])#@219 Build macro's arguments string from ARGS.
ARGS are strings.  Return value is a string with arguments
properly escaped and separated with commas.  This is the opposite
of `org-macro-extract-arguments'.

(fn &rest ARGS)
(defalias 'org-macro-escape-arguments #[128 "\300\301!\211\2033 \211@\302\303\304\305\300\232?\205$ \306\307\"\205$ \310\311\"P\312\313%Q\262A\266\202\202 \314\312O\207" ["" reverse "," replace-regexp-in-string "\\(\\\\*\\)," #[257 "\300\301\302\303\"G_T\304\"\305P\207" [make-string 2 match-string 1 92 ","] 6 "\n\n(fn M)"] string-match "\\\\+\\'" match-string 0 nil t 1] 12 (#$ . 7588)])#@209 Extract macro arguments from string S.
S is a string containing comma separated values properly escaped.
Return a list of arguments, as strings.  This is the opposite of
`org-macro-escape-arguments'.

(fn S)
(defalias 'org-macro-extract-arguments #[257 "\300\301\302\303\304\305%\306\"\207" [split-string replace-regexp-in-string "\\(\\\\*\\)," #[257 "\300\301\"G\302\303\245\304\"\305\303\"\306U\203 \307\202 \310P\207" [match-string 1 make-string 2 92 mod 0 " " ","] 6 "\n\n(fn STR)"] nil t " "] 8 (#$ . 8216)])#@167 Find PROPERTY's value at LOCATION.
PROPERTY is a string.  LOCATION is a search string, as expected
by `org-link-search', or the empty string.

(fn PROPERTY LOCATION)
(defalias 'org-macro--get-property #[514 "\212\301!\203 \3021 \303\304\305\303#)0\210\202 \306\307\"\266\310\305\311#)\207" [org-link-search-must-match-exact-headline org-string-nw-p (error) t org-link-search nil error "Macro property failed: cannot find location %s" org-entry-get selective] 6 (#$ . 8742)])#@281 Find value for keyword NAME in current buffer.
Return value associated to the keywords named after NAME, as
a string, or nil.  When optional argument COLLECT is non-nil,
concatenate values, separated with a space, from various keywords
in the buffer.

(fn NAME &optional COLLECT)
(defalias 'org-macro--find-keyword-value #[513 "\212\301\302!\203\f \303\302!q\210\212\214~\210\302b\210\304\305\306!\"\307\310\3112\213 \312\310\307#\203p \313\224\212\301!\2037 \303!q\210\212\214~\210\211\206@ `b\210\314\315 \313\224C\"+\262\316!\317=\203l \320\321\"\204e \322\311\"\266\202! \323Q\262\210\210\202! \211\205\212 \211\310\324\203 \325\202\200 \326\327\324\330\327##\266\2020)\266\203+\207" [case-fold-search markerp 1 marker-buffer format "^[ 	]*#\\+%s:" regexp-quote t nil :exit re-search-forward 0 org-element-keyword-parser line-end-position org-element-type keyword org-element-property :value throw " " replace-regexp-in-string "\\`\\([ 	]*\n\\)+" "\\`[ 	\n]+" "" "[ 	\n]+\\'"] 14 (#$ . 9232)])#@66 Find value for DATE in current buffer.
Return value as a string.
(defalias 'org-macro--find-date #[0 "\300\301!\302\303\304!\"\211:\203( \211A\204( \305@!\306=\203( \307\310\307\311\312@!\"#\207\207" [org-macro--find-keyword-value "DATE" org-element-parse-secondary-string org-element-restriction keyword org-element-type timestamp format "(eval (if (org-string-nw-p $1) %s %S))" "(org-format-timestamp '%S $1)" org-element-copy] 8 (#$ . 10256)])#@13 

(fn FILE)
(defalias 'org-macro--vc-modified-time #[257 "\301\302!\210\303 \304\305\"\216\306!\205R \307\310!\311\312C\304\313\"\216C\314\306!\315\312\211\316&\266rq\210\317\304\320\"!)\210\321!\211\203K \322\323\312\311$\204> )\210\211\242)\266\203)\207" [case-fold-search require vc current-window-configuration make-closure #[0 "\301\300!\207" [V0 set-window-configuration] 2] vc-backend get-buffer-create " *org-vc*" t nil #[0 "\301\300!\207" [V0 kill-buffer] 2] vc-call-backend print-log 1 vc-exec-after #[0 "eb\210\301\302\303\304#\205 \305`\306 {!\307\310\"\205 \300\311!\240\262\207" [V0 re-search-forward "Date:?[ 	]*" nil t parse-time-string line-end-position cl-some identity encode-time] 4] get-buffer-process accept-process-output 0.5] 14 (#$ . 10713)])#@47 Hash table containing counter value per name.
(defvar org-macro--counter-table nil (#$ . 11507))#@40 Initialize `org-macro--counter-table'.
(defalias 'org-macro--counter-initialize #[0 "\301\302\303\"\211\207" [org-macro--counter-table make-hash-table :test equal] 3 (#$ . 11609)])#@361 Increment counter NAME.
NAME is a string identifying the counter.

When non-nil, optional argument ACTION is a string.

If the string is "-", keep the NAME counter at its current
value, i.e. do not increment.

If the string represents an integer, set the counter to this number.

Any other non-empty string resets the counter to 1.

(fn NAME &optional ACTION)
(defalias 'org-macro--counter-increment #[513 ";\203 \301\302\203 \303\202 \304\305\302\306\305##\266\202\202 \305\307!\205; \301\302\2030 \303\2021 \304\305\302\306\305##\266\202\310\307!\204L \311\312#T\202o \313\230\203Z \311\314#\202o \315\301\316\317$\266\203\203n \320!\202o \314#\207" [org-macro--counter-table nil replace-regexp-in-string "\\`\\([ 	]*\n\\)+" "\\`[ 	\n]+" "" "[ 	\n]+\\'" org-string-nw-p puthash gethash 0 "-" 1 "\\`[0-9]+\\'" string-match t string-to-number] 14 (#$ . 11797)])
(provide 'org-macro)
