-
Notifications
You must be signed in to change notification settings - Fork 6
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
Folder in init wollok init [folder]
#190
Folder in init wollok init [folder]
#190
Conversation
@@ -39,7 +39,7 @@ export type FileContent = { | |||
|
|||
export const createFolderIfNotExists = (folder: string): void => { | |||
if (!existsSync(folder)) { | |||
mkdirSync(folder) | |||
mkdirSync(folder, { recursive: true }) |
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.
Capaz lo puedo pasar por parametro esto
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.
No creo que haga falta
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.
AAARRRRMMMOOSSSOOO ! 💯 🏆 🙌
Muchas graciaas, @nmigueles !
@@ -39,7 +39,7 @@ export type FileContent = { | |||
|
|||
export const createFolderIfNotExists = (folder: string): void => { | |||
if (!existsSync(folder)) { | |||
mkdirSync(folder) | |||
mkdirSync(folder, { recursive: true }) |
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.
No creo que haga falta
export const pathAssertions: Chai.ChaiPlugin = (chai) => { | ||
const { Assertion } = chai | ||
|
||
Assertion.addMethod('pathExists', function (path) { | ||
const exists = existsSync(path) | ||
this.assert( | ||
exists, | ||
'expected path #{this} to exist', | ||
'expected path #{this} to not exist', | ||
path | ||
) | ||
}) | ||
} |
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.
👏 👏 👏
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.
Me fallaba y me decia expected true, but false o algo asi, con esto dice el path exacto del archivo que falla, una belleza
Fix #189
Now the init command has an optional argument for the folder name.
Known issue
Me esta creando la carpeta
log
por fuera y no veo donde se crea