create-atom.io 0.0.0 → 0.0.1

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.
@@ -1,38 +1,27 @@
1
1
  #!/usr/bin/env node
2
2
  import { t as createAtom } from "./create-atom-BV6WVRvY.js";
3
- import { cli, helpOption, optional, parseBooleanOption } from "comline";
4
- import { z } from "zod/v4";
3
+ import { type } from "arktype";
4
+ import { cli, optional, options, parseBooleanOption } from "comline";
5
5
 
6
6
  //#region src/create-atom.x.ts
7
- const helper = helpOption();
8
- const CREATE_ATOM_OPTS = {
9
- description: `Check for breaking changes in a package.`,
10
- optionsSchema: z.object({
11
- packageManager: z.union([
12
- z.literal(`bun`),
13
- z.literal(`npm`),
14
- z.literal(`pnpm`),
15
- z.literal(`yarn`)
16
- ]).optional(),
17
- skipHints: z.boolean().optional()
18
- }),
19
- options: {
20
- ...helper.options,
21
- packageManager: {
22
- flag: `m`,
23
- required: false,
24
- description: `The package manager to use.`,
25
- example: `--packageManager="npm"`
26
- },
27
- skipHints: {
28
- flag: `k`,
29
- required: false,
30
- description: `Silences the 'Getting Started' info, mainly for use in other initializers that may wrap this one but provide their own scripts/instructions.`,
31
- example: `--skipHints`,
32
- parse: parseBooleanOption
33
- }
7
+ const CREATE_ATOM_OPTS = options(`Create a new project with atom.io.`, type({
8
+ "packageManager?": `"bun" | "npm" | "pnpm" | "yarn"`,
9
+ "skipHints?": `boolean`
10
+ }), {
11
+ packageManager: {
12
+ flag: `m`,
13
+ required: false,
14
+ description: `The package manager to use.`,
15
+ example: `--packageManager="npm"`
16
+ },
17
+ skipHints: {
18
+ flag: `k`,
19
+ required: false,
20
+ description: `Silences the 'Getting Started' info, mainly for use in other initializers that may wrap this one but provide their own scripts/instructions.`,
21
+ example: `--skipHints`,
22
+ parse: parseBooleanOption
34
23
  }
35
- };
24
+ });
36
25
  const { inputs } = cli({
37
26
  cliName: `create-atom`,
38
27
  routes: optional({ $projectName: null }),
@@ -1 +1 @@
1
- {"version":3,"file":"create-atom.x.js","names":[],"sources":["../src/create-atom.x.ts"],"sourcesContent":["#!/usr/bin/env node\n\nimport type { OptionsGroup } from \"comline\"\nimport { cli, helpOption, optional, parseBooleanOption } from \"comline\"\nimport { z } from \"zod/v4\"\n\nimport type { CreateAtomOptionsPreloaded } from \"./create-atom.ts\"\nimport { createAtom } from \"./create-atom.ts\"\n\nconst helper = helpOption()\n\nconst CREATE_ATOM_OPTS = {\n\tdescription: `Check for breaking changes in a package.`,\n\toptionsSchema: z.object({\n\t\tpackageManager: z\n\t\t\t.union([\n\t\t\t\tz.literal(`bun`),\n\t\t\t\tz.literal(`npm`),\n\t\t\t\tz.literal(`pnpm`),\n\t\t\t\tz.literal(`yarn`),\n\t\t\t])\n\t\t\t.optional(),\n\t\tskipHints: z.boolean().optional(),\n\t}),\n\toptions: {\n\t\t...helper.options,\n\t\tpackageManager: {\n\t\t\tflag: `m`,\n\t\t\trequired: false,\n\t\t\tdescription: `The package manager to use.`,\n\t\t\texample: `--packageManager=\"npm\"`,\n\t\t},\n\t\tskipHints: {\n\t\t\tflag: `k`,\n\t\t\trequired: false,\n\t\t\tdescription: `Silences the 'Getting Started' info, mainly for use in other initializers that may wrap this one but provide their own scripts/instructions.`,\n\t\t\texample: `--skipHints`,\n\t\t\tparse: parseBooleanOption,\n\t\t},\n\t},\n} satisfies OptionsGroup<CreateAtomOptionsPreloaded>\n\nconst parse = cli(\n\t{\n\t\tcliName: `create-atom`,\n\t\troutes: optional({ $projectName: null }),\n\t\trouteOptions: {\n\t\t\t\"\": CREATE_ATOM_OPTS,\n\t\t\t$projectName: CREATE_ATOM_OPTS,\n\t\t},\n\t},\n\t{\n\t\terror: console.error.bind(console),\n\t\tinfo: () => {},\n\t},\n)\nconst { inputs } = parse(process.argv)\n\nawait createAtom(inputs.path[0], inputs.opts)\n"],"mappings":";;;;;;AASA,MAAM,SAAS,YAAY;AAE3B,MAAM,mBAAmB;CACxB,aAAa;CACb,eAAe,EAAE,OAAO;EACvB,gBAAgB,EACd,MAAM;GACN,EAAE,QAAQ,MAAM;GAChB,EAAE,QAAQ,MAAM;GAChB,EAAE,QAAQ,OAAO;GACjB,EAAE,QAAQ,OAAO;GACjB,CAAC,CACD,UAAU;EACZ,WAAW,EAAE,SAAS,CAAC,UAAU;EACjC,CAAC;CACF,SAAS;EACR,GAAG,OAAO;EACV,gBAAgB;GACf,MAAM;GACN,UAAU;GACV,aAAa;GACb,SAAS;GACT;EACD,WAAW;GACV,MAAM;GACN,UAAU;GACV,aAAa;GACb,SAAS;GACT,OAAO;GACP;EACD;CACD;AAgBD,MAAM,EAAE,WAdM,IACb;CACC,SAAS;CACT,QAAQ,SAAS,EAAE,cAAc,MAAM,CAAC;CACxC,cAAc;EACb,IAAI;EACJ,cAAc;EACd;CACD,EACD;CACC,OAAO,QAAQ,MAAM,KAAK,QAAQ;CAClC,YAAY;CACZ,CACD,CACwB,QAAQ,KAAK;AAEtC,MAAM,WAAW,OAAO,KAAK,IAAI,OAAO,KAAK"}
1
+ {"version":3,"file":"create-atom.x.js","names":[],"sources":["../src/create-atom.x.ts"],"sourcesContent":["#!/usr/bin/env node\n\nimport { type } from \"arktype\"\nimport type { OptionsGroup } from \"comline\"\nimport { cli, optional, options, parseBooleanOption } from \"comline\"\n\nimport type { CreateAtomOptionsPreloaded } from \"./create-atom.ts\"\nimport { createAtom } from \"./create-atom.ts\"\n\nconst CREATE_ATOM_OPTS = options(\n\t`Create a new project with atom.io.`,\n\ttype({\n\t\t\"packageManager?\": `\"bun\" | \"npm\" | \"pnpm\" | \"yarn\"`,\n\t\t\"skipHints?\": `boolean`,\n\t}),\n\t{\n\t\tpackageManager: {\n\t\t\tflag: `m`,\n\t\t\trequired: false,\n\t\t\tdescription: `The package manager to use.`,\n\t\t\texample: `--packageManager=\"npm\"`,\n\t\t},\n\t\tskipHints: {\n\t\t\tflag: `k`,\n\t\t\trequired: false,\n\t\t\tdescription: `Silences the 'Getting Started' info, mainly for use in other initializers that may wrap this one but provide their own scripts/instructions.`,\n\t\t\texample: `--skipHints`,\n\t\t\tparse: parseBooleanOption,\n\t\t},\n\t},\n) satisfies OptionsGroup<CreateAtomOptionsPreloaded>\n\nconst parse = cli(\n\t{\n\t\tcliName: `create-atom`,\n\t\troutes: optional({ $projectName: null }),\n\t\trouteOptions: {\n\t\t\t\"\": CREATE_ATOM_OPTS,\n\t\t\t$projectName: CREATE_ATOM_OPTS,\n\t\t},\n\t},\n\t{\n\t\terror: console.error.bind(console),\n\t\tinfo: () => {},\n\t},\n)\nconst { inputs } = parse(process.argv)\n\nawait createAtom(inputs.path[0], inputs.opts)\n"],"mappings":";;;;;;AASA,MAAM,mBAAmB,QACxB,sCACA,KAAK;CACJ,mBAAmB;CACnB,cAAc;CACd,CAAC,EACF;CACC,gBAAgB;EACf,MAAM;EACN,UAAU;EACV,aAAa;EACb,SAAS;EACT;CACD,WAAW;EACV,MAAM;EACN,UAAU;EACV,aAAa;EACb,SAAS;EACT,OAAO;EACP;CACD,CACD;AAgBD,MAAM,EAAE,WAdM,IACb;CACC,SAAS;CACT,QAAQ,SAAS,EAAE,cAAc,MAAM,CAAC;CACxC,cAAc;EACb,IAAI;EACJ,cAAc;EACd;CACD,EACD;CACC,OAAO,QAAQ,MAAM,KAAK,QAAQ;CAClC,YAAY;CACZ,CACD,CACwB,QAAQ,KAAK;AAEtC,MAAM,WAAW,OAAO,KAAK,IAAI,OAAO,KAAK"}
package/package.json CHANGED
@@ -1,56 +1,56 @@
1
1
  {
2
- "name": "create-atom.io",
3
- "version": "0.0.0",
4
- "license": "MIT",
5
- "author": {
6
- "name": "Jeremy Banka",
7
- "email": "hello@jeremybanka.com"
8
- },
9
- "publishConfig": {
10
- "access": "public"
11
- },
12
- "repository": {
13
- "type": "git",
14
- "url": "git+https://github.com/jeremybanka/wayforge.git",
15
- "directory": "packages/create-atom"
16
- },
17
- "type": "module",
18
- "files": [
19
- "bin",
20
- "dist",
21
- "src",
22
- "templates"
23
- ],
24
- "main": "dist/create-atom.js",
25
- "types": "dist/create-atom.d.ts",
26
- "bin": "./bin/create-atom.bin.js",
27
- "dependencies": {
28
- "@clack/prompts": "0.11.0",
29
- "comline": "workspace:*",
30
- "picocolors": "1.1.1",
31
- "tinyexec": "1.0.1",
32
- "zod": "3.25.76"
33
- },
34
- "scripts": {
35
- "build": "tsdown && rm -f dist/*.x.d.ts",
36
- "lint:biome": "biome check -- .",
37
- "lint:eslint": "eslint -- .",
38
- "lint:types": "tsgo --noEmit",
39
- "watch:types": "tsgo --watch --noEmit",
40
- "lint": "concurrently \"bun:lint:*\"",
41
- "test": "bun test --watch -- **/*.test.ts",
42
- "test:once": "bun test -- **/*.test.ts",
43
- "postversion": "biome format --write package.json"
44
- },
45
- "devDependencies": {
46
- "@types/node": "24.9.1",
47
- "@types/bun": "npm:bun-types@1.3.1",
48
- "@types/tmp": "0.2.6",
49
- "@typescript/native-preview": "7.0.0-dev.20251025.1",
50
- "concurrently": "9.2.1",
51
- "eslint": "9.38.0",
52
- "rimraf": "6.0.1",
53
- "tmp": "0.2.5",
54
- "tsdown": "0.15.9"
55
- }
56
- }
2
+ "name": "create-atom.io",
3
+ "version": "0.0.1",
4
+ "license": "MIT",
5
+ "author": {
6
+ "name": "Jeremy Banka",
7
+ "email": "hello@jeremybanka.com"
8
+ },
9
+ "publishConfig": {
10
+ "access": "public"
11
+ },
12
+ "repository": {
13
+ "type": "git",
14
+ "url": "git+https://github.com/jeremybanka/wayforge.git",
15
+ "directory": "packages/create-atom"
16
+ },
17
+ "type": "module",
18
+ "files": [
19
+ "bin",
20
+ "dist",
21
+ "src",
22
+ "templates"
23
+ ],
24
+ "main": "dist/create-atom.js",
25
+ "types": "dist/create-atom.d.ts",
26
+ "bin": "./bin/create-atom.bin.js",
27
+ "dependencies": {
28
+ "@clack/prompts": "0.11.0",
29
+ "arktype": "2.1.25",
30
+ "picocolors": "1.1.1",
31
+ "tinyexec": "1.0.1",
32
+ "comline": "0.4.2"
33
+ },
34
+ "devDependencies": {
35
+ "@types/node": "24.9.1",
36
+ "@types/bun": "npm:bun-types@1.3.1",
37
+ "@types/tmp": "0.2.6",
38
+ "@typescript/native-preview": "7.0.0-dev.20251025.1",
39
+ "concurrently": "9.2.1",
40
+ "eslint": "9.38.0",
41
+ "rimraf": "6.0.1",
42
+ "tmp": "0.2.5",
43
+ "tsdown": "0.15.9"
44
+ },
45
+ "scripts": {
46
+ "build": "tsdown && rm -f dist/*.x.d.ts",
47
+ "lint:biome": "biome check -- .",
48
+ "lint:eslint": "eslint -- .",
49
+ "lint:types": "tsgo --noEmit",
50
+ "watch:types": "tsgo --watch --noEmit",
51
+ "lint": "concurrently \"bun:lint:*\"",
52
+ "test": "bun test --watch -- **/*.test.ts",
53
+ "test:once": "bun test -- **/*.test.ts",
54
+ "postversion": "biome format --write package.json"
55
+ }
56
+ }
@@ -1,29 +1,19 @@
1
1
  #!/usr/bin/env node
2
2
 
3
+ import { type } from "arktype"
3
4
  import type { OptionsGroup } from "comline"
4
- import { cli, helpOption, optional, parseBooleanOption } from "comline"
5
- import { z } from "zod/v4"
5
+ import { cli, optional, options, parseBooleanOption } from "comline"
6
6
 
7
7
  import type { CreateAtomOptionsPreloaded } from "./create-atom.ts"
8
8
  import { createAtom } from "./create-atom.ts"
9
9
 
10
- const helper = helpOption()
11
-
12
- const CREATE_ATOM_OPTS = {
13
- description: `Check for breaking changes in a package.`,
14
- optionsSchema: z.object({
15
- packageManager: z
16
- .union([
17
- z.literal(`bun`),
18
- z.literal(`npm`),
19
- z.literal(`pnpm`),
20
- z.literal(`yarn`),
21
- ])
22
- .optional(),
23
- skipHints: z.boolean().optional(),
10
+ const CREATE_ATOM_OPTS = options(
11
+ `Create a new project with atom.io.`,
12
+ type({
13
+ "packageManager?": `"bun" | "npm" | "pnpm" | "yarn"`,
14
+ "skipHints?": `boolean`,
24
15
  }),
25
- options: {
26
- ...helper.options,
16
+ {
27
17
  packageManager: {
28
18
  flag: `m`,
29
19
  required: false,
@@ -38,7 +28,7 @@ const CREATE_ATOM_OPTS = {
38
28
  parse: parseBooleanOption,
39
29
  },
40
30
  },
41
- } satisfies OptionsGroup<CreateAtomOptionsPreloaded>
31
+ ) satisfies OptionsGroup<CreateAtomOptionsPreloaded>
42
32
 
43
33
  const parse = cli(
44
34
  {
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes