mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-11 16:17:25 +02:00
refactor: unify error handling behavior (#6755)
* refactor: unify error handling behavior * revert * normalize paths * test... * change * does this work... * fix... * maybe fix * maybe fix * fix * fix...
This commit is contained in:
parent
dcbf9f644e
commit
f903422617
58 changed files with 1123 additions and 299 deletions
|
@ -92,9 +92,9 @@ async function generateTemplateExample(template) {
|
|||
);
|
||||
|
||||
console.log(`Generated example for template ${template}`);
|
||||
} catch (error) {
|
||||
} catch (err) {
|
||||
console.error(`Failed to generated example for template ${template}`);
|
||||
throw error;
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -115,12 +115,12 @@ function updateStarters() {
|
|||
console.log(`forcePushGitSubtree command: ${command}`);
|
||||
shell.exec(command);
|
||||
console.log('forcePushGitSubtree success!');
|
||||
} catch (e) {
|
||||
} catch (err) {
|
||||
console.error(
|
||||
`Can't force push to git subtree with command '${command}'`,
|
||||
);
|
||||
console.error(`If it's a permission problem, ask @slorber`);
|
||||
console.error(e);
|
||||
console.error(err);
|
||||
}
|
||||
console.log('');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue