Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: vitaliy-guliy <[email protected]>
  • Loading branch information
vitaliy-guliy committed Jan 2, 2025
1 parent 5d51a86 commit f9e2233
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions code/extensions/che-remote/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -247,25 +247,6 @@ async function updateDevfile(cheApi: any): Promise<boolean> {
}

try {
const serialized = jsYaml.dump(devfileContext);
await fs.writeFile('/projects/new-devfile.yaml', serialized);
await vscode.window.showInformationMessage('The new devfile has been written to \'/projects/new-devfile.yaml\'', {
modal: true
});
} catch (error) {
await vscode.window.showErrorMessage(`Failed to write new devfile context to '/projects/new-devfile.yaml'. ${error}`);
return false;
}

try {
const action = await vscode.window.showInformationMessage('The new devfile has been written to \'/projects/new-devfile.yaml\'', {
modal: true,
detail: 'Apply changes?'
}, 'Apply');
if (action !== 'Apply') {
return false;
}

await devfileService.updateDevfile(devfileContext.devWorkspace.spec?.template);
} catch (error) {
if (error.body && error.body.message) {
Expand Down

0 comments on commit f9e2233

Please sign in to comment.