;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\210\300\303!\210\300\304!\210\300\305!\210\300\306!\210\307\310\311\312\313\306\314\315&\210\316\317\320\321\322DD\323\324\325\313\310\314\326& \210\316\327\320\321\330DD\331\324\332\313\310\314\333& \210\316\334\320\321\335DD\336\324\337\313\310\314\340& \210\316\341\320\321\342DD\343\324\332\313\310\314\344& \210\316\345\320\321\346DD\347\324\332\313\310\314\350& \210\316\351\320\321\352DD\353\324\354\313\310\314\355& \210\316\356\320\321\357DD\360\324\332\313\310\314\361& \210\316\362\320\321\363DD\364\324\332\313\310\314\365& \210\316\366\320\321\367DD\370\324\332\313\310\314\371& \210\316\372\320\321\373DD\374\324\375\313\310\314\376& \210\316\377\320\321\201@DD\201A\324\332\313\310\314\201B& \210\316\201C\320\321\201DDD\201E\324\332\313\310\314\201F& \210\316\201G\320\321\201HDD\201I\324\332\313\310\314\201J& \210\316\201K\320\321\201LDD\201M\324\332\313\310\314\201N& \210\316\201O\320\321\201PDD\201Q\324\332\313\310\314\201R& \210\316\201S\320\321\201TDD\201U\324\332\313\310\314\201V& \210\316\201W\320\321\201XDD\201Y\324\332\313\310\314\201Z& \210\316\201[\320\321\201\\DD\201]\324\332\313\310\314\201^& \210\316\201_\320\321\201`DD\201a\324\332\313\310\314\201b& \210\316\201c\320\321\201dDD\201e\324\201f\313\310\314\201g& \210\316\201h\320\321\201iDD\201j\324\332\313\310\314\201k& \210\316\201l\320\321\201mDD\201n\324\201o\313\310\314\201p& \210\201q\201r!\210\316\201s\320\321\201tDD\201u\324\337\313\310\314\201v& \210\316\201w\320\321\201xDD\201y\324\337\313\310\314\201z& \210\316\201{\320\321\201|DD\201}\324\337\313\310\314\201~& \207" [require f dash s ht lsp-protocol lsp-mode custom-declare-group lsp-pwsh nil "LSP support for PowerShell, using the PowerShellEditorServices." :group :package-version (lsp-mode . "6.2") custom-declare-variable lsp-pwsh-help-completion funcall function #[0 "\300\207" [#1="BlockComment"] 1 #1#] "Controls the comment-based help completion behavior triggered by typing '##'.\nSet the generated help style with 'BlockComment' or 'LineComment'.\nDisable the feature with 'Disabled'." :type (choice (:tag "Disabled" "BlockComment" "LineComment")) (lsp-mode . "6.2") lsp-pwsh-script-analysis-enable #[0 "\300\207" [t] 1] "Enables real-time script analysis from PowerShell Script Analyzer.\nUses the newest installed version of the PSScriptAnalyzer module or the\nversion bundled with this extension, if it is newer." boolean (lsp-mode . "6.2") lsp-pwsh-script-analysis-settings-path #[0 "\300\207" [#2=""] 1 #2#] "Specifies the path to a PowerShell Script Analyzer settings file.\nTo override the default settings for all projects, enter an absolute path,\nor enter a path relative to your workspace." string (lsp-mode . "6.2") lsp-pwsh-code-folding-enable #[0 "\300\207" [t] 1] "Enables syntax based code folding.\nWhen disabled, the default indentation based code folding is used." (lsp-mode . "6.2") lsp-pwsh-code-folding-show-last-line #[0 "\300\207" [t] 1] "Shows the last line of a folded section.\nSimilar to the default VSCode folding style.\nWhen disabled, the entire folded region is hidden." (lsp-mode . "6.2") lsp-pwsh-code-formatting-preset #[0 "\300\207" [#3="Custom"] 1 #3#] "Sets the codeformatting options to follow the given indent style.\nSets in a way that is compatible with PowerShell syntax.\nFor more information about the brace styles please refer to https://github.com/PoshCode/PowerShellPracticeAndStyle/issues/81." (choice (:tag "Custom" "Allman" "OTBS" "Stroustrup")) (lsp-mode . "6.2") lsp-pwsh-code-formatting-open-brace-on-same-line #[0 "\300\207" [t] 1] "Places open brace on the same line as its associated statement." (lsp-mode . "6.2") lsp-pwsh-code-formatting-new-line-after-open-brace #[0 "\300\207" [t] 1] "Adds a newline (line break) after an open brace." (lsp-mode . "6.2") lsp-pwsh-code-formatting-new-line-after-close-brace #[0 "\300\207" [t] 1] "Adds a newline (line break) after a closing brace." (lsp-mode . "6.2") lsp-pwsh-code-formatting-pipeline-indentation-style #[0 "\300\207" [#4="NoIndentation"] 1 #4#] "Multi-line pipeline style settings." (choice (:tag "IncreaseIndentationForFirstPipeline" "IncreaseIndentationAfterEveryPipeline" "NoIndentation")) (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-before-open-brace #[0 "\300\207" [t] 1] "Adds a space between a keyword and its associated scriptblock expression." (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-before-open-paren #[0 "\300\207" [t] 1] "Adds a space between a keyword (if, elseif, while, switch, etc) and its\nassociated conditional expression." (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-around-operator #[0 "\300\207" [t] 1] "Adds spaces before and after an operator ('=', '+', '-', etc.)." (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-after-separator #[0 "\300\207" [t] 1] "Adds a space after a separator (',' and ';')." (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-inside-brace #[0 "\300\207" [t] 1] "Adds a space after an opening brace ('{') and before a closing brace ('}')." (lsp-mode . "6.2") lsp-pwsh-code-formatting-whitespace-around-pipe #[0 "\300\207" [t] 1] "Adds a space before and after the pipeline operator ('|')." (lsp-mode . "6.2") lsp-pwsh-code-formatting-ignore-one-line-block #[0 "\300\207" [t] 1] "Does not reformat one-line code blocks, such as \"if (...) {...} else\n{...}\"." (lsp-mode . "6.2") lsp-pwsh-code-formatting-align-property-value-pairs #[0 "\300\207" [t] 1] "Align assignment statements in a hashtable or a DSC Configuration." (lsp-mode . "6.2") lsp-pwsh-code-formatting-use-correct-casing #[0 "\300\207" [nil] 1] "Use correct casing for cmdlets." (lsp-mode . "6.2") lsp-pwsh-developer-editor-services-log-level #[0 "\300\207" [#5="Normal"] 1 #5#] "Sets the log level for the PowerShell Editor Services host executable.\nValid values are 'Diagnostic', 'Verbose', 'Normal', 'Warning', and 'Error'" (choice (:tag "Diagnostic" "Verbose" "Normal" "Warning" "Error")) (lsp-mode . "6.2") lsp-pwsh-developer-editor-services-wait-for-debugger #[0 "\300\207" [nil] 1] "Launches the language service with the /waitForDebugger flag to force it to\nwait for a .NET debugger to attach before proceeding." (lsp-mode . "6.2") lsp-pwsh-developer-feature-flags #[0 "\300\207" [nil] 1] "An array of strings that enable experimental features in the PowerShell\nextension." (repeat string) (lsp-mode . "6.2") lsp-register-custom-settings (("powershell.developer.featureFlags" lsp-pwsh-developer-feature-flags) ("powershell.developer.editorServicesWaitForDebugger" lsp-pwsh-developer-editor-services-wait-for-debugger t) ("powershell.codeFormatting.useCorrectCasing" lsp-pwsh-code-formatting-use-correct-casing t) ("powershell.codeFormatting.alignPropertyValuePairs" lsp-pwsh-code-formatting-align-property-value-pairs t) ("powershell.codeFormatting.ignoreOneLineBlock" lsp-pwsh-code-formatting-ignore-one-line-block t) ("powershell.codeFormatting.whitespaceAroundPipe" lsp-pwsh-code-formatting-whitespace-around-pipe t) ("powershell.codeFormatting.whitespaceInsideBrace" lsp-pwsh-code-formatting-whitespace-inside-brace t) ("powershell.codeFormatting.whitespaceAfterSeparator" lsp-pwsh-code-formatting-whitespace-after-separator t) ("powershell.codeFormatting.whitespaceAroundOperator" lsp-pwsh-code-formatting-whitespace-around-operator t) ("powershell.codeFormatting.whitespaceBeforeOpenParen" lsp-pwsh-code-formatting-whitespace-before-open-paren t) ("powershell.codeFormatting.whitespaceBeforeOpenBrace" lsp-pwsh-code-formatting-whitespace-before-open-brace t) ("powershell.codeFormatting.pipelineIndentationStyle" lsp-pwsh-code-formatting-pipeline-indentation-style) ("powershell.codeFormatting.newLineAfterCloseBrace" lsp-pwsh-code-formatting-new-line-after-close-brace t) ("powershell.codeFormatting.newLineAfterOpenBrace" lsp-pwsh-code-formatting-new-line-after-open-brace t) ("powershell.codeFormatting.openBraceOnSameLine" lsp-pwsh-code-formatting-open-brace-on-same-line t) ("powershell.codeFormatting.preset" lsp-pwsh-code-formatting-preset) ("powershell.codeFolding.showLastLine" lsp-pwsh-code-folding-show-last-line t) ("powershell.codeFolding.enable" lsp-pwsh-code-folding-enable t) ("powershell.scriptAnalysis.settingsPath" lsp-pwsh-script-analysis-settings-path) ("powershell.scriptAnalysis.enable" lsp-pwsh-script-analysis-enable t) ("powershell.helpCompletion" lsp-pwsh-help-completion)) lsp-pwsh-ext-path #[0 "\301\302\"\207" [lsp-server-install-dir f-join "pwsh"] 3] "The path to powershell vscode extension." (lsp-mode . "6.2") lsp-pwsh-exe #[0 "\300\301!\206 \300\302!\207" [executable-find "pwsh" "powershell"] 2] "PowerShell executable." (lsp-mode . "6.2") lsp-pwsh-dir #[0 "\301\302\"\207" [lsp-pwsh-ext-path expand-file-name "PowerShellEditorServices"] 3] "Path to PowerShellEditorServices without last slash." (lsp-mode . "6.2")] 10) #@68 Path to directory where server will write log files. Must not nil. (defvar lsp-pwsh-log-path (expand-file-name "logs" lsp-pwsh-ext-path) (#$ . 8999)) (defvar lsp-pwsh--sess-id (emacs-pid)) #@37 Return the command to start server. (defalias 'lsp-pwsh--command #[0 "\306\307\310\311 \312=\205\f\313\314\315\316\317\n\320\"\321\322\323\324\325\326\327\317 \330\"\331\f\332\333\334 #\335\336\n\337BBBBBBBBBBBBBBBBBBB\"BBBB\207" [lsp-pwsh-exe system-type lsp-pwsh-dir lsp-pwsh-log-path lsp-pwsh-developer-editor-services-log-level lsp-pwsh--sess-id "-NoProfile" "-NonInteractive" "-NoLogo" append windows-nt ("-ExecutionPolicy" "Bypass") "-OutputFormat" "Text" "-File" f-join "PowerShellEditorServices/Start-EditorServices.ps1" "-HostName" "\"Emacs Host\"" "-HostProfileId" "'Emacs.LSP'" "-HostVersion" "0.1" "-LogPath" "emacs-powershell.log" "-LogLevel" "-SessionDetailsPath" format "%s/PSES-VSCode-%d" "-Stdio" "-BundledModulesPath" ("-FeatureFlags" "@()")] 26 (#$ . 9194)]) #@56 Return form describing parameters for language server. (defalias 'lsp-pwsh--extra-init-params #[0 "\300\207" ["Return form describing parameters for language server."] 1 (#$ . 9981)]) #@65 Handle ACTION for PowerShell.ApplyCodeActionEdits. (fn INPUT0) (defalias 'lsp-pwsh--apply-code-action-edits #[257 "\300\301\"\300\302\"\303!\211\203\241\300\304\"\211\203\234\300\305\"\211\203\227\300\306\"\211\203\220\300\307\"\211\203\211\300\310\"\211\203\202\311\312S\313S$\211\203{\311\312S\313S$\211\203t\314\315\316\317\320\321$\322$!\211\203m\323\324\"\207\325  \"\207\325\n\n\"\207\325  \"\207\325\"\207\325\"\207\325\"\207\325\"\207\325\"\207\325\"\207" [gethash "command" "arguments" lsp-seq-first "StartLineNumber" "EndLineNumber" "StartColumnNumber" "EndColumnNumber" "Text" lsp-make-position :line :character vector lsp-make-text-edit :range lsp-make-range :start :end :newText lsp--apply-text-edits code-action lsp-send-execute-command] 19 (#$ . 10171)]) #@72 Handle ACTION for PowerShell.ShowCodeActionDocumentation. (fn INPUT0) (defalias 'lsp-pwsh--show-code-action-document #[257 "\300\301\"\302!\211\203)\303\304\"\203\211\305\306O\202\211\211\203%\307\310\311Q!\207\312\313!\207\312\313!\207" [gethash "arguments" lsp-seq-first s-prefix-p "PS" 2 nil browse-url "https://github.com/PowerShell/PSScriptAnalyzer/blob/master/RuleDocumentation/" ".md" lsp-warn "Cannot show documentation for code action, no ruleName was supplied"] 8 (#$ . 11005)]) (defvar lsp-pwsh--major-modes '(powershell-mode)) (byte-code "\301\302\303\304\305\306\"\307\310\311\312\313\314\315\316\317\320\321\322\323\"\324\325\326#\210\324\327\326#\210\211\262\330\321\322\323\"\324\331\332#\210\324\333\334#\210\211\262\335\336\337\340&!\210\341\342\343\344\345DD\346\347\350\351\352\353\354& \207" [lsp-pwsh--major-modes lsp-register-client make-lsp-client :new-connection lsp-stdio-connection lsp-pwsh--command #[0 "\301!\207" [lsp-pwsh-dir f-exists\?] 2] :major-modes :server-id pwsh-ls :priority -1 :multi-root t :initialization-options lsp-pwsh--extra-init-params :notification-handlers make-hash-table :test equal puthash "powerShell/executionStatusChanged" ignore "output" :action-handlers "PowerShell.ApplyCodeActionEdits" lsp-pwsh--apply-code-action-edits "PowerShell.ShowCodeActionDocumentation" lsp-pwsh--show-code-action-document :initialized-fn #[257 "\211\302\303\304!!\210)\305! >\204\306\307\310D\"\210\211\311H\312\313\"\210\314\313\"\207" [lsp--cur-workspace cl-struct-lsp--workspace-tags lsp--set-configuration lsp-configuration-section "powershell" type-of signal wrong-type-argument lsp--workspace 2 lsp:set-server-capabilities-document-range-formatting-provider\? t lsp:set-server-capabilities-document-formatting-provider\?] 5 "\n\n(fn W)"] :download-server-fn lsp-pwsh-setup custom-declare-variable lsp-pwsh-github-asset-url funcall function #[0 "\300\207" [#1="https://github.com/%s/%s/releases/latest/download/%s"] 1 #1#] "GitHub latest asset template url." :type string :group lsp-pwsh :package-version (lsp-mode . "6.2")] 22) #@281 Downloads PowerShellEditorServices to `lsp-pwsh-dir'. CALLBACK is called when the download finish successfully otherwise ERROR-CALLBACK is called. UPDATE is non-nil if it is already downloaded. FORCED if specified with prefix argument. (fn CLIENT CALLBACK ERROR-CALLBACK UPDATE) (defalias 'lsp-pwsh-setup #[1028 "\203\n\304!\204\305\306\"\210\307 \310\311\312$\313\314\315\316#\317\n!\204%\320\n\321\"\210?\205-\317 !?\205Y\317 !\203<\322 \323\"\210\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343 !&\207" [lsp-pwsh-exe lsp-pwsh-github-asset-url lsp-pwsh-log-path lsp-pwsh-dir file-executable-p user-error "Use `lsp-pwsh-exe' with the value of `%s' is not a valid powershell binary" format "PowerShell" "PowerShellEditorServices" "PowerShellEditorServices.zip" make-temp-file "ext" nil ".zip" f-exists\? mkdir create-parent delete-directory recursive lsp-async-start-process "-noprofile" "-noninteractive" "-nologo" "-ex" "bypass" "-command" "Invoke-WebRequest" "-UseBasicParsing" "-uri" "-outfile" ";" "Expand-Archive" "-Path" "-DestinationPath" file-name-directory] 29 (#$ . 13107)]) (defconst lsp-pwsh-plist-value-when-compiled nil) (provide 'lsp-pwsh)