Repository: JoshuaKGoldberg/create-typescript-app (ts)

Issue:
🚀 Feature: Add builder Block for GitHub Actions
### Feature Request Checklist

- [x] I have pulled the latest `main` branch of the repository.
- [x] I have [searched for related issues](https://github.com/JoshuaKGoldberg/create-typescript-app/issues?q=is%3Aissue) and found none that matched my issue.

### Overview

For projects of mine such as https://github.com/JoshuaKGoldberg/all-contributors-auto-action, I'd like to be able to stick with CTA fully. But that means swapping out the default tsup builder Block for an [ncc](https://github.com/vercel/ncc) one.

### Additional Info

🎁 

Pull request:
feat: add ncc builder block
## PR Checklist

- [x] Addresses an existing open issue: fixes #2030
- [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

🎁 

Patch:
diff --git a/docs/Blocks.md b/docs/Blocks.md
index 350a0aa..544da1d 100644
--- a/docs/Blocks.md
+++ b/docs/Blocks.md
@@ -33,6 +33,7 @@ This table summarizes each block and which base levels they're included in:
 | Knip                         | `--exclude-knip`                         |         |        | 💯         |
 | Markdownlint                 | `--exclude-markdownlint`                 |         |        | 💯         |
 | MIT License                  | `--exclude-mit-license`                  | ✔️      | ✅     | 💯         |
+| ncc                          | `--exclude-ncc`                          |         |        |            |
 | nvmrc                        | `--exclude-nvmrc`                        |         |        | 💯         |
 | Package JSON                 | `--exclude-package-json`                 | ✔️      | ✅     | 💯         |
 | pnpm Dedupe                  | `--exclude-pnpm-dedupe`                  |         |        | 💯         |
diff --git a/src/blocks/blockNcc.ts b/src/blocks/blockNcc.ts
new file mode 100644
index 0000000..40f6838
--- /dev/null
+++ b/src/blocks/blockNcc.ts
@@ -0,0 +1,78 @@
+import { base } from "../base.js";
+import { blockCSpell } from "./blockCSpell.js";
+import { blockDevelopmentDocs } from "./blockDevelopmentDocs.js";
+import { blockESLint } from "./blockESLint.js";
+import { blockGitHubActionsCI } from "./blockGitHubActionsCI.js";
+import { blockPackageJson } from "./blockPackageJson.js";
+
+export const blockNcc = base.createBlock({
+	about: {
+		name: "ncc",
+	},
+	produce() {
+		return {
+			addons: [
+				blockCSpell({
+					ignores: ["dist"],
+				}),
+				blockDevelopmentDocs({
+					sections: {
+						Building: {
+							contents: `
+Run [TypeScript](https://typescriptlang.org) locally to type check and build source files from \`src/\` into output files in \`lib/\`:
+
+\`\`\`shell
+pnpm build
+\`\`\`
+
+Add \`--watch\` to run the builder in a watch mode that continuously cleans and recreates \`lib/\` as you save files:
+
+\`\`\`shell
+pnpm build --watch
+\`\`\`
+`,
+							innerSections: [
+								{
+									contents: `
+Run [\`@vercel/ncc\`](https://github.com/vercel/ncc) to create an output \`dist/\` to be used in production.
+
+\`\`\`shell
+pnpm build:release
+\`\`\`
+		`,
+									heading: "Building for Release",
+								},
+							],
+						},
+					},
+				}),
+				blockESLint({
+					ignores: ["dist"],
+				}),
+				blockGitHubActionsCI({
+					jobs: [
+						{
+							name: "Build",
+							steps: [{ run: "pnpm build" }],
+						},
+						{
+							name: "Build (Release)",
+							steps: [{ run: "pnpm build:release" }],
+						},
+					],
+				}),
+				blockPackageJson({
+					properties: {
+						devDependencies: {
+							"@vercel/ncc": "^0.38.3",
+						},
+						scripts: {
+							build: "tsc",
+							"build:release": "ncc build src/index.ts -o dist",
+						},
+					},
+				}),
+			],
+		};
+	},
+});
diff --git a/src/blocks/index.ts b/src/blocks/index.ts
index 2c6d4d7..e062537 100644
--- a/src/blocks/index.ts
+++ b/src/blocks/index.ts
@@ -24,6 +24,7 @@ import { blockGitignore } from "./blockGitignore.js";
 import { blockKnip } from "./blockKnip.js";
 import { blockMarkdownlint } from "./blockMarkdownlint.js";
 import { blockMITLicense } from "./blockMITLicense.js";
+import { blockNcc } from "./blockNcc.js";
 import { blockNvmrc } from "./blockNvmrc.js";
 import { blockPackageJson } from "./blockPackageJson.js";
 import { blockPnpmDedupe } from "./blockPnpmDedupe.js";
@@ -69,6 +70,7 @@ export const blocks = {
 	blockKnip,
 	blockMarkdownlint,
 	blockMITLicense,
+	blockNcc,
 	blockNvmrc,
 	blockPackageJson,
 	blockPnpmDedupe,
@@ -115,6 +117,7 @@ export { blockGitignore } from "./blockGitignore.js";
 export { blockKnip } from "./blockKnip.js";
 export { blockMarkdownlint } from "./blockMarkdownlint.js";
 export { blockMITLicense } from "./blockMITLicense.js";
+export { blockNcc } from "./blockNcc.js";
 export { blockNvmrc } from "./blockNvmrc.js";
 export { blockPackageJson } from "./blockPackageJson.js";
 export { blockPnpmDedupe } from "./blockPnpmDedupe.js";
diff --git a/src/template.ts b/src/template.ts
index 738f7f2..26c3e1f 100644
--- a/src/template.ts
+++ b/src/template.ts
@@ -1,6 +1,7 @@
 import { base } from "./base.js";
 import { blockAreTheTypesWrong } from "./blocks/blockAreTheTypesWrong.js";
 import { blockCTATransitions } from "./blocks/blockCTATransitions.js";
+import { blockNcc } from "./blocks/blockNcc.js";
 import { blockRemoveDependencies } from "./blocks/blockRemoveDependencies.js";
 import { blockRemoveFiles } from "./blocks/blockRemoveFiles.js";
 import { presetCommon } from "./presets/common.js";
@@ -18,6 +19,7 @@ export const template = base.createStratumTemplate({
 	blocks: [
 		blockAreTheTypesWrong,
 		blockCTATransitions,
+		blockNcc,
 		blockRemoveDependencies,
 		blockRemoveFiles,
 	],


Test patch:
diff --git a/src/blocks/blockNcc.test.ts b/src/blocks/blockNcc.test.ts
new file mode 100644
index 0000000..7bda2b1
--- /dev/null
+++ b/src/blocks/blockNcc.test.ts
@@ -0,0 +1,107 @@
+import { testBlock } from "bingo-stratum-testers";
+import { describe, expect, test } from "vitest";
+
+import { blockNcc } from "./blockNcc.js";
+import { optionsBase } from "./options.fakes.js";
+
+describe("blockNcc", () => {
+	test("production", () => {
+		const creation = testBlock(blockNcc, {
+			options: optionsBase,
+		});
+
+		expect(creation).toMatchInlineSnapshot(`
+			{
+			  "addons": [
+			    {
+			      "addons": {
+			        "ignores": [
+			          "dist",
+			        ],
+			      },
+			      "block": [Function],
+			    },
+			    {
+			      "addons": {
+			        "sections": {
+			          "Building": {
+			            "contents": "
+			Run [TypeScript](https://typescriptlang.org) locally to type check and build source files from \`src/\` into output files in \`lib/\`:
+
+			\`\`\`shell
+			pnpm build
+			\`\`\`
+
+			Add \`--watch\` to run the builder in a watch mode that continuously cleans and recreates \`lib/\` as you save files:
+
+			\`\`\`shell
+			pnpm build --watch
+			\`\`\`
+			",
+			            "innerSections": [
+			              {
+			                "contents": "
+			Run [\`@vercel/ncc\`](https://github.com/vercel/ncc) to create an output \`dist/\` to be used in production.
+
+			\`\`\`shell
+			pnpm build:release
+			\`\`\`
+					",
+			                "heading": "Building for Release",
+			              },
+			            ],
+			          },
+			        },
+			      },
+			      "block": [Function],
+			    },
+			    {
+			      "addons": {
+			        "ignores": [
+			          "dist",
+			        ],
+			      },
+			      "block": [Function],
+			    },
+			    {
+			      "addons": {
+			        "jobs": [
+			          {
+			            "name": "Build",
+			            "steps": [
+			              {
+			                "run": "pnpm build",
+			              },
+			            ],
+			          },
+			          {
+			            "name": "Build (Release)",
+			            "steps": [
+			              {
+			                "run": "pnpm build:release",
+			              },
+			            ],
+			          },
+			        ],
+			      },
+			      "block": [Function],
+			    },
+			    {
+			      "addons": {
+			        "properties": {
+			          "devDependencies": {
+			            "@vercel/ncc": "^0.38.3",
+			          },
+			          "scripts": {
+			            "build": "tsc",
+			            "build:release": "ncc build src/index.ts -o dist",
+			          },
+			        },
+			      },
+			      "block": [Function],
+			    },
+			  ],
+			}
+		`);
+	});
+});