;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (require 'dap-mode) #@54 Unzip script to unzip vscode extension package file. (defconst dap-utils--ext-unzip-script "bash -c 'mkdir -p %2$s && unzip -qq %1$s -d %2$s'" (#$ . 107)) #@59 Powershell script to unzip vscode extension package file. (defconst dap-utils--ext-pwsh-script "powershell -noprofile -noninteractive -nologo -ex bypass Expand-Archive -path '%s' -dest '%s'" (#$ . 268)) (byte-code "\300\301\302\303\304DD\305\306\307\310\311&\207" [custom-declare-variable dap-utils-unzip-script funcall function #[0 "\302\303!\203\207\302\304!\203 \207\305\207" [dap-utils--ext-pwsh-script dap-utils--ext-unzip-script executable-find "powershell" "unzip" nil] 2] "The script to unzip vscode extension package file." :group dap-utils :type string] 8) #@60 Get extension from URL and extract to DEST. (fn URL DEST) (defalias 'dap-utils--get-extension #[514 "\301\302\303\304#\305\306#\210\307!\203\310\311\"\210\312\313#!\207" [dap-utils-unzip-script make-temp-file "ext" nil ".zip" url-copy-file overwrite file-exists-p delete-directory recursive shell-command format] 8 (#$ . 847)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311&\210\300\312\302\303\313DD\314\306\307\310\311&\210\300\315\302\303\316DD\317\306\307\310\320&\207" [custom-declare-variable dap-utils-vscode-ext-url funcall function #[0 "\300\207" [#1="https://marketplace.visualstudio.com/_apis/public/gallery/publishers/%s/vsextensions/%s/%s/vspackage"] 1 #1#] "Vscode extension template url." :group dap-utils :type string dap-utils-github-extension-url #[0 "\300\207" [#2="https://github.com/%s/%s/archive/v%s.zip"] 1 #2#] "Github extension template url." dap-utils-extension-path #[0 "\301\302\"\207" [user-emacs-directory expand-file-name ".extension"] 3] "Directory to store vscode extension." directory] 8) #@195 Get vscode extension from PUBLISHER named NAME. VERSION is the version of the extenssion, otherwise the latest. PATH is the download destination dir. (fn PUBLISHER NAME &optional VERSION PATH) (defalias 'dap-utils-get-vscode-extension #[1026 "\206\302\303$\206\304 \305\306 Q#\307\"\207" [dap-utils-vscode-ext-url dap-utils-extension-path "latest" format f-join "vscode" "." dap-utils--get-extension] 12 (#$ . 1900)]) #@137 Get extension from github named OWNER/REPO with VERSION. PATH is the download destination path. (fn OWNER REPO VERSION &optional PATH) (defalias 'dap-utils-get-github-extension #[1027 "\302$\206\303 \304\305Q#\306\"\207" [dap-utils-github-extension-url dap-utils-extension-path format f-join "github" "." dap-utils--get-extension] 11 (#$ . 2343)]) #@373 Helper to create DAPFILE setup function for vscode debug extension. PUBLISHER is the vscode extension publisher. NAME is the vscode extension name. PATH is the download destination dir. if VERSION is nil, use latest version from vscode marketplace. If CALLBACK is non nil, call it after download the extension. (fn DAPFILE PUBLISHER NAME &optional PATH VERSION CALLBACK) (defalias 'dap-utils-vscode-setup-function '(macro . #[1539 "\301Q\206 \302\303#\304\305\"\306\307\310\304\311 \"!\312\313\314\315\316\317 DE\320 \257\321\322EF\257\323\324DE\314\317D\321\325\n\257EF\207" [dap-utils-extension-path "." f-join "vscode" format "Downloading %s to path specified.\nWith prefix, FORCED to redownload the extension." progn defun intern "%s-setup" (&optional forced) (interactive "P") unless and (not forced) file-exists-p dap-utils-get-vscode-extension message "%s: Downloading done!" when funcall "%s: %s debug extension are not set. You can download it with M-x %s-setup"] 22 (#$ . 2712)])) #@320 Helper to create DAPFILE setup function for debug extension from github. OWNER is the github owner. REPO is the github repository. VERSION is the github extension version. PATH is the download destination dir. CALLBACK is the fn to be called after the download. (fn DAPFILE OWNER REPO VERSION &optional PATH CALLBACK) (defalias 'dap-utils-github-extension-setup-function '(macro . #[1540 "\301Q\206 \302\303#\304\305\"\306\307\310\304\311 \"!\312\313\314\315\316\317 DE\320 \257\321\322\f\323\322\324FF\322 \325BBE\326\327E\330\331DE\257\257\314\317D\326\332 \257EE\207" [dap-utils-extension-path "." f-join "github" format "Downloading %s to path specified.\nWith prefix, FORCED to redownload the extension." progn defun intern "%s-setup" (&optional forced) (interactive "P") unless and (not forced) file-exists-p dap-utils-get-github-extension rename-file concat "/" "-" ("/extension") message "%s: Downloading done!" when funcall "%s: %s debug extension are not set. You can download it with M-x %s-setup"] 26 (#$ . 3744)])) (provide 'dap-utils)