create-typescript-app 2.70.0 → 2.71.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -6,7 +6,6 @@ import { createSoloWorkflowFile } from "./files/createSoloWorkflowFile.mjs";
|
|
|
6
6
|
import { withPreviously } from "./files/withPreviously.mjs";
|
|
7
7
|
import { blockREADME } from "./blockREADME.mjs";
|
|
8
8
|
import { blockPrettier } from "./blockPrettier.mjs";
|
|
9
|
-
import { blockRepositorySecrets } from "./blockRepositorySecrets.mjs";
|
|
10
9
|
import _ from "lodash";
|
|
11
10
|
import { contributionTypes, createContributionLink, isContributionTypeName } from "all-contributors-types";
|
|
12
11
|
//#region src/blocks/blockAllContributors.ts
|
|
@@ -16,32 +15,25 @@ const blockAllContributors = base.createBlock({
|
|
|
16
15
|
const contributions = options.contributors?.length;
|
|
17
16
|
const ownerContributions = Array.from(new Set([options.contributors?.find((contributor) => contributor.login.toLowerCase() === options.owner.toLowerCase())?.contributions, startingOwnerContributions].filter(Boolean).flat()));
|
|
18
17
|
return {
|
|
19
|
-
addons: [
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
comments: {
|
|
25
|
-
after: `
|
|
18
|
+
addons: [blockPrettier({ ignores: ["/.all-contributorsrc"] }), blockREADME({
|
|
19
|
+
badges: [{
|
|
20
|
+
alt: `👪 All Contributors: ${contributions}`,
|
|
21
|
+
comments: {
|
|
22
|
+
after: `
|
|
26
23
|
<!-- ALL-CONTRIBUTORS-BADGE:END -->
|
|
27
24
|
\t<!-- prettier-ignore-end -->`,
|
|
28
|
-
|
|
25
|
+
before: `<!-- prettier-ignore-start -->
|
|
29
26
|
\t<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
|
|
30
27
|
\t`
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
blockRepositorySecrets({ secrets: [{
|
|
41
|
-
description: "a GitHub PAT with repo and workflow permissions",
|
|
42
|
-
name: "ACCESS_TOKEN"
|
|
43
|
-
}] })
|
|
44
|
-
],
|
|
28
|
+
},
|
|
29
|
+
href: "#contributors",
|
|
30
|
+
src: `https://img.shields.io/badge/%F0%9F%91%AA_all_contributors-${contributions}-21bb42.svg`
|
|
31
|
+
}],
|
|
32
|
+
sections: options.contributors ? [printAllContributorsTable(options.contributors, {
|
|
33
|
+
projectName: options.repository,
|
|
34
|
+
projectOwner: options.owner
|
|
35
|
+
})] : void 0
|
|
36
|
+
})],
|
|
45
37
|
files: {
|
|
46
38
|
".all-contributorsrc": JSON.stringify({
|
|
47
39
|
badgeTemplate: " <a href=\"#contributors\" target=\"_blank\"><img alt=\"👪 All Contributors: <%= contributors.length %>\" src=\"https://img.shields.io/badge/%F0%9F%91%AA_all_contributors-<%= contributors.length %>-21bb42.svg\" /></a>",
|
|
@@ -57,17 +49,16 @@ const blockAllContributors = base.createBlock({
|
|
|
57
49
|
".github": { workflows: { "contributors.yaml": withPreviously(createSoloWorkflowFile({
|
|
58
50
|
name: "Contributors",
|
|
59
51
|
on: { push: { branches: ["main"] } },
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
]
|
|
52
|
+
permissions: {
|
|
53
|
+
actions: "read",
|
|
54
|
+
contents: "read",
|
|
55
|
+
issues: "write",
|
|
56
|
+
"pull-requests": "write"
|
|
57
|
+
},
|
|
58
|
+
steps: [{
|
|
59
|
+
env: { GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" },
|
|
60
|
+
uses: resolveUses("JoshuaKGoldberg/all-contributors-auto-action", "v0.7.0", options.workflowsVersions)
|
|
61
|
+
}]
|
|
71
62
|
}), ["contributors.yml"]) } }
|
|
72
63
|
},
|
|
73
64
|
scripts: [{
|
|
@@ -7,6 +7,7 @@ import { createSoloWorkflowFile } from "./files/createSoloWorkflowFile.mjs";
|
|
|
7
7
|
import { withPreviously } from "./files/withPreviously.mjs";
|
|
8
8
|
import { blockPackageJson } from "./blockPackageJson.mjs";
|
|
9
9
|
import { blockCSpell } from "./blockCSpell.mjs";
|
|
10
|
+
import { blockRepositorySecrets } from "./blockRepositorySecrets.mjs";
|
|
10
11
|
//#region src/blocks/blockCTATransitions.ts
|
|
11
12
|
const blockCTATransitions = base.createBlock({
|
|
12
13
|
about: { name: "CTA Transitions" },
|
|
@@ -19,7 +20,11 @@ const blockCTATransitions = base.createBlock({
|
|
|
19
20
|
"stefanzweifel"
|
|
20
21
|
] }),
|
|
21
22
|
blockPackageJson({ properties: { devDependencies: { "create-typescript-app": packageData.version } } }),
|
|
22
|
-
blockRepositoryBranchRuleset({ requiredStatusChecks: ["Transition"] })
|
|
23
|
+
blockRepositoryBranchRuleset({ requiredStatusChecks: ["Transition"] }),
|
|
24
|
+
blockRepositorySecrets({ secrets: [{
|
|
25
|
+
description: "a GitHub PAT with repo and workflow permissions",
|
|
26
|
+
name: "ACCESS_TOKEN"
|
|
27
|
+
}] })
|
|
23
28
|
],
|
|
24
29
|
files: { ".github": {
|
|
25
30
|
actions: { transition: { "action.yaml": withPreviously(formatYaml({
|
|
@@ -6,8 +6,8 @@ import { withPreviously } from "./files/withPreviously.mjs";
|
|
|
6
6
|
import { formatFile } from "../utils/formatFile.mjs";
|
|
7
7
|
import { blockPackageJson } from "./blockPackageJson.mjs";
|
|
8
8
|
import { blockCSpell } from "./blockCSpell.mjs";
|
|
9
|
-
import { blockREADME } from "./blockREADME.mjs";
|
|
10
9
|
import { blockRepositorySecrets } from "./blockRepositorySecrets.mjs";
|
|
10
|
+
import { blockREADME } from "./blockREADME.mjs";
|
|
11
11
|
import { z } from "zod";
|
|
12
12
|
//#region src/blocks/blockReleaseIt.ts
|
|
13
13
|
const blockReleaseIt = base.createBlock({
|
package/dist/presets/minimal.mjs
CHANGED
|
@@ -6,13 +6,13 @@ import { blockDevelopmentDocs } from "../blocks/blockDevelopmentDocs.mjs";
|
|
|
6
6
|
import { blockPackageJson } from "../blocks/blockPackageJson.mjs";
|
|
7
7
|
import { blockRemoveWorkflows } from "../blocks/blockRemoveWorkflows.mjs";
|
|
8
8
|
import { blockGitHubIssueTemplates } from "../blocks/blockGitHubIssueTemplates.mjs";
|
|
9
|
+
import { blockRepositorySecrets } from "../blocks/blockRepositorySecrets.mjs";
|
|
9
10
|
import { blockRemoveDependencies } from "../blocks/blockRemoveDependencies.mjs";
|
|
10
11
|
import { blockESLint } from "../blocks/blockESLint.mjs";
|
|
11
12
|
import { blockREADME } from "../blocks/blockREADME.mjs";
|
|
12
13
|
import { blockExampleFiles } from "../blocks/blockExampleFiles.mjs";
|
|
13
14
|
import { blockGitignore } from "../blocks/blockGitignore.mjs";
|
|
14
15
|
import { blockPrettier } from "../blocks/blockPrettier.mjs";
|
|
15
|
-
import { blockRepositorySecrets } from "../blocks/blockRepositorySecrets.mjs";
|
|
16
16
|
import { blockTSDown } from "../blocks/blockTSDown.mjs";
|
|
17
17
|
import { blockTypeScript } from "../blocks/blockTypeScript.mjs";
|
|
18
18
|
import { blockGitHubApps } from "../blocks/blockGitHubApps.mjs";
|