windows - remove not needed and confusing disable-restore-windows CLI arg

This commit is contained in:
Benjamin Pasero 2020-10-01 11:36:45 +02:00
parent 35d4bbf592
commit 781e0e3192
5 changed files with 2 additions and 5 deletions

View file

@ -56,7 +56,6 @@ export interface NativeParsedArgs {
'enable-proposed-api'?: string[]; // undefined or array of 1 or more
'open-url'?: boolean;
'skip-release-notes'?: boolean;
'disable-restore-windows'?: boolean;
'disable-telemetry'?: boolean;
'export-default-configuration'?: string;
'install-source'?: string;

View file

@ -90,7 +90,6 @@ export const OPTIONS: OptionDescriptions<Required<NativeParsedArgs>> = {
'driver': { type: 'string' },
'logExtensionHostCommunication': { type: 'boolean' },
'skip-release-notes': { type: 'boolean' },
'disable-restore-windows': { type: 'boolean' },
'disable-telemetry': { type: 'boolean' },
'disable-updates': { type: 'boolean' },
'disable-crash-reporter': { type: 'boolean' },

View file

@ -433,7 +433,7 @@ export class WindowsMainService extends Disposable implements IWindowsMainServic
// These are windows to restore because of hot-exit or from previous session (only performed once on startup!)
//
let workspacesToRestore: IWorkspacePathToOpen[] = [];
if (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath && !openConfig.cli['disable-restore-windows']) {
if (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) {
// Untitled workspaces are always restored
workspacesToRestore = this.workspacesMainService.getUntitledWorkspacesSync();

View file

@ -141,7 +141,6 @@ export async function spawn(options: SpawnOptions): Promise<Code> {
'--disable-crash-reporter',
`--extensions-dir=${options.extensionsPath}`,
`--user-data-dir=${options.userDataDir}`,
`--disable-restore-windows`,
'--driver', handle
];

View file

@ -40,7 +40,7 @@ export function setup() {
// restart with preventing additional windows from restoring
// to ensure the window after restart is the multi-root workspace
await app.restart({ workspaceOrFolder: workspaceFilePath, extraArgs: ['--disable-restore-windows'] });
await app.restart({ workspaceOrFolder: workspaceFilePath });
});
it('shows results from all folders', async function () {