-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding command to create a gauge project from vscode #211 #215
Conversation
src/init/projectInit.ts
Outdated
commands.executeCommand(VSCodeCommands.OpenFolder, uri, !!workspace.workspaceFolders); | ||
} | ||
|
||
cancle(message: string | Buffer) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cancel
instead of cancle
return new Promise(async (res, rej) => { | ||
let ph = new ProgressHandler(p, res, rej); | ||
if (this.isGaugeInstalled) await this.createFromCommandLine(template, projectFolder, ph); | ||
else await this.createFromTemplate(template, projectFolder, ph); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets not mix async and promises. instead of await
, can we do a .then
and .catch
?
src/init/projectInit.ts
Outdated
|
||
import { VSCodeCommands, GaugeCommands, GaugeVSCodeCommands, GAUGE_TEMPLATE_URL } from "../constants"; | ||
import { FileListItem } from '../types/fileListItem'; | ||
import { spawnSync, execSync, spawn } from 'child_process'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spawnSync
is not used?
src/init/projectInit.ts
Outdated
let options: any = { prompt: "Enter a name for your new project", placeHolder: "gauge-tests" }; | ||
const name = await window.showInputBox(); | ||
if (!name) return; | ||
options = { canSelectFolders: true, openLabel: "Select a folder to create the project in" }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use canSelectMany
to enforce a single folder selection. Ref: here
725b4d3
to
358ee78
Compare
358ee78
to
6fb63f3
Compare
No description provided.