;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\210\303\304\305\306\307\310%\207" [require rx url-parse custom-declare-group gh-profile nil "Github profile." :group gh] 6) (defalias 'gh-profile-remote-regexp #[(domain) "\301\302\303\304\305\306Q\307\310\311\312\313\314BBBBBBE\315BBB!\207" [domain eval rx bol or "git@" ":" and (or "git" "ssh" "http" "https") "://" (* nonl) (32 "@") ("/") ((and (group (* nonl)) "/" (group (* nonl))) (32 ".git"))] 12]) #@121 List of profiles for Github access. List every Github Enterprise server and/or Github accounts you have access to here. (custom-declare-variable 'gh-profile-alist '`(("github" :url "https://api.github.com" :remote-regexp ,(gh-profile-remote-regexp "github.com"))) '(#$ . 531) :type '(alist :key-type string :value-type (plist :key-type (choice (const :url) (const :username) (const :password) (const :token) (const :remote-regexp)) :value-type string)) :group 'gh-profile) (defalias 'gh-profile-get-remote-regexp #[(profile) "\306 \"A\307\n\310\"\211\203 \2023\311\307\n\312\"!\313\f! >\204)\314\315\304\fD\"\210\f\316H\317!**\207" [profile gh-profile-alist profile-plist regexp url cl-struct-url-tags assoc plist-get :remote-regexp url-generic-parse-url :url type-of signal wrong-type-argument 4 gh-profile-remote-regexp host] 5]) #@73 Default profile. This needs to be a key present in `gh-profile-alist' (custom-declare-variable 'gh-profile-default-profile "github" '(#$ . 1381) :type 'string :group 'gh-profile) (defalias 'gh-profile-default-profile #[nil "\207" [gh-profile-default-profile] 1]) (defvar gh-profile-current-profile nil) (make-variable-buffer-local 'gh-profile-current-profile) (defalias 'gh-profile-current-profile #[nil "\206\301 \207" [gh-profile-current-profile gh-profile-default-profile] 1]) (defalias 'gh-profile-url #[nil "\301\302\303 \"A\304\"\207" [gh-profile-alist plist-get assoc gh-profile-current-profile :url] 4]) (defalias 'gh-profile-completing-read #[nil "\302\303\"\211G\304V\203\305\306 \307\310\307\211 @&\202 @)\207" [gh-profile-alist profiles mapcar car 1 completing-read "Github profile: " nil t] 9]) (defalias 'gh-profile-get-remote-profile #[(remote-url) "\306\211\307\306 :\2035 @\211\211A\242\310\311 !\n\"\203* \306\211\202+\307\2035 A\211\202 -\207" [gh-profile-alist #1=#:--cl-var-- props id #2=#:--cl-var-- #3=#:--cl-var-- nil t string-match gh-profile-get-remote-regexp remote-url] 4]) (provide 'gh-profile)