Skip to content

Commit ac1d156

Browse files
authored
fix: fix associations on windows (#72)
1 parent 83b6b23 commit ac1d156

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,7 @@ function getSchemaAssociations(): ISchemaAssociation[] {
597597
const associations: ISchemaAssociation[] = []
598598
if (resolveJson) {
599599
let home = path.normalize(process.env.COC_VIMCONFIG) ?? path.join(os.homedir(), '.vim')
600-
let userConfigFile = URI.file(path.join(home, 'coc-settings.json')).fsPath
600+
let userConfigFile = URI.file(path.join(home, 'coc-settings.json')).fsPath.split(path.win32.sep).join(path.posix.sep)
601601
associations.push({ fileMatch: [userConfigFile], uri: 'vscode://schemas/settings/user' })
602602
associations.push({ fileMatch: ['coc-settings.json', `!${userConfigFile}`], uri: 'vscode://schemas/settings/folder' })
603603
} else {

0 commit comments

Comments
 (0)