Skip to content
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

fix(init): fix hexo init error with a number target project name #200

Merged
merged 2 commits into from
Jun 12, 2020

Conversation

brelian
Copy link
Contributor

@brelian brelian commented May 21, 2020

What this PR does / why we need it:
Fix hexo init bug with a number target name. Also ref #45 #199 .

Special notes for your reviewer:

/review
@SukkaW @tommy351

@coveralls
Copy link

Coverage Status

Coverage remained the same at 85.417% when pulling 49886e1 on brelian:master into 71debfb on hexojs:master.

@@ -15,7 +15,7 @@ function initConsole(args) {
args = Object.assign({ install: true, clone: true }, args);

const baseDir = this.base_dir;
const target = args._[0] ? resolve(baseDir, String(args._[0])) : baseDir;
const target = args._[0] ? resolve(baseDir, args._[0]) : baseDir;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Always parses it as a string. Manually convert is unnecessary anymore.

@brelian brelian changed the title fix: fix hexo init error with a number target project name fix(init): fix hexo init error with a number target project name May 21, 2020
Copy link
Member

@SukkaW SukkaW left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@SukkaW SukkaW requested a review from a team May 21, 2020 14:05
@stevenjoezhang stevenjoezhang linked an issue May 21, 2020 that may be closed by this pull request
@brelian brelian requested review from SukkaW and removed request for a team May 25, 2020 06:27
@SukkaW SukkaW merged commit af92881 into hexojs:master Jun 12, 2020
SukkaW added a commit to SukkaW/hexo-cli that referenced this pull request Jun 19, 2020
SukkaW added a commit that referenced this pull request Jun 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

A bug regarding init project with a hexadecimal name
3 participants