@lincyaw/cli 1.0.0-rc.13 → 1.0.0-rc.15
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/package.json +6 -6
- package/src/messages.ts +5 -6
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ Part of [Presmium](https://github.com/Lincyaw/presmium), which turns structured
|
|
|
6
6
|
|
|
7
7
|
## Install
|
|
8
8
|
|
|
9
|
-
Most people install the `presmium` package, which brings this command with the renderers and the official plugins:
|
|
9
|
+
Most people install the `presmium` package, which brings this command with Studio, the renderers and the official plugins:
|
|
10
10
|
|
|
11
11
|
```sh
|
|
12
12
|
pnpm add -g @lincyaw/presmium
|
|
@@ -28,7 +28,7 @@ pnpm add -D @lincyaw/cli @lincyaw/web @lincyaw/render-slides @lincyaw/render-not
|
|
|
28
28
|
| `presmium dev [deck]` | Dev servers that update on save (`--to`, `--out`, `--server-port`, `--allow`) |
|
|
29
29
|
| `presmium new [dir]` | A new lecture, workspace or plugin project (`--type`, `--title`, `--name`, `--no-git`); from `create-presmium`, which the `presmium` package brings |
|
|
30
30
|
| `presmium serve [dir]` | The workspace service, on this machine: the documents and their sites, compiled on demand (`--port`, `--host`, `--operator-dir`, `--preview-origin`) |
|
|
31
|
-
| `presmium studio [dir]` | The workbench (experimental),
|
|
31
|
+
| `presmium studio [dir]` | The workbench (experimental), included with Presmium (`--port`, `--host`); uses the running command's bundled version |
|
|
32
32
|
|
|
33
33
|
`[deck]` is a directory with `lecture.json` or an entry file, by default the current directory. Exit codes: 0 no errors, 1 error findings, 2 usage or internal error. `presmium --help` lists every option.
|
|
34
34
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lincyaw/cli",
|
|
3
|
-
"version": "1.0.0-rc.
|
|
3
|
+
"version": "1.0.0-rc.15",
|
|
4
4
|
"description": "The presmium command: build, dev, ir, check and serve for Presmium documents",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -36,10 +36,10 @@
|
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"jiti": "^2.7.0",
|
|
39
|
-
"@lincyaw/compiler": "1.0.0-rc.
|
|
40
|
-
"@lincyaw/
|
|
41
|
-
"@lincyaw/
|
|
42
|
-
"@lincyaw/server": "1.0.0-rc.
|
|
43
|
-
"@lincyaw/skills": "1.0.0-rc.
|
|
39
|
+
"@lincyaw/compiler": "1.0.0-rc.15",
|
|
40
|
+
"@lincyaw/kernel": "1.0.0-rc.15",
|
|
41
|
+
"@lincyaw/workspace": "1.0.0-rc.15",
|
|
42
|
+
"@lincyaw/server": "1.0.0-rc.15",
|
|
43
|
+
"@lincyaw/skills": "1.0.0-rc.15"
|
|
44
44
|
}
|
|
45
45
|
}
|
package/src/messages.ts
CHANGED
|
@@ -87,8 +87,7 @@ export const CLI_MESSAGES: Record<Locale, CliMessages> = {
|
|
|
87
87
|
--public-url <网址> 反向代理在前面时浏览器使用的地址:信任它的主机,预览与产物
|
|
88
88
|
的地址用它给出;带路径时代理原样转发该路径,服务的全部内容都在它下面
|
|
89
89
|
studio 启动 Presmium Studio(实验性):浏览器中的编辑应用与这个目录(工作区的
|
|
90
|
-
|
|
91
|
-
@lincyaw/studio(约 865 MB)
|
|
90
|
+
根目录或一份文稿)的工作区服务,只打印一个要打开的网址。随 Presmium 一起安装
|
|
92
91
|
--port <端口> Presmium Studio 的端口(默认为 4320,被占用时取空闲端口)
|
|
93
92
|
--host <地址> 改为监听本机在局域网中的这个地址,而不是 127.0.0.1,且没有
|
|
94
93
|
登录:任何能访问这个端口的人都以你的身份操作
|
|
@@ -116,7 +115,7 @@ export const CLI_MESSAGES: Record<Locale, CliMessages> = {
|
|
|
116
115
|
noFfmpeg: command => `presmium serve: 没有找到 FFmpeg,讲授视频只能由浏览器导出为 WebM,画质较低。安装后可导出清晰的 MP4:${command}`,
|
|
117
116
|
serveOpen: (address, port) => `presmium serve: 正在 ${address} 上监听,局域网中的设备可以访问,且没有登录:任何能访问端口 ${port} 的人都以你的身份使用这个工作区(编辑、运行代码、允许操作)。请只在可信的网络中使用;不加 --host 时只在本机监听。`,
|
|
118
117
|
newMissing: 'presmium new: 没有安装 create-presmium。它随 presmium 一起安装,请运行 pnpm add -g @lincyaw/presmium。',
|
|
119
|
-
studioMissing: 'presmium studio:
|
|
118
|
+
studioMissing: 'presmium studio: 没有安装 Presmium Studio。它随 Presmium 一起安装,请运行 pnpm add -g @lincyaw/presmium。',
|
|
120
119
|
noProblems: '没有问题',
|
|
121
120
|
counts: (errors, warnings, infos) => `${errors} 个错误,${warnings} 个警告,${infos} 条信息`,
|
|
122
121
|
severity: { error: '错误', warning: '警告', info: '信息' },
|
|
@@ -176,8 +175,8 @@ Commands:
|
|
|
176
175
|
host is trusted, and previews and outputs are linked under it; with a path, the
|
|
177
176
|
proxy forwards that path unchanged and everything the service serves is below it
|
|
178
177
|
studio Presmium Studio (experimental): the editing app in the browser and the workspace service
|
|
179
|
-
of the directory (the workspace root, or a deck); prints the one address to open.
|
|
180
|
-
|
|
178
|
+
of the directory (the workspace root, or a deck); prints the one address to open.
|
|
179
|
+
Included with Presmium
|
|
181
180
|
--port <n> Presmium Studio’s port (default: 4320, or a free one when that is in use)
|
|
182
181
|
--host <addr> listen on this address of the machine on the local network instead of
|
|
183
182
|
127.0.0.1, with no login: whoever reaches the port works as you
|
|
@@ -205,7 +204,7 @@ Exit Codes: 0 no errors, 1 error findings, 2 usage or internal error.`,
|
|
|
205
204
|
noFfmpeg: command => `presmium serve: FFmpeg was not found, so lecture videos export from the browser as WebM, at a lower quality. Install it for sharp MP4 videos: ${command}`,
|
|
206
205
|
serveOpen: (address, port) => `presmium serve: listening on ${address}, on the local network, with no login: anyone who reaches port ${port} uses this workspace as you (edits, runs code, approves). Use it on a network you trust; without --host it listens on this machine only.`,
|
|
207
206
|
newMissing: 'presmium new: create-presmium is not installed. It comes with the presmium package: run pnpm add -g @lincyaw/presmium.',
|
|
208
|
-
studioMissing: 'presmium studio: Presmium Studio is not installed
|
|
207
|
+
studioMissing: 'presmium studio: Presmium Studio is not installed. It comes with Presmium: run pnpm add -g @lincyaw/presmium.',
|
|
209
208
|
noProblems: 'no problems',
|
|
210
209
|
counts: (errors, warnings, infos) => `${errors} errors, ${warnings} warnings, ${infos} infos`,
|
|
211
210
|
severity: { error: 'error', warning: 'warning', info: 'info' },
|