;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. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (require 'ol) #@27 The IRC client to act on. (defvar org-irc-client 'erc (#$ . 422)) #@75 Non-nil will store a link to the logs, nil will store an irc: style link. (defvar org-irc-link-to-logs nil (#$ . 494)) (org-link-set-parameters "irc" :follow 'org-irc-visit :store 'org-irc-store-link :export 'org-irc-export) #@89 Parse LINK and dispatch to the correct function based on the client found. (fn LINK _) (defalias 'org-irc-visit #[514 "\301!\302=\203\303!\202\304\305!\207" [org-irc-client org-irc-parse-link erc org-irc-visit-erc error "ERC only known client"] 5 (#$ . 725)]) #@222 Parse an IRC LINK and return the attributes found. Parse a LINK that looks like server:port/chan/user (port, chan and user being optional) and return any of the port, channel or user attributes that are found. (fn LINK) (defalias 'org-irc-parse-link #[257 "\300\301\302#\211G\211\303W\204\211\304V\203\305\306\"\210\300@\307\302#\240\210\207" [split-string "/" t 1 3 error "Failed to parse link needed 1-3 parts, got %d" ":"] 8 (#$ . 1000)]) #@73 Dispatch to the appropriate function to store a link to an IRC session. (defalias 'org-irc-store-link #[0 "\301=\205\302 \207" [major-mode erc-mode org-irc-erc-store-link] 2 (#$ . 1458)]) #@208 Remove unnecessary white space from STRING and add ellipses if necessary. Strip starting and ending white space from STRING and replace any chars that the value AFTER with `...' (fn STRING &optional AFTER) (defalias 'org-irc-ellipsify-description #[513 "\300\206\301!\302\303B\304\303B\305\306Q\307BE\211\211\2035\211@\310@\"\203.\311A\312\211 $\262A\266\202\202\262\207" [number-to-string 30 "^[ ]*" "" "[ ]*$" "^\\(.\\{" "\\}\\).*" "\\1..." string-match replace-match nil] 11 (#$ . 1656)]) #@267 Find the best line to link to from the ERC logs given ERC-LINE as a start. If the user is on the ERC-prompt then search backward for the first non-blank line, otherwise return the current line. The result is a cons of the filename and search string. (fn ERC-LINE) (defalias 'org-irc-erc-get-line-from-log #[257 "\301 \210\302\303!\210r\304\305 !q\210db\210\306!\307 \230\2030\310 b\210\311\312\313\314#\205>\315\310 \316 \"\202>\317\313\314#\205>\315\310 \316 \")D\207" [buffer-file-name erc-save-buffer-in-logs require erc-log find-file-noselect erc-current-logfile abbreviate-file-name erc-prompt point-at-bol search-backward-regexp "^[^ ]" nil t buffer-substring-no-properties point-at-eol search-backward] 6 (#$ . 2175)]) #@205 Store a link to the IRC log file or the session itself. Depending on the variable `org-irc-link-to-logs' store either a link to the log file for the current session or an irc: link to the session itself. (defalias 'org-irc-erc-store-link #[0 "\302\303!\210\203;\304\305 \306 \"\307!\310\311!\2037\312\313\314\315\316\317A@\320\"\321Q\322\323@\324 A@R&\210\325\202:\326\327!\207\330 \331!\203v\312\313\332\322\333P\315\334\316Q\335@@\336\337 \211A\262 \242A@!\206g \340\f\211A\262\242&\f\210\325\202y\326\341!\207" [org-irc-link-to-logs erc-default-port require erc-log buffer-substring-no-properties point-at-bol point-at-eol org-irc-erc-get-line-from-log erc-logging-enabled nil org-link-store-props :type "file" :description "'" org-irc-ellipsify-description 20 "' from an IRC conversation" :link "file:" "::" t error "This ERC session is not being logged" org-irc-get-erc-link org-irc-parse-link "irc" "irc:/" "irc session `" :server :port string-to-number :nick "Failed to create ('irc:/' style) ERC link"] 16 (#$ . 2917)]) #@57 Return an org compatible irc:/ link from an ERC buffer. (defalias 'org-irc-get-erc-link #[0 "\247\203 \302!\202\f \303Q\211\304\305 \2035\306\305 !\2035\307`\310\"@\2035\307`\310\"@\305 \304Q\262\2027\305 Q\207" [erc-session-port erc-session-server number-to-string ":" "/" erc-default-target erc-channel-p get-text-property erc-data] 8 (#$ . 3976)]) #@113 Return the current port as a number. Return the current port number or, if none is set, return the ERC default. (defalias 'org-irc-get-current-erc-port #[0 ";\203 \302!\207\247\203\207 \207" [erc-session-port erc-default-port string-to-number] 2 (#$ . 4346)]) #@65 Visit an ERC buffer based on criteria found in LINK. (fn LINK) (defalias 'org-irc-visit-erc #[257 "\302\303!\210\302\304!\210\211@@\211A\262\242A@\211\203\305!\202\262\306\307\310\311\312\313\314\"\315\"\316$!\211\203\243\211A\262\242\211\203\233\3172b\211\205_\211@\320!\230\203X\321\317\"\210A\266\202\202E\2620\211\203\217\322!\210\211A\262\242\211\205\212\211\323 \235\203\205db\210\211\324Pc\202\212\325\326#\262\202\226\322 !\210\327!\262\202\236\322 !\262\202\251\330\331\332$)\207" [erc-default-port server-buffer require erc erc-log string-to-number nil erc-buffer-filter make-byte-code 0 "\304 \211\205r\211q\210\305 \301=\205\n\300\230\205\211\211)\207" vconcat vector [erc-session-server server-buffer erc-server-buffer org-irc-get-current-erc-port] 3 found buffer-name throw pop-to-buffer-same-window erc-get-server-nickname-list ": " error "%s not found in %s" erc-cmd-JOIN erc-select :server :port] 11 (#$ . 4619)]) #@125 Export an IRC link. See `org-link-parameters' for details about LINK, DESCRIPTION and FORMAT. (fn LINK DESCRIPTION FORMAT) (defalias 'org-irc-export #[771 "\206\300=\203\301\302#\202#\303=\203\"\301\304#\202#\305\207" [html format "%s" md "[%s](irc:%s)" nil] 8 (#$ . 5611)]) (provide 'ol-irc)