neutrinos-cli 2.0.0-beta.0 → 2.0.0-beta.2
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 +77 -111
- package/dist/src/commands/new-workspace.js +4 -4
- package/package.json +2 -3
package/README.md
CHANGED
|
@@ -1,173 +1,139 @@
|
|
|
1
1
|
# neutrinos CLI
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A command-line interface for managing, developing, and publishing alpha plugin packages.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
**Requires Node.js 22+**
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
## Installation
|
|
8
8
|
|
|
9
9
|
```sh
|
|
10
|
+
# Stable
|
|
10
11
|
npm i -g neutrinos-cli
|
|
12
|
+
|
|
13
|
+
# Beta
|
|
14
|
+
npm i -g neutrinos-cli@beta
|
|
11
15
|
```
|
|
12
16
|
|
|
13
|
-
|
|
17
|
+
## Quick Start
|
|
14
18
|
|
|
15
19
|
```sh
|
|
16
|
-
|
|
20
|
+
neutrinos new my-workspace
|
|
21
|
+
cd my-workspace
|
|
22
|
+
neutrinos generate component my-button
|
|
23
|
+
neutrinos build plugins
|
|
24
|
+
neutrinos start
|
|
17
25
|
```
|
|
18
26
|
|
|
19
|
-
### Commands
|
|
20
|
-
|
|
21
|
-
- `new <name>` Create a new project
|
|
22
|
-
- `generate` | `g` Generate a new plugin. Run "help generate" for more information.
|
|
23
|
-
- `auth` Perform authentication tasks like login, logout, or status
|
|
24
|
-
- `publish [options] [packageName]` Bundle and publish the plugin
|
|
25
|
-
- `build <type> [pluginName]` Build the plugin
|
|
26
|
-
- `start [options]` Start the live server for the plugin
|
|
27
|
-
- `serve` Start the express server that serves the plugins
|
|
28
|
-
|
|
29
|
-
### Options
|
|
30
|
-
|
|
31
|
-
- `-v, --version` Output the version number
|
|
32
|
-
- `-h, --help` Display help for command
|
|
33
|
-
|
|
34
|
-
---
|
|
35
|
-
|
|
36
27
|
## Commands
|
|
37
28
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
29
|
+
```
|
|
30
|
+
neutrinos <command> [options]
|
|
31
|
+
```
|
|
41
32
|
|
|
42
|
-
|
|
33
|
+
| Command | Description |
|
|
34
|
+
|---------|-------------|
|
|
35
|
+
| `new <name>` | Create a new plugin workspace |
|
|
36
|
+
| `generate\|g` | Generate a component, module, or attribute |
|
|
37
|
+
| `build <type> [name]` | Build plugins (`plugins` or `docker`) |
|
|
38
|
+
| `start` | Start the Vite dev server |
|
|
39
|
+
| `serve` | Start the Express plugins server |
|
|
40
|
+
| `publish [name]` | Bundle and publish a package |
|
|
41
|
+
| `deprecate [name]` | Deprecate a published package |
|
|
42
|
+
| `auth` | Login or check auth state |
|
|
43
|
+
| `completion <shell>` | Output shell completion script (`bash` or `zsh`) |
|
|
43
44
|
|
|
44
|
-
|
|
45
|
+
### `new <name>`
|
|
45
46
|
|
|
46
|
-
|
|
47
|
+
Create a new workspace with scaffold files, plugin.json, git init, and npm install.
|
|
47
48
|
|
|
48
49
|
```sh
|
|
49
|
-
|
|
50
|
+
neutrinos new my-workspace
|
|
50
51
|
```
|
|
51
52
|
|
|
52
|
-
##### Arguments
|
|
53
|
-
|
|
54
|
-
- `<name>` project or workspace name
|
|
55
|
-
|
|
56
|
-
---
|
|
57
|
-
|
|
58
53
|
### `generate` | `g`
|
|
59
54
|
|
|
60
|
-
##### Description
|
|
61
|
-
|
|
62
|
-
- Generate a new component or module
|
|
63
|
-
|
|
64
|
-
##### Usage
|
|
65
|
-
|
|
66
55
|
```sh
|
|
67
|
-
|
|
56
|
+
neutrinos generate component <name> [-d <description>]
|
|
57
|
+
neutrinos generate module <name> [-d <description>]
|
|
58
|
+
neutrinos generate attribute [componentName] [options]
|
|
68
59
|
```
|
|
69
60
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
- `component <name>` | `c <name>` Component is a package enabling drag and drop functionality within the canvas
|
|
73
|
-
- `module <name>` | `m <name>` Module is a globally accessible package, available throughout the entire project on `alpha.plugins` | `ap`.
|
|
74
|
-
- `attribute [command] [options]` | `a [command] [options]` Generate an Attribute for a component, Read the `ATTRIBUTE.md` file in projetc/workspcae directory for more help
|
|
75
|
-
|
|
76
|
-
##### Arguments
|
|
77
|
-
|
|
78
|
-
- `<name>` component or module name
|
|
79
|
-
|
|
80
|
-
---
|
|
61
|
+
Aliases: `g`, `c`, `m`, `a`
|
|
81
62
|
|
|
82
|
-
|
|
63
|
+
Attribute options: `-t` type, `-u` ui-type, `-l` label, `-e` event, `-c` category, `-p` placeholder, `-d` defaultValue, `-o` options, `-f` fieldMappings, `-n` validation. See `ATTRIBUTE.md` in your workspace for details.
|
|
83
64
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
- Build the plugins
|
|
87
|
-
|
|
88
|
-
#### Usage
|
|
65
|
+
### `build <type> [pluginName]`
|
|
89
66
|
|
|
90
67
|
```sh
|
|
91
|
-
|
|
68
|
+
neutrinos build plugins [name] [--module] [--all]
|
|
69
|
+
neutrinos build docker [name]
|
|
92
70
|
```
|
|
93
71
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
-
|
|
97
|
-
- `
|
|
98
|
-
|
|
99
|
-
---
|
|
100
|
-
|
|
101
|
-
## `start [options]`
|
|
72
|
+
- `plugins` — Runs tsc + Vite build, copies output to plugins-server
|
|
73
|
+
- `docker` — Builds plugins then runs `docker build`
|
|
74
|
+
- `--module` — Skip tsc (for JS-only modules)
|
|
75
|
+
- `--all` — Build all packages in the workspace
|
|
102
76
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
- Start the live server for the workspace
|
|
106
|
-
|
|
107
|
-
#### Usage
|
|
77
|
+
### `start`
|
|
108
78
|
|
|
109
79
|
```sh
|
|
110
|
-
|
|
80
|
+
neutrinos start [-p <port>]
|
|
111
81
|
```
|
|
112
82
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
- `-p, --port <port>` Port to start the server on, default is 6969
|
|
83
|
+
Starts a Vite dev server. Default port: 6969.
|
|
116
84
|
|
|
117
|
-
|
|
85
|
+
### `serve`
|
|
118
86
|
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
87
|
+
```sh
|
|
88
|
+
neutrinos serve [-p <port>]
|
|
89
|
+
```
|
|
122
90
|
|
|
123
|
-
|
|
91
|
+
Starts the Express server that serves built plugins. Default port: 3000.
|
|
124
92
|
|
|
125
|
-
|
|
93
|
+
### `publish [packageName]`
|
|
126
94
|
|
|
127
95
|
```sh
|
|
128
|
-
|
|
96
|
+
neutrinos publish [name] [-t <patch|minor|major>] [-d <displayName>] [-i <iconPath>] [-m <images...>] [--accept-defaults] [--all]
|
|
129
97
|
```
|
|
130
98
|
|
|
131
|
-
|
|
99
|
+
Authenticates, builds, zips, and uploads the package to the marketplace. Prompts for missing metadata unless `--accept-defaults` is passed.
|
|
132
100
|
|
|
133
|
-
### `
|
|
101
|
+
### `deprecate [packageName]`
|
|
134
102
|
|
|
135
|
-
|
|
103
|
+
```sh
|
|
104
|
+
neutrinos deprecate [name] [-y] [--all]
|
|
105
|
+
```
|
|
136
106
|
|
|
137
|
-
|
|
107
|
+
Marks a published package as deprecated. Prompts for confirmation unless `-y` is passed.
|
|
138
108
|
|
|
139
|
-
|
|
109
|
+
### `auth`
|
|
140
110
|
|
|
141
111
|
```sh
|
|
142
|
-
|
|
112
|
+
neutrinos auth login # Opens browser for OIDC login
|
|
113
|
+
neutrinos auth state # Shows current auth state
|
|
143
114
|
```
|
|
144
115
|
|
|
145
|
-
|
|
116
|
+
### `completion`
|
|
146
117
|
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
---
|
|
118
|
+
```sh
|
|
119
|
+
# Bash
|
|
120
|
+
neutrinos completion bash >> ~/.bashrc
|
|
151
121
|
|
|
152
|
-
|
|
122
|
+
# Zsh
|
|
123
|
+
neutrinos completion zsh >> ~/.zshrc
|
|
124
|
+
```
|
|
153
125
|
|
|
154
|
-
|
|
126
|
+
## Global Options
|
|
155
127
|
|
|
156
|
-
-
|
|
128
|
+
- `-v, --version` — Show version
|
|
129
|
+
- `-h, --help` — Show help
|
|
157
130
|
|
|
158
|
-
|
|
131
|
+
## Development
|
|
159
132
|
|
|
160
133
|
```sh
|
|
161
|
-
|
|
134
|
+
pnpm install
|
|
135
|
+
pnpm build # tsc
|
|
136
|
+
pnpm test # vitest
|
|
137
|
+
pnpm publish:beta # build + test + npm publish --tag beta
|
|
138
|
+
pnpm publish:latest # build + test + npm publish --tag latest
|
|
162
139
|
```
|
|
163
|
-
|
|
164
|
-
#### Arguments
|
|
165
|
-
|
|
166
|
-
- `PackageName` The name of the component/module to publish, if not cli will show the list of packages inside the current workspace/project
|
|
167
|
-
|
|
168
|
-
#### Options
|
|
169
|
-
|
|
170
|
-
- `-t, --version-type <versionType>` Version type for verion up, it can be one of `patch`, `minor`, `major`
|
|
171
|
-
- `-d, --display-name <displayName>` Display Name for the package
|
|
172
|
-
- `-i, --icon <iconPath>` Path to the icon
|
|
173
|
-
- `-m, --images <imagePaths...>` path to the image
|
|
@@ -83,12 +83,12 @@ const initializePackages = async (dir) => {
|
|
|
83
83
|
serve: 'neutrinos serve',
|
|
84
84
|
};
|
|
85
85
|
pkgJson.devDependencies = {
|
|
86
|
-
lit: '^3.
|
|
87
|
-
typescript: '^5.
|
|
86
|
+
lit: '^3.3.2',
|
|
87
|
+
typescript: '^5.9.3',
|
|
88
88
|
};
|
|
89
89
|
pkgJson.dependencies = {
|
|
90
|
-
express: '^
|
|
91
|
-
'@jatahworx/alpha-annotations-lib': '^1.0.
|
|
90
|
+
express: '^5.2.1',
|
|
91
|
+
'@jatahworx/alpha-annotations-lib': '^1.0.12',
|
|
92
92
|
};
|
|
93
93
|
pkgJson.workspaces = ['packages/*'];
|
|
94
94
|
pkgJson.type = 'module';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "neutrinos-cli",
|
|
3
|
-
"version": "2.0.0-beta.
|
|
3
|
+
"version": "2.0.0-beta.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"bin": {
|
|
6
6
|
"neutrinos": "./dist/src/bin/cli.js"
|
|
@@ -38,8 +38,7 @@
|
|
|
38
38
|
"colorette": "^2.0.20",
|
|
39
39
|
"commander": "^12.0.0",
|
|
40
40
|
"dotenv": "^16.4.5",
|
|
41
|
-
"
|
|
42
|
-
"fastify": "^4.26.2",
|
|
41
|
+
"fastify": "^5.8.2",
|
|
43
42
|
"handlebars": "^4.7.8",
|
|
44
43
|
"inquirer": "^13.3.2",
|
|
45
44
|
"open": "^10.1.0",
|