@ossy/cli 1.16.7 → 1.16.9
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 +3 -5
- package/package.json +3 -3
- package/src/index.js +2 -6
- package/src/init/cli.js +1 -2
package/README.md
CHANGED
|
@@ -1,22 +1,20 @@
|
|
|
1
1
|
# @ossy/cli
|
|
2
2
|
|
|
3
|
-
Unified CLI for the Ossy platform: app
|
|
3
|
+
Unified CLI for the Ossy platform: app build and CMS workflows.
|
|
4
4
|
|
|
5
5
|
## Commands
|
|
6
6
|
|
|
7
7
|
| Command | Description |
|
|
8
8
|
|---------|-------------|
|
|
9
9
|
| `init [dir]` | Scaffold a new Ossy app (default: current directory) |
|
|
10
|
-
| `dev` | Start dev server with watch (uses `src/**/*.page.jsx`, `src/config.js`) |
|
|
11
10
|
| `build` | Production build |
|
|
12
11
|
| `publish` | Queue a container deployment via `@ossy/deployment-tools` (**temporary**; see below), then upload `resourceTemplates` and **site build artifacts** (S3 presign + CMS resource) when `workspaceId` is set |
|
|
13
12
|
| `cms upload` | Upload resource templates only (same API as publish’s upload step) |
|
|
14
13
|
| `cms validate` | Validate ossy config and resource templates |
|
|
15
14
|
|
|
16
|
-
## App:
|
|
15
|
+
## App: build
|
|
17
16
|
|
|
18
17
|
```bash
|
|
19
|
-
npx @ossy/cli dev
|
|
20
18
|
npx @ossy/cli build
|
|
21
19
|
```
|
|
22
20
|
|
|
@@ -88,7 +86,7 @@ When **`--config`** is omitted, **`./src/config.js`** is used if it exists (same
|
|
|
88
86
|
|
|
89
87
|
### Config consistency
|
|
90
88
|
|
|
91
|
-
- **App** (`
|
|
89
|
+
- **App** (`build`), **CMS** (`cms upload` / `cms validate`), and **publish** all use **`--config`** (`-c`) for the app / workspace config file (`src/config.js` by default when present).
|
|
92
90
|
|
|
93
91
|
### Workflow example
|
|
94
92
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ossy/cli",
|
|
3
|
-
"version": "1.16.
|
|
3
|
+
"version": "1.16.9",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/ossy-se/packages.git"
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"bin": "./src/index.js",
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@babel/parser": "^7.28.6",
|
|
21
|
-
"@ossy/app": "^1.16.
|
|
21
|
+
"@ossy/app": "^1.16.9",
|
|
22
22
|
"arg": "^5.0.2",
|
|
23
23
|
"glob": "^10.3.10"
|
|
24
24
|
},
|
|
@@ -30,5 +30,5 @@
|
|
|
30
30
|
"/src",
|
|
31
31
|
"README.md"
|
|
32
32
|
],
|
|
33
|
-
"gitHead": "
|
|
33
|
+
"gitHead": "be7612ac40cc49e027b0e417938cda738e19cd58"
|
|
34
34
|
}
|
package/src/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { build
|
|
2
|
+
import { build } from '@ossy/app'
|
|
3
3
|
import * as Cms from './cms/cli.js'
|
|
4
4
|
import * as Init from './init/cli.js'
|
|
5
5
|
import { publish } from './publish/cli.js'
|
|
@@ -9,7 +9,7 @@ const [,, command, ...restArgs] = process.argv
|
|
|
9
9
|
|
|
10
10
|
if (!command) {
|
|
11
11
|
console.error(
|
|
12
|
-
'[@ossy/cli] No command provided. Usage: ossy
|
|
12
|
+
'[@ossy/cli] No command provided. Usage: ossy build [--worker] | publish | registry <subcommand> | init | cms <subcommand>'
|
|
13
13
|
)
|
|
14
14
|
process.exit(1)
|
|
15
15
|
}
|
|
@@ -31,10 +31,6 @@ const run = async () => {
|
|
|
31
31
|
await publish(restArgs)
|
|
32
32
|
return
|
|
33
33
|
}
|
|
34
|
-
if (command === 'dev') {
|
|
35
|
-
await dev(restArgs)
|
|
36
|
-
return
|
|
37
|
-
}
|
|
38
34
|
if (command === 'build') {
|
|
39
35
|
await build(restArgs)
|
|
40
36
|
return
|
package/src/init/cli.js
CHANGED
|
@@ -26,7 +26,6 @@ const TEMPLATE_PACKAGE_JSON = {
|
|
|
26
26
|
private: true,
|
|
27
27
|
type: 'module',
|
|
28
28
|
scripts: {
|
|
29
|
-
dev: 'app dev',
|
|
30
29
|
build: 'app build',
|
|
31
30
|
start: 'node build/server.js',
|
|
32
31
|
},
|
|
@@ -69,5 +68,5 @@ export const init = (options) => {
|
|
|
69
68
|
logInfo({ message: '[@ossy/cli] package.json exists, skipping. Add scripts manually if needed.' })
|
|
70
69
|
}
|
|
71
70
|
|
|
72
|
-
logInfo({ message: '[@ossy/cli] Done. Run: npm install && npm run
|
|
71
|
+
logInfo({ message: '[@ossy/cli] Done. Run: npm install && npm run build' })
|
|
73
72
|
}
|