Skip to content

Commit aef28f2

Browse files
author
Graham Vasquez
authoredOct 20, 2023
feat: skip file cleanup if installation is skipped (#975)
<!-- 👋 Hi, thanks for sending a PR to create-typescript-app! 💖. Please fill out all fields below and make sure each item is true and [x] checked. Otherwise we may not be able to review your PR. --> ## PR Checklist - [x] Addresses an existing open issue: fixes #706 - [x] That issue was marked as [`status: accepting prs`](https://github.com/JoshuaKGoldberg/create-typescript-app/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22) - [x] Steps in [CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/create-typescript-app/blob/main/.github/CONTRIBUTING.md) were taken ## Overview <!-- Description of what is changed and how the code change does that. --> Moved the "Cleaning up files" `runCommand` call inside of the preceding conditional to only run if packages were installed. For some reason my terminal won't let me put in emojis, so I'll use <(-.-)>
1 parent a13ac6a commit aef28f2

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed
 

‎src/create/createWithOptions.ts

+6-6
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,13 @@ export async function createWithOptions({ github, options }: GitHubAndOptions) {
3636
await withSpinner("Installing packages", async () =>
3737
finalizeDependencies(options),
3838
);
39-
}
4039

41-
await runCommands("Cleaning up files", [
42-
"pnpm dedupe",
43-
"pnpm lint --fix",
44-
"pnpm format --write",
45-
]);
40+
await runCommands("Cleaning up files", [
41+
"pnpm dedupe",
42+
"pnpm lint --fix",
43+
"pnpm format --write",
44+
]);
45+
}
4646

4747
const sendToGitHub =
4848
github && (await doesRepositoryExist(github.octokit, options));

0 commit comments

Comments
 (0)
Please sign in to comment.