@tonk/cli 0.1.1 → 0.1.3
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 +2 -2
- package/dist/commands/create.js +5 -5
- package/dist/commands/create.js.map +1 -1
- package/dist/commands/hello.d.ts +3 -0
- package/dist/commands/hello.d.ts.map +1 -0
- package/dist/commands/hello.js +36 -0
- package/dist/commands/hello.js.map +1 -0
- package/dist/tonk.js +2 -0
- package/dist/tonk.js.map +1 -1
- package/package.json +1 -3
package/README.md
CHANGED
package/dist/commands/create.js
CHANGED
|
@@ -2,16 +2,16 @@ import { Command } from 'commander';
|
|
|
2
2
|
import child_process from 'child_process';
|
|
3
3
|
export const createCommand = new Command('create')
|
|
4
4
|
.description('Create a new tonk application or component')
|
|
5
|
-
.
|
|
6
|
-
.action(
|
|
5
|
+
.argument('[name]', 'Name of the application')
|
|
6
|
+
.action(name => {
|
|
7
7
|
console.log('Creating a new tonk app...');
|
|
8
8
|
try {
|
|
9
9
|
// Build the command with any passed options
|
|
10
10
|
let createCommand = 'npx @tonk/create';
|
|
11
11
|
// Pass through any options provided to the CLI
|
|
12
|
-
if (
|
|
13
|
-
createCommand += `
|
|
14
|
-
|
|
12
|
+
if (name)
|
|
13
|
+
createCommand += ` "${name}"`;
|
|
14
|
+
console.log(createCommand);
|
|
15
15
|
// Execute the create package
|
|
16
16
|
child_process.execSync(createCommand, {
|
|
17
17
|
stdio: 'inherit',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../src/commands/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,aAAa,MAAM,eAAe,CAAC;AAE1C,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,OAAO,CAAC,QAAQ,CAAC;KAC/C,WAAW,CAAC,4CAA4C,CAAC;KACzD,
|
|
1
|
+
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../src/commands/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,aAAa,MAAM,eAAe,CAAC;AAE1C,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,OAAO,CAAC,QAAQ,CAAC;KAC/C,WAAW,CAAC,4CAA4C,CAAC;KACzD,QAAQ,CAAC,QAAQ,EAAE,yBAAyB,CAAC;KAC7C,MAAM,CAAC,IAAI,CAAC,EAAE;IACb,OAAO,CAAC,GAAG,CAAC,4BAA4B,CAAC,CAAC;IAE1C,IAAI,CAAC;QACH,4CAA4C;QAC5C,IAAI,aAAa,GAAG,kBAAkB,CAAC;QAEvC,+CAA+C;QAC/C,IAAI,IAAI;YAAE,aAAa,IAAI,KAAK,IAAI,GAAG,CAAC;QAExC,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC;QAE3B,6BAA6B;QAC7B,aAAa,CAAC,QAAQ,CAAC,aAAa,EAAE;YACpC,KAAK,EAAE,SAAS;YAChB,GAAG,EAAE,EAAC,GAAG,OAAO,CAAC,GAAG,EAAC;SACtB,CAAC,CAAC;QAEH,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAC;QACjD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,KAAK,CAAC,CAAC;QACnD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hello.d.ts","sourceRoot":"","sources":["../../src/commands/hello.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAGlC,eAAO,MAAM,YAAY,SAoCrB,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
export const helloCommand = new Command('hello')
|
|
4
|
+
.description('Display a welcome message for Tonk')
|
|
5
|
+
.action(() => {
|
|
6
|
+
console.log(`
|
|
7
|
+
・。゜☆。・゜。・。゜☆。・゜★・。゜☆。・゜。・。゜☆。・゜☆。・゜
|
|
8
|
+
|
|
9
|
+
_____ U ___ u _ _ _ __
|
|
10
|
+
|_ " _| \\/"_ \\/ | \\ |"| |"|/ /
|
|
11
|
+
| | | | | |<| \\| |> | ' /
|
|
12
|
+
/| |\\.-,_| |_| |U| |\\ |u U/| . \\\\u
|
|
13
|
+
u |_|U \\_)-\\___/ |_| \\_| |_|\\_\\
|
|
14
|
+
_// \\\\_ \\\\ || \\\\,-.,-,>> \\\\,-.
|
|
15
|
+
(__) (__) (__) (_") (_/ \\.) (_/
|
|
16
|
+
|
|
17
|
+
・。゜☆。・゜。・。゜☆。・゜★・。゜☆。・゜。・。゜☆。・゜☆。・゜
|
|
18
|
+
|
|
19
|
+
Welcome to Tonk!
|
|
20
|
+
|
|
21
|
+
We're excited to work with you in building your own ☆𝐿𝒾𝓉𝓉𝓁𝑒 𝐼𝓃𝓉𝑒𝓇𝓃𝑒𝓉☆.
|
|
22
|
+
|
|
23
|
+
To get started...
|
|
24
|
+
|
|
25
|
+
1. Create your first app by running the command: ${chalk.cyan('tonk create [app name]')}
|
|
26
|
+
2. Start the app with: ${chalk.cyan('npm run dev')}
|
|
27
|
+
3. Open in your favorite code editor and vibe.
|
|
28
|
+
|
|
29
|
+
You can find more information and how to reach us at ${chalk.blue('https://tonk.xyz')}
|
|
30
|
+
Feel free to ask for help in the Telegram chat or just say hello.
|
|
31
|
+
|
|
32
|
+
Cheers!
|
|
33
|
+
`);
|
|
34
|
+
process.exit(0);
|
|
35
|
+
});
|
|
36
|
+
//# sourceMappingURL=hello.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hello.js","sourceRoot":"","sources":["../../src/commands/hello.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,CAAC,MAAM,YAAY,GAAG,IAAI,OAAO,CAAC,OAAO,CAAC;KAC7C,WAAW,CAAC,oCAAoC,CAAC;KACjD,MAAM,CAAC,GAAG,EAAE;IACX,OAAO,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;mDAmBmC,KAAK,CAAC,IAAI,CACvD,wBAAwB,CACzB;yBACoB,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC;;;uDAGK,KAAK,CAAC,IAAI,CAC3D,kBAAkB,CACnB;;;;CAIJ,CAAC,CAAC;IACC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
|
package/dist/tonk.js
CHANGED
|
@@ -4,6 +4,7 @@ import { devCommand } from './commands/dev.js';
|
|
|
4
4
|
import { serveCommand } from './commands/serve.js';
|
|
5
5
|
import { deployCommand } from './commands/deploy.js';
|
|
6
6
|
import { configCommand } from './commands/config.js';
|
|
7
|
+
import { helloCommand } from './commands/hello.js';
|
|
7
8
|
const program = new Command();
|
|
8
9
|
// Main program setup
|
|
9
10
|
program
|
|
@@ -18,6 +19,7 @@ program.addCommand(devCommand);
|
|
|
18
19
|
program.addCommand(serveCommand);
|
|
19
20
|
program.addCommand(deployCommand);
|
|
20
21
|
program.addCommand(configCommand);
|
|
22
|
+
program.addCommand(helloCommand);
|
|
21
23
|
// Parse arguments
|
|
22
24
|
program.parse();
|
|
23
25
|
// Show help if no arguments provided
|
package/dist/tonk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tonk.js","sourceRoot":"","sources":["../src/tonk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,EAAC,aAAa,EAAC,MAAM,sBAAsB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AClB,OAAO,CAAC,KAAK,EAAE,CAAC;AAEhB,qCAAqC;AACrC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IAClC,OAAO,CAAC,UAAU,EAAE,CAAC;AACvB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tonk/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "The Tonk stack command line utility",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -36,9 +36,7 @@
|
|
|
36
36
|
"posttest": "npm run lint"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@modelcontextprotocol/sdk": "^1.6.1",
|
|
40
39
|
"@tonk/server": "^0.1.0",
|
|
41
|
-
"@tonk/create": "^0.1.1",
|
|
42
40
|
"chalk": "^5.3.0",
|
|
43
41
|
"commander": "^11.1.0",
|
|
44
42
|
"dotenv": "^16.4.7",
|