Skip to content

change some text of comments #5

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/core/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const handleEjsToFile = async (name, dest, template, filename) => {
const result = await ejsCompile(templatePath, {name, lowerName: name.toLowerCase()});

// 2.写入文件中
// 判断文件不存在,那么就创建文件
// 判断文件夹是否存在,不存在就创建对应的文件夹
mkdirSync(dest);
const targetPath = path.resolve(dest, filename);
writeFile(targetPath, result);
Expand Down
2 changes: 1 addition & 1 deletion lib/utils/file.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const mkdirSync = (dirname) => {
} else {
// 不存在,判断父亲文件夹是否存在?
if (mkdirSync(path.dirname(dirname))) {
// 存在父亲文件,就直接新建该文件
// 存在父亲文件夹,就直接新建该文件夹
fs.mkdirSync(dirname)
return true
}
Expand Down