Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 05fd880

Browse files
If an existing project has no gitignore, create one
1 parent 555b79d commit 05fd880

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎index.mjs‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,8 @@ async function addToExistingProject(projectName) {
179179

180180
if (fs.existsSync(gitignorePath)) {
181181
await fs.promises.appendFile(gitignorePath, os.EOL + "/lib/" + os.EOL + ".bsb.lock" + os.EOL);
182+
} else {
183+
await fs.promises.copyFile(path.join(templatePath, "_gitignore"), gitignorePath);
182184
}
183185

184186
await updateExistingPackageJson();

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /