Skip to content

Commit 6fad78b

Browse files
fix: remove default command
1 parent 535ccf8 commit 6fad78b

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@
6464
"astGrep.serverPath": {
6565
"scope": "window",
6666
"type": "string",
67-
"default": "ast-grep",
6867
"description": "Specify the language server binary path."
6968
},
7069
"astGrep.configPath": {

src/extension/common.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@ export async function detectDefaultBinaryAtStart() {
3232
}
3333

3434
export function resolveBinary() {
35-
return workspace.getConfiguration('astGrep').get('serverPath', defaultBinary)
35+
const config = workspace.getConfiguration('astGrep').get('serverPath', '')
36+
if (!config) {
37+
return defaultBinary
38+
}
39+
return config
3640
}
3741

3842
export async function testBinaryExist(command: string) {

0 commit comments

Comments
 (0)