fix(schematics): ignore errors when the tools directory already exists
This commit is contained in:
parent
fba3b24958
commit
2a377fe643
@ -4,8 +4,12 @@ import * as path from 'path';
|
||||
export default {
|
||||
description: 'Add tools directory',
|
||||
run: () => {
|
||||
mkdirSync('tools');
|
||||
mkdirSync(path.join('tools', 'schematics'));
|
||||
try {
|
||||
mkdirSync('tools');
|
||||
} catch (e) {}
|
||||
try {
|
||||
mkdirSync(path.join('tools', 'schematics'));
|
||||
} catch (e) {}
|
||||
writeFileSync(path.join('tools', 'schematics', '.gitkeep'), '');
|
||||
}
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user