create-typescript-app 2.6.1 → 2.7.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.
- package/lib/base.d.ts +6 -6
- package/lib/base.js +5 -1
- package/lib/data/packageData.d.ts +1 -1
- package/lib/options/readAccess.d.ts +5 -0
- package/lib/options/readAccess.js +6 -0
- package/lib/types.d.ts +4 -0
- package/package.json +1 -1
package/lib/base.d.ts
CHANGED
|
@@ -9,16 +9,16 @@ declare const zContributor: z.ZodObject<{
|
|
|
9
9
|
name: z.ZodString;
|
|
10
10
|
profile: z.ZodString;
|
|
11
11
|
}, "strip", z.ZodTypeAny, {
|
|
12
|
-
name: string;
|
|
13
12
|
avatar_url: string;
|
|
14
13
|
contributions: string[];
|
|
15
14
|
login: string;
|
|
15
|
+
name: string;
|
|
16
16
|
profile: string;
|
|
17
17
|
}, {
|
|
18
|
-
name: string;
|
|
19
18
|
avatar_url: string;
|
|
20
19
|
contributions: string[];
|
|
21
20
|
login: string;
|
|
21
|
+
name: string;
|
|
22
22
|
profile: string;
|
|
23
23
|
}>;
|
|
24
24
|
type Contributor = z.infer<typeof zContributor>;
|
|
@@ -33,16 +33,16 @@ declare const base: bingo_stratum.Base<{
|
|
|
33
33
|
name: z.ZodString;
|
|
34
34
|
profile: z.ZodString;
|
|
35
35
|
}, "strip", z.ZodTypeAny, {
|
|
36
|
-
name: string;
|
|
37
36
|
avatar_url: string;
|
|
38
37
|
contributions: string[];
|
|
39
38
|
login: string;
|
|
39
|
+
name: string;
|
|
40
40
|
profile: string;
|
|
41
41
|
}, {
|
|
42
|
-
name: string;
|
|
43
42
|
avatar_url: string;
|
|
44
43
|
contributions: string[];
|
|
45
44
|
login: string;
|
|
45
|
+
name: string;
|
|
46
46
|
profile: string;
|
|
47
47
|
}>, "many">>;
|
|
48
48
|
description: z.ZodDefault<z.ZodString>;
|
|
@@ -84,11 +84,11 @@ declare const base: bingo_stratum.Base<{
|
|
|
84
84
|
href: z.ZodString;
|
|
85
85
|
title: z.ZodString;
|
|
86
86
|
}, "strip", z.ZodTypeAny, {
|
|
87
|
-
title: string;
|
|
88
87
|
href: string;
|
|
89
|
-
}, {
|
|
90
88
|
title: string;
|
|
89
|
+
}, {
|
|
91
90
|
href: string;
|
|
91
|
+
title: string;
|
|
92
92
|
}>>;
|
|
93
93
|
keywords: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
94
94
|
logo: z.ZodOptional<z.ZodObject<{
|
package/lib/base.js
CHANGED
|
@@ -3,6 +3,7 @@ import { inputFromFile } from "input-from-file";
|
|
|
3
3
|
import { inputFromScript } from "input-from-script";
|
|
4
4
|
import lazyValue from "lazy-value";
|
|
5
5
|
import { z } from "zod";
|
|
6
|
+
import { readAccess } from "./options/readAccess.js";
|
|
6
7
|
import { readAllContributors } from "./options/readAllContributors.js";
|
|
7
8
|
import { readAuthor } from "./options/readAuthor.js";
|
|
8
9
|
import { readDescription } from "./options/readDescription.js";
|
|
@@ -100,6 +101,9 @@ const base = createBase({
|
|
|
100
101
|
version: z.string().optional().describe("package version to publish as and store in `package.json`")
|
|
101
102
|
},
|
|
102
103
|
prepare({ options, take }) {
|
|
104
|
+
const getAccess = lazyValue(
|
|
105
|
+
async () => await readAccess(getPackageDataFull)
|
|
106
|
+
);
|
|
103
107
|
const getAllContributors = lazyValue(
|
|
104
108
|
async () => await readAllContributors(take)
|
|
105
109
|
);
|
|
@@ -182,7 +186,7 @@ const base = createBase({
|
|
|
182
186
|
async () => (await getPackageDataFull()).version
|
|
183
187
|
);
|
|
184
188
|
return {
|
|
185
|
-
access:
|
|
189
|
+
access: getAccess,
|
|
186
190
|
author: getAuthor,
|
|
187
191
|
bin: getBin,
|
|
188
192
|
contributors: getAllContributors,
|
package/lib/types.d.ts
CHANGED
|
@@ -23,6 +23,7 @@ interface PartialPackageData {
|
|
|
23
23
|
};
|
|
24
24
|
name?: string;
|
|
25
25
|
packageManager?: string;
|
|
26
|
+
publishConfig?: PartialPublishConfig;
|
|
26
27
|
repository?: string | {
|
|
27
28
|
type: string;
|
|
28
29
|
url: string;
|
|
@@ -30,5 +31,8 @@ interface PartialPackageData {
|
|
|
30
31
|
scripts?: Record<string, string>;
|
|
31
32
|
version?: string;
|
|
32
33
|
}
|
|
34
|
+
interface PartialPublishConfig {
|
|
35
|
+
access?: "public" | "restricted";
|
|
36
|
+
}
|
|
33
37
|
|
|
34
38
|
export type { AllContributorContributor, AllContributorsData, PartialPackageData };
|