mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-23 14:06:59 +02:00
feat(logger): new "url" format, add double quotes around paths (#7019)
* refactor(logger): add double quotes around paths * Introduce url formatter * Fix
This commit is contained in:
parent
2bcac29cd4
commit
a307da0b9f
7 changed files with 21 additions and 11 deletions
|
@ -271,7 +271,7 @@ export default async function init(
|
|||
return logger.red('Invalid repository URL');
|
||||
},
|
||||
message: logger.interpolate`Enter a repository URL from GitHub, Bitbucket, GitLab, or any other public repo.
|
||||
(e.g: path=${'https://github.com/ownerName/repoName.git'})`,
|
||||
(e.g: url=${'https://github.com/ownerName/repoName.git'})`,
|
||||
});
|
||||
({gitStrategy} = await prompts({
|
||||
type: 'select',
|
||||
|
@ -318,7 +318,7 @@ export default async function init(
|
|||
logger.info('Creating new Docusaurus project...');
|
||||
|
||||
if (isValidGitRepoUrl(template)) {
|
||||
logger.info`Cloning Git template path=${template}...`;
|
||||
logger.info`Cloning Git template url=${template}...`;
|
||||
if (!gitStrategies.includes(gitStrategy)) {
|
||||
logger.error`Invalid git strategy: name=${gitStrategy}. Value must be one of ${gitStrategies.join(
|
||||
', ',
|
||||
|
@ -416,7 +416,7 @@ export default async function init(
|
|||
}
|
||||
|
||||
const useNpm = pkgManager === 'npm';
|
||||
logger.success`Created path=${cdpath}.`;
|
||||
logger.success`Created name=${cdpath}.`;
|
||||
logger.info`Inside that directory, you can run several commands:
|
||||
|
||||
code=${`${pkgManager} start`}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue