@geektech/tsone-cli 0.2.1 → 0.3.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/README.md +16 -6
- package/dist/cli.d.ts +4 -1
- package/dist/cli.js +14 -4
- package/dist/cli.js.map +3 -3
- package/dist/create.d.ts +16 -0
- package/dist/index-r68229k4.js +2978 -0
- package/dist/index-r68229k4.js.map +19 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/dist/index-8cbw0a0y.js +0 -3258
- package/dist/index-8cbw0a0y.js.map +0 -18
package/README.md
CHANGED
|
@@ -124,17 +124,23 @@ document.
|
|
|
124
124
|
|
|
125
125
|
## Command Line
|
|
126
126
|
|
|
127
|
+
`tsone create` scaffolds a basic TSone project into the current directory:
|
|
128
|
+
`package.json`, `tsone.config.ts`, `tsconfig.json`, `.gitignore`, and a
|
|
129
|
+
`src/main.ts` homepage that shows the TSone name and a link to the framework
|
|
130
|
+
GitHub repository. It refuses to overwrite existing files.
|
|
131
|
+
|
|
127
132
|
Development and build options are deliberately separate:
|
|
128
133
|
|
|
129
134
|
```text
|
|
135
|
+
tsone create
|
|
130
136
|
tsone dev [--host <host>] [--port <port>] [--no-watch]
|
|
131
137
|
tsone build [--out-dir <path>]
|
|
132
138
|
```
|
|
133
139
|
|
|
134
|
-
`dev` accepts `--host`, `--port`, and `--no-watch`;
|
|
135
|
-
`--out-dir`. Options override `tsone.config.ts`. Both
|
|
136
|
-
forms work, for example `--port 3000`, `--port=3000`,
|
|
137
|
-
`--out-dir=output`.
|
|
140
|
+
`create` takes no options. `dev` accepts `--host`, `--port`, and `--no-watch`;
|
|
141
|
+
`build` accepts only `--out-dir`. Options override `tsone.config.ts`. Both
|
|
142
|
+
separated and equals forms work, for example `--port 3000`, `--port=3000`,
|
|
143
|
+
`--out-dir output`, and `--out-dir=output`.
|
|
138
144
|
|
|
139
145
|
`tsone dev` watches the project by default: when a source, style, or config
|
|
140
146
|
file changes it rebuilds the current page and notifies connected browsers to
|
|
@@ -178,6 +184,7 @@ All tooling APIs come from `@geektech/tsone-cli`, not from the framework root:
|
|
|
178
184
|
```typescript
|
|
179
185
|
import {
|
|
180
186
|
build,
|
|
187
|
+
createProject,
|
|
181
188
|
defineConfig,
|
|
182
189
|
resolveConfig,
|
|
183
190
|
startDevServer,
|
|
@@ -206,6 +213,9 @@ console.log(result.root, result.outDir, result.assetsBuilt);
|
|
|
206
213
|
server. The caller owns its lifecycle and must call `server.stop()`.
|
|
207
214
|
- `build(options?)` validates the entry and output path, then returns
|
|
208
215
|
`{ root, outDir, assetsBuilt }`; the paths in the result are absolute.
|
|
216
|
+
- `createProject(options?)` writes a basic TSone scaffold into `options.root`
|
|
217
|
+
(defaults to the current working directory) and returns
|
|
218
|
+
`{ root, files }`; it refuses to overwrite existing files.
|
|
209
219
|
|
|
210
220
|
## Version 1 Scope
|
|
211
221
|
|
|
@@ -213,5 +223,5 @@ The development server serves HTTP only. Proxy targets may use HTTP or HTTPS.
|
|
|
213
223
|
CLI v1 has no config plugins, WebSocket, HMR, SSR, functional config,
|
|
214
224
|
`public/` directory copying, or public `minify` and `sourcemap`
|
|
215
225
|
configuration. Development bundles use an internal inline source map, while
|
|
216
|
-
|
|
217
|
-
configurable.
|
|
226
|
+
`tsone build` minifies production output by default; minification and
|
|
227
|
+
source-map controls are intentionally not configurable.
|
package/dist/cli.d.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
export interface CreateCliArgs {
|
|
2
|
+
command: 'create';
|
|
3
|
+
}
|
|
1
4
|
export interface DevCliArgs {
|
|
2
5
|
command: 'dev';
|
|
3
6
|
host?: string;
|
|
@@ -8,6 +11,6 @@ export interface BuildCliArgs {
|
|
|
8
11
|
command: 'build';
|
|
9
12
|
outDir?: string;
|
|
10
13
|
}
|
|
11
|
-
export type CliArgs = DevCliArgs | BuildCliArgs;
|
|
14
|
+
export type CliArgs = CreateCliArgs | DevCliArgs | BuildCliArgs;
|
|
12
15
|
export declare function parseCliArgs(argv: string[]): CliArgs;
|
|
13
16
|
export declare function runCli(argv?: string[]): Promise<void>;
|
package/dist/cli.js
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
build,
|
|
4
|
+
createProject,
|
|
4
5
|
startDevServer
|
|
5
|
-
} from "./index-
|
|
6
|
+
} from "./index-r68229k4.js";
|
|
6
7
|
|
|
7
8
|
// src/cli.ts
|
|
8
9
|
var USAGE = [
|
|
9
10
|
"Usage:",
|
|
11
|
+
" tsone create",
|
|
10
12
|
" tsone dev [--host <host>] [--port <port>] [--no-watch]",
|
|
11
13
|
" tsone build [--out-dir <path>]"
|
|
12
14
|
].join(`
|
|
@@ -14,7 +16,7 @@ var USAGE = [
|
|
|
14
16
|
var FLAG_OPTIONS = new Set(["--no-watch"]);
|
|
15
17
|
function parseCliArgs(argv) {
|
|
16
18
|
const command = argv[0];
|
|
17
|
-
if (command !== "dev" && command !== "build") {
|
|
19
|
+
if (command !== "create" && command !== "dev" && command !== "build") {
|
|
18
20
|
throw parseError(command === undefined ? "Missing command" : `Unknown command: ${command}`);
|
|
19
21
|
}
|
|
20
22
|
const options = new Map;
|
|
@@ -42,6 +44,9 @@ function parseCliArgs(argv) {
|
|
|
42
44
|
}
|
|
43
45
|
options.set(name, value);
|
|
44
46
|
}
|
|
47
|
+
if (command === "create") {
|
|
48
|
+
return { command };
|
|
49
|
+
}
|
|
45
50
|
if (command === "dev") {
|
|
46
51
|
const port = options.get("--port");
|
|
47
52
|
return {
|
|
@@ -58,6 +63,11 @@ function parseCliArgs(argv) {
|
|
|
58
63
|
}
|
|
59
64
|
async function runCli(argv = process.argv.slice(2)) {
|
|
60
65
|
const args = parseCliArgs(argv);
|
|
66
|
+
if (args.command === "create") {
|
|
67
|
+
const result2 = createProject();
|
|
68
|
+
console.log(`TSone project created at ${result2.root} (${result2.files.length} files)`);
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
61
71
|
if (args.command === "dev") {
|
|
62
72
|
const server = await startDevServer({
|
|
63
73
|
...args.host === undefined ? {} : { host: args.host },
|
|
@@ -87,7 +97,7 @@ function assertKnownOption(name) {
|
|
|
87
97
|
throw parseError(`Unknown option: ${name}`);
|
|
88
98
|
}
|
|
89
99
|
function assertSupportedOption(command, name) {
|
|
90
|
-
const supported = command === "dev" && (name === "--host" || name === "--port" || name === "--no-watch") || command === "build" && name === "--out-dir";
|
|
100
|
+
const supported = command === "create" && false || command === "dev" && (name === "--host" || name === "--port" || name === "--no-watch") || command === "build" && name === "--out-dir";
|
|
91
101
|
if (!supported) {
|
|
92
102
|
throw parseError(`Option ${name} is not supported for ${command}`);
|
|
93
103
|
}
|
|
@@ -112,5 +122,5 @@ export {
|
|
|
112
122
|
runCli
|
|
113
123
|
};
|
|
114
124
|
|
|
115
|
-
//# debugId=
|
|
125
|
+
//# debugId=F28094E403DF7A3D64756E2164756E21
|
|
116
126
|
//# sourceMappingURL=cli.js.map
|
package/dist/cli.js.map
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/cli.ts"],
|
|
4
4
|
"sourcesContent": [
|
|
5
|
-
"import { build } from './build';\nimport { startDevServer } from './server';\n\nconst USAGE = [\n 'Usage:',\n ' tsone dev [--host <host>] [--port <port>] [--no-watch]',\n ' tsone build [--out-dir <path>]',\n].join('\\n');\n\nconst FLAG_OPTIONS = new Set(['--no-watch']);\n\nexport interface DevCliArgs {\n command: 'dev';\n host?: string;\n port?: number;\n noWatch?: boolean;\n}\n\nexport interface BuildCliArgs {\n command: 'build';\n outDir?: string;\n}\n\nexport type CliArgs = DevCliArgs | BuildCliArgs;\n\nexport function parseCliArgs(argv: string[]): CliArgs {\n const command = argv[0];\n if (command !== 'dev' && command !== 'build') {\n throw parseError(\n command === undefined ? 'Missing command' : `Unknown command: ${command}`\n );\n }\n\n const options = new Map<string, string>();\n for (let index = 1; index < argv.length; index += 1) {\n const token = argv[index];\n if (!token.startsWith('--')) {\n throw parseError(`Unexpected positional argument: ${token}`);\n }\n\n const { name, inlineValue } = splitOption(token);\n assertKnownOption(name);\n assertSupportedOption(command, name);\n if (options.has(name)) {\n throw parseError(`Duplicate option: ${name}`);\n }\n if (FLAG_OPTIONS.has(name)) {\n options.set(name, 'true');\n continue;\n }\n\n const value = inlineValue ?? argv[index + 1];\n if (value === undefined || value === '' || value.startsWith('--')) {\n throw parseError(`Missing value for option: ${name}`);\n }\n if (inlineValue === undefined) {\n index += 1;\n }\n options.set(name, value);\n }\n\n if (command === 'dev') {\n const port = options.get('--port');\n return {\n command,\n ...(options.has('--host') ? { host: options.get('--host') } : {}),\n ...(port === undefined ? {} : { port: parsePort(port) }),\n ...(options.has('--no-watch') ? { noWatch: true } : {}),\n };\n }\n\n return {\n command,\n ...(options.has('--out-dir') ? { outDir: options.get('--out-dir') } : {}),\n };\n}\n\nexport async function runCli(\n argv: string[] = process.argv.slice(2)\n): Promise<void> {\n const args = parseCliArgs(argv);\n\n if (args.command === 'dev') {\n const server = await startDevServer({\n ...(args.host === undefined ? {} : { host: args.host }),\n ...(args.port === undefined ? {} : { port: args.port }),\n watch: !args.noWatch,\n });\n console.log(\n `TSone dev server listening at http://${server.hostname}:${server.port}`\n );\n return;\n }\n\n const result = await build(\n args.outDir === undefined ? {} : { outDir: args.outDir }\n );\n console.log(\n `TSone build completed: ${result.outDir} (${result.assetsBuilt.length} assets)`\n );\n}\n\nfunction splitOption(token: string): { name: string; inlineValue?: string } {\n const equalsIndex = token.indexOf('=');\n if (equalsIndex === -1) {\n return { name: token };\n }\n\n return {\n name: token.slice(0, equalsIndex),\n inlineValue: token.slice(equalsIndex + 1),\n };\n}\n\nfunction assertKnownOption(name: string): void {\n if (\n name === '--host' ||\n name === '--port' ||\n name === '--out-dir' ||\n name === '--no-watch'\n ) {\n return;\n }\n\n throw parseError(`Unknown option: ${name}`);\n}\n\nfunction assertSupportedOption(\n command: CliArgs['command'],\n name: string\n): void {\n const supported =\n (command === 'dev' &&\n (name === '--host' || name === '--port' || name === '--no-watch')) ||\n (command === 'build' && name === '--out-dir');\n\n if (!supported) {\n throw parseError(`Option ${name} is not supported for ${command}`);\n }\n}\n\nfunction parsePort(value: string): number {\n if (!/^\\d+$/.test(value)) {\n throw parseError('Port must be an integer between 0 and 65535');\n }\n\n const port = Number(value);\n if (!Number.isInteger(port) || port < 0 || port > 65535) {\n throw parseError('Port must be an integer between 0 and 65535');\n }\n\n return port;\n}\n\nfunction parseError(message: string): Error {\n return new Error(`${message}\\n\\n${USAGE}`);\n}\n"
|
|
5
|
+
"import { build } from './build';\nimport { createProject } from './create';\nimport { startDevServer } from './server';\n\nconst USAGE = [\n 'Usage:',\n ' tsone create',\n ' tsone dev [--host <host>] [--port <port>] [--no-watch]',\n ' tsone build [--out-dir <path>]',\n].join('\\n');\n\nconst FLAG_OPTIONS = new Set(['--no-watch']);\n\nexport interface CreateCliArgs {\n command: 'create';\n}\n\nexport interface DevCliArgs {\n command: 'dev';\n host?: string;\n port?: number;\n noWatch?: boolean;\n}\n\nexport interface BuildCliArgs {\n command: 'build';\n outDir?: string;\n}\n\nexport type CliArgs = CreateCliArgs | DevCliArgs | BuildCliArgs;\n\nexport function parseCliArgs(argv: string[]): CliArgs {\n const command = argv[0];\n if (command !== 'create' && command !== 'dev' && command !== 'build') {\n throw parseError(\n command === undefined ? 'Missing command' : `Unknown command: ${command}`\n );\n }\n\n const options = new Map<string, string>();\n for (let index = 1; index < argv.length; index += 1) {\n const token = argv[index];\n if (!token.startsWith('--')) {\n throw parseError(`Unexpected positional argument: ${token}`);\n }\n\n const { name, inlineValue } = splitOption(token);\n assertKnownOption(name);\n assertSupportedOption(command, name);\n if (options.has(name)) {\n throw parseError(`Duplicate option: ${name}`);\n }\n if (FLAG_OPTIONS.has(name)) {\n options.set(name, 'true');\n continue;\n }\n\n const value = inlineValue ?? argv[index + 1];\n if (value === undefined || value === '' || value.startsWith('--')) {\n throw parseError(`Missing value for option: ${name}`);\n }\n if (inlineValue === undefined) {\n index += 1;\n }\n options.set(name, value);\n }\n\n if (command === 'create') {\n return { command };\n }\n\n if (command === 'dev') {\n const port = options.get('--port');\n return {\n command,\n ...(options.has('--host') ? { host: options.get('--host') } : {}),\n ...(port === undefined ? {} : { port: parsePort(port) }),\n ...(options.has('--no-watch') ? { noWatch: true } : {}),\n };\n }\n\n return {\n command,\n ...(options.has('--out-dir') ? { outDir: options.get('--out-dir') } : {}),\n };\n}\n\nexport async function runCli(\n argv: string[] = process.argv.slice(2)\n): Promise<void> {\n const args = parseCliArgs(argv);\n\n if (args.command === 'create') {\n const result = createProject();\n console.log(\n `TSone project created at ${result.root} (${result.files.length} files)`\n );\n return;\n }\n\n if (args.command === 'dev') {\n const server = await startDevServer({\n ...(args.host === undefined ? {} : { host: args.host }),\n ...(args.port === undefined ? {} : { port: args.port }),\n watch: !args.noWatch,\n });\n console.log(\n `TSone dev server listening at http://${server.hostname}:${server.port}`\n );\n return;\n }\n\n const result = await build(\n args.outDir === undefined ? {} : { outDir: args.outDir }\n );\n console.log(\n `TSone build completed: ${result.outDir} (${result.assetsBuilt.length} assets)`\n );\n}\n\nfunction splitOption(token: string): { name: string; inlineValue?: string } {\n const equalsIndex = token.indexOf('=');\n if (equalsIndex === -1) {\n return { name: token };\n }\n\n return {\n name: token.slice(0, equalsIndex),\n inlineValue: token.slice(equalsIndex + 1),\n };\n}\n\nfunction assertKnownOption(name: string): void {\n if (\n name === '--host' ||\n name === '--port' ||\n name === '--out-dir' ||\n name === '--no-watch'\n ) {\n return;\n }\n\n throw parseError(`Unknown option: ${name}`);\n}\n\nfunction assertSupportedOption(\n command: CliArgs['command'],\n name: string\n): void {\n const supported =\n (command === 'create' && false) ||\n (command === 'dev' &&\n (name === '--host' || name === '--port' || name === '--no-watch')) ||\n (command === 'build' && name === '--out-dir');\n\n if (!supported) {\n throw parseError(`Option ${name} is not supported for ${command}`);\n }\n}\n\nfunction parsePort(value: string): number {\n if (!/^\\d+$/.test(value)) {\n throw parseError('Port must be an integer between 0 and 65535');\n }\n\n const port = Number(value);\n if (!Number.isInteger(port) || port < 0 || port > 65535) {\n throw parseError('Port must be an integer between 0 and 65535');\n }\n\n return port;\n}\n\nfunction parseError(message: string): Error {\n return new Error(`${message}\\n\\n${USAGE}`);\n}\n"
|
|
6
6
|
],
|
|
7
|
-
"mappings": "
|
|
8
|
-
"debugId": "
|
|
7
|
+
"mappings": ";;;;;;;;AAIA,IAAM,QAAQ;AAAA,EACZ;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,EAAE,KAAK;AAAA,CAAI;AAEX,IAAM,eAAe,IAAI,IAAI,CAAC,YAAY,CAAC;AAoBpC,SAAS,YAAY,CAAC,MAAyB;AAAA,EACpD,MAAM,UAAU,KAAK;AAAA,EACrB,IAAI,YAAY,YAAY,YAAY,SAAS,YAAY,SAAS;AAAA,IACpE,MAAM,WACJ,YAAY,YAAY,oBAAoB,oBAAoB,SAClE;AAAA,EACF;AAAA,EAEA,MAAM,UAAU,IAAI;AAAA,EACpB,SAAS,QAAQ,EAAG,QAAQ,KAAK,QAAQ,SAAS,GAAG;AAAA,IACnD,MAAM,QAAQ,KAAK;AAAA,IACnB,IAAI,CAAC,MAAM,WAAW,IAAI,GAAG;AAAA,MAC3B,MAAM,WAAW,mCAAmC,OAAO;AAAA,IAC7D;AAAA,IAEA,QAAQ,MAAM,gBAAgB,YAAY,KAAK;AAAA,IAC/C,kBAAkB,IAAI;AAAA,IACtB,sBAAsB,SAAS,IAAI;AAAA,IACnC,IAAI,QAAQ,IAAI,IAAI,GAAG;AAAA,MACrB,MAAM,WAAW,qBAAqB,MAAM;AAAA,IAC9C;AAAA,IACA,IAAI,aAAa,IAAI,IAAI,GAAG;AAAA,MAC1B,QAAQ,IAAI,MAAM,MAAM;AAAA,MACxB;AAAA,IACF;AAAA,IAEA,MAAM,QAAQ,eAAe,KAAK,QAAQ;AAAA,IAC1C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AAAA,EAChE;AAAA,EAEA,OAAO;AAAA;AAGT,SAAS,UAAU,CAAC,SAAwB;AAAA,EAC1C,OAAO,IAAI,MAAM,GAAG;AAAA;AAAA,EAAc,OAAO;AAAA;",
|
|
8
|
+
"debugId": "F28094E403DF7A3D64756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|
package/dist/create.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export interface CreateProjectOptions {
|
|
2
|
+
/** Target directory; defaults to the current working directory. */
|
|
3
|
+
root?: string;
|
|
4
|
+
/** Package name; defaults to the target directory basename. */
|
|
5
|
+
name?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface CreateProjectResult {
|
|
8
|
+
root: string;
|
|
9
|
+
files: string[];
|
|
10
|
+
}
|
|
11
|
+
/** Published framework version referenced by generated projects. */
|
|
12
|
+
export declare const TSONE_FRAMEWORK_VERSION = "0.2.1";
|
|
13
|
+
/** Published CLI version referenced by generated projects. */
|
|
14
|
+
export declare const TSONE_CLI_VERSION = "0.2.2";
|
|
15
|
+
export declare const GITHUB_URL = "https://github.com/geektech-team/tsone";
|
|
16
|
+
export declare function createProject(options?: CreateProjectOptions): CreateProjectResult;
|