提交 f19aa21d 编写于 作者: I Ilie Halip

added config option git.cloneDirectory, defaulting to os.homedir()

上级 65e90f85
......@@ -618,6 +618,11 @@
"type": "boolean",
"description": "%config.ignoreLegacyWarning%",
"default": false
},
"git.cloneDirectory": {
"type": "string",
"default": null,
"description": "%config.cloneDirectory%"
}
}
}
......
......@@ -36,5 +36,6 @@
"config.confirmSync": "Confirm before synchronizing git repositories",
"config.countBadge": "Controls the git badge counter",
"config.checkoutType": "Controls what type of branches are listed",
"config.ignoreLegacyWarning": "Ignores the legacy Git warning"
"config.ignoreLegacyWarning": "Ignores the legacy Git warning",
"config.cloneDirectory": "When cloning a new repository, the default location will be set to this directory"
}
\ No newline at end of file
......@@ -202,9 +202,12 @@ export class CommandCenter {
return;
}
const config = workspace.getConfiguration('git');
const cloneDirectory = config.get<string>('cloneDirectory') || os.homedir();
const parentPath = await window.showInputBox({
prompt: localize('parent', "Parent Directory"),
value: os.homedir(),
value: cloneDirectory,
ignoreFocusOut: true
});
......
......@@ -235,6 +235,11 @@ export function registerContributions(): void {
enum: ['all', 'local', 'tags', 'remote'],
default: 'all',
description: nls.localize('checkoutType', "Controls what type of branches are listed."),
},
'git.cloneDirectory': {
type: 'string',
default: null,
description: nls.localize('cloneDirectory', "When cloning a new repository, the default location will be set to this directory."),
}
}
});
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册