;ELC ;;; Compiled ;;; in Emacs version 26.3 ;;; 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. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; #@36 The location of persist directory. (defvar persist--directory-location (locate-user-emacs-file "persist") (#$ . 408)) #@29 List of symbols to persist. (defvar persist--symbols nil (#$ . 532)) #@197 Special hook run on loading a variable. Hook functions are called with two values: the symbol and the value it will be set to. If any function returns nil, the variable is not set to the value. (defvar persist-load-hook nil (#$ . 608)) #@73 Return the file name at which SYMBOL does or will persist. (fn SYMBOL) (defalias 'persist--file-location #[257 "\301\302!\303N\206 \"\207" [persist--directory-location expand-file-name symbol-name persist-location] 5 (#$ . 852)]) #@54 Set symbol up for persistance. (fn SYMBOL LOCATION) (defalias 'persist--defvar-1 #[514 "\211\203 \300\"\210\301\211J\"\210\302!\207" [persist-location persist-symbol persist-load] 5 (#$ . 1093)]) #@308 Define SYMBOL as a persistant variable and return SYMBOL. This form is nearly equivalent to `defvar', except that the variable persists between Emacs sessions. It does not support the optional parameters. Both INITVALUE and DOCSTRING need to be given. (fn SYMBOL INITVALUE DOCSTRING &optional LOCATION) (defalias 'persist-defvar '(macro . #[1027 "\300\301F\302\303DE\303DF\207" [progn defvar persist--defvar-1 quote] 9 (#$ . 1302)])) (byte-code "\300\301\302\303#\210\304\301\305\306#\300\207" [put persist-defvar edebug-form-spec (symbolp form stringp &optional form) function-put doc-string-elt 3] 4) #@250 Set the directory for persisting the value of symbol. This does not force the loading of value from this directory, so to persist a variable, you will normally need to call `persist-load' to load a previously saved location. (fn SYMBOL DIRECTORY) (defalias 'persist-location #[514 "\300\301\302!#\207" [put persist-location expand-file-name] 7 (#$ . 1924)]) #@482 Make SYMBOL a persistant variable. If non-nil, INITVALUE is the value to which SYMBOL will be set if `persist-reset' is called. Otherwise, the INITVALUE will be the current `symbol-value' of SYMBOL. INITVALUE is set for the session and will itself not persist across sessions. This does force the loading of value from this directory, so to persist a variable, you will normally need to call `persist-load' to load a previously saved location. (fn SYMBOL &optional INITVALUE) (defalias 'persist-symbol #[513 "\211\206J\235\203\210\202B\301\302\303#\210\301\304#\207" [persist--symbols put persist t persist-default] 7 (#$ . 2293)]) #@65 Return non-nil if SYMBOL is a persistant variable. (fn SYMBOL) (defalias 'persist--persistant-p #[257 "\211\300N\207" [persist] 3 (#$ . 2952)]) #@147 Save SYMBOL now. Normally, it should not be necessary to call this explicitly, as variables persist automatically when Emacs exits. (fn SYMBOL) (defalias 'persist-save #[257 "\300!\204 \301\302\303\"!\210\211J\304!\232?\205L\305\306!!\307!\204&\310!\210\210\311\312!r\211q\210\313\314\315\316\317!\320\"\321$\216\322Jp\"\210\323ed\306!\324\325%*\262\207" [persist--persistant-p error format "Symbol %s is not persistant" persist-default file-name-directory persist--file-location file-exists-p mkdir generate-new-buffer " *temp*" make-byte-code 0 "\301\300!\205 \302\300!\207" vconcat vector [buffer-name kill-buffer] 2 print write-region nil quiet] 8 (#$ . 3104)]) #@51 Return the default value for SYMBOL. (fn SYMBOL) (defalias 'persist-default #[257 "\211\300N\207" [persist-default] 3 (#$ . 3792)]) #@56 Reset the value of SYMBOL to the default. (fn SYMBOL) (defalias 'persist-reset #[257 "\211\300!L\207" [persist-default] 4 (#$ . 3931)]) #@46 Load the saved value of SYMBOL. (fn SYMBOL) (defalias 'persist-load #[257 "\300\301!!\2054\302\303!r\211q\210\304\305\306\307\310!\311\"\312$\216\313\301!!\210\314p!\315\316#\205/L\262*\262\207" [file-exists-p persist--file-location generate-new-buffer " *temp*" make-byte-code 0 "\301\300!\205 \302\300!\207" vconcat vector [buffer-name kill-buffer] 2 insert-file-contents read run-hook-with-args-until-failure persist-load-hook] 8 (#$ . 4075)]) #@105 Stop the value in SYMBOL from persisting. This does not remove any saved value of SYMBOL. (fn SYMBOL) (defalias 'persist-unpersist #[257 "\301\302\303#\210\304\"\211\207" [persist--symbols put persist nil remove] 5 (#$ . 4542)]) #@30 Save all persistant symbols. (defalias 'persist--save-all #[0 "\301\302\"\207" [persist--symbols mapc persist-save] 3 (#$ . 4783)]) (byte-code "\300\301\302\"\210\303\304!\207" [add-hook kill-emacs-hook persist--save-all provide persist] 3)