@@ -2,7 +2,7 @@ import * as path from "path";
22import * as vscode from "vscode" ;
33
44import { Commands } from "@actions/languageserver/commands" ;
5- import { InitializationOptions , LogLevel } from "@actions/languageserver/initializationOptions" ;
5+ import { InitializationOptions , LogLevel , SecretsValidationMode } from "@actions/languageserver/initializationOptions" ;
66import { ReadFileRequest , Requests } from "@actions/languageserver/request" ;
77import { BaseLanguageClient , LanguageClientOptions } from "vscode-languageclient" ;
88import { LanguageClient as BrowserLanguageClient } from "vscode-languageclient/browser" ;
@@ -20,6 +20,10 @@ function isNode(): boolean {
2020 return typeof process !== "undefined" && process . versions ?. node != null ;
2121}
2222
23+ function getSecretsValidationMode ( ) : SecretsValidationMode {
24+ return vscode . workspace . getConfiguration ( "github-actions" ) . get < SecretsValidationMode > ( "validation.secrets" , "auto" ) ;
25+ }
26+
2327export async function initLanguageServer ( context : vscode . ExtensionContext ) {
2428 const session = await getSession ( ) ;
2529
@@ -35,7 +39,8 @@ export async function initLanguageServer(context: vscode.ExtensionContext) {
3539 workspaceUri : repo . workspaceUri . toString ( ) ,
3640 organizationOwned : repo . organizationOwned
3741 } ) ) ,
38- logLevel : PRODUCTION ? LogLevel . Warn : LogLevel . Debug
42+ logLevel : PRODUCTION ? LogLevel . Warn : LogLevel . Debug ,
43+ secretsValidation : getSecretsValidationMode ( )
3944 } ;
4045
4146 const clientOptions : LanguageClientOptions = {
0 commit comments