-
Notifications
You must be signed in to change notification settings - Fork 324
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding autoedits onboarding setup for dotcom users
- Loading branch information
1 parent
91ac295
commit ab9ec69
Showing
5 changed files
with
43 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
|
||
import * as vscode from 'vscode' | ||
|
||
export async function showAutoeditOnboarding(): Promise<void> { | ||
const selection = await vscode.window.showInformationMessage( | ||
'✨ Try Cody Autoedits - An alternative to autocomplete that helps you edit code more efficiently', | ||
'Enable Autoedits' | ||
) | ||
|
||
if (selection === 'Enable Autoedits') { | ||
// Enable the setting programmatically | ||
await vscode.workspace.getConfiguration().update( | ||
'cody.experimental.autoedits.enabled', | ||
true, | ||
vscode.ConfigurationTarget.Global | ||
) | ||
|
||
// Open VS Code settings UI and focus on the Cody Autoedits setting | ||
await vscode.commands.executeCommand( | ||
'workbench.action.openSettings', | ||
'cody.experimental.autoedits' | ||
) | ||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,5 +12,9 @@ declare module 'wink-nlp-utils' { | |
} | ||
} | ||
|
||
|
||
export default winkUtils | ||
} | ||
|
||
|
||
|