@nocobase/cli 2.2.0-beta.1 → 2.2.0-beta.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.
Files changed (37) hide show
  1. package/bin/early-locale.js +89 -0
  2. package/bin/node-version.js +35 -0
  3. package/bin/run.js +9 -0
  4. package/bin/windows-admin.js +60 -0
  5. package/dist/commands/app/destroy.js +4 -3
  6. package/dist/commands/app/shared.js +49 -3
  7. package/dist/commands/examples/prompts-stages.js +2 -2
  8. package/dist/commands/examples/prompts-test.js +2 -2
  9. package/dist/commands/init.js +5 -9
  10. package/dist/commands/license/activate.js +4 -1
  11. package/dist/commands/license/shared.js +24 -15
  12. package/dist/commands/self/check.js +1 -1
  13. package/dist/commands/self/update.js +2 -2
  14. package/dist/commands/skills/check.js +4 -5
  15. package/dist/commands/skills/install.js +18 -1
  16. package/dist/commands/skills/update.js +19 -4
  17. package/dist/commands/source/download.js +1 -2
  18. package/dist/lib/api-command-compat.js +51 -8
  19. package/dist/lib/prompt-web-ui.js +7 -11
  20. package/dist/lib/self-manager.js +3 -0
  21. package/dist/lib/skills-manager.js +116 -23
  22. package/dist/locale/en-US.json +10 -4
  23. package/dist/locale/zh-CN.json +10 -4
  24. package/package.json +7 -2
  25. package/assets/env-proxy/nginx/app.conf.tpl +0 -23
  26. package/assets/env-proxy/nginx/nocobase.conf.tpl +0 -5
  27. package/assets/env-proxy/nginx/snippets/dist-location.conf +0 -5
  28. package/assets/env-proxy/nginx/snippets/gzip.conf +0 -17
  29. package/assets/env-proxy/nginx/snippets/log-format-http.conf +0 -13
  30. package/assets/env-proxy/nginx/snippets/maps-http.conf +0 -14
  31. package/assets/env-proxy/nginx/snippets/mime-types.conf +0 -98
  32. package/assets/env-proxy/nginx/snippets/proxy-location.conf +0 -17
  33. package/assets/env-proxy/nginx/snippets/spa-location.conf +0 -6
  34. package/assets/env-proxy/nginx/snippets/uploads-location.conf +0 -21
  35. package/scripts/build.mjs +0 -34
  36. package/scripts/clean.mjs +0 -9
  37. package/tsconfig.json +0 -19
@@ -1,98 +0,0 @@
1
- types {
2
- text/html html htm shtml;
3
- text/css css;
4
- text/xml xml;
5
- image/gif gif;
6
- image/jpeg jpeg jpg;
7
- application/javascript js mjs;
8
- application/atom+xml atom;
9
- application/rss+xml rss;
10
-
11
- text/mathml mml;
12
- text/plain txt;
13
- text/vnd.sun.j2me.app-descriptor jad;
14
- text/vnd.wap.wml wml;
15
- text/x-component htc;
16
-
17
- image/avif avif;
18
- image/png png;
19
- image/svg+xml svg svgz;
20
- image/tiff tif tiff;
21
- image/vnd.wap.wbmp wbmp;
22
- image/webp webp;
23
- image/x-icon ico;
24
- image/x-jng jng;
25
- image/x-ms-bmp bmp;
26
-
27
- font/woff woff;
28
- font/woff2 woff2;
29
-
30
- application/java-archive jar war ear;
31
- application/json json;
32
- application/mac-binhex40 hqx;
33
- application/msword doc;
34
- application/pdf pdf;
35
- application/postscript ps eps ai;
36
- application/rtf rtf;
37
- application/vnd.apple.mpegurl m3u8;
38
- application/vnd.google-earth.kml+xml kml;
39
- application/vnd.google-earth.kmz kmz;
40
- application/vnd.ms-excel xls;
41
- application/vnd.ms-fontobject eot;
42
- application/vnd.ms-powerpoint ppt;
43
- application/vnd.oasis.opendocument.graphics odg;
44
- application/vnd.oasis.opendocument.presentation odp;
45
- application/vnd.oasis.opendocument.spreadsheet ods;
46
- application/vnd.oasis.opendocument.text odt;
47
- application/vnd.openxmlformats-officedocument.presentationml.presentation
48
- pptx;
49
- application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
50
- xlsx;
51
- application/vnd.openxmlformats-officedocument.wordprocessingml.document
52
- docx;
53
- application/vnd.wap.wmlc wmlc;
54
- application/wasm wasm;
55
- application/x-7z-compressed 7z;
56
- application/x-cocoa cco;
57
- application/x-java-archive-diff jardiff;
58
- application/x-java-jnlp-file jnlp;
59
- application/x-makeself run;
60
- application/x-perl pl pm;
61
- application/x-pilot prc pdb;
62
- application/x-rar-compressed rar;
63
- application/x-redhat-package-manager rpm;
64
- application/x-sea sea;
65
- application/x-shockwave-flash swf;
66
- application/x-stuffit sit;
67
- application/x-tcl tcl tk;
68
- application/x-x509-ca-cert der pem crt;
69
- application/x-xpinstall xpi;
70
- application/xhtml+xml xhtml;
71
- application/xspf+xml xspf;
72
- application/zip zip;
73
-
74
- application/octet-stream bin exe dll;
75
- application/octet-stream deb;
76
- application/octet-stream dmg;
77
- application/octet-stream iso img;
78
- application/octet-stream msi msp msm;
79
-
80
- audio/midi mid midi kar;
81
- audio/mpeg mp3;
82
- audio/ogg ogg;
83
- audio/x-m4a m4a;
84
- audio/x-realaudio ra;
85
-
86
- video/3gpp 3gpp 3gp;
87
- video/mp2t ts;
88
- video/mp4 mp4;
89
- video/mpeg mpeg mpg;
90
- video/quicktime mov;
91
- video/webm webm;
92
- video/x-flv flv;
93
- video/x-m4v m4v;
94
- video/x-mng mng;
95
- video/x-ms-asf asx asf;
96
- video/x-ms-wmv wmv;
97
- video/x-msvideo avi;
98
- }
@@ -1,17 +0,0 @@
1
- proxy_http_version 1.1;
2
-
3
- proxy_set_header Upgrade $http_upgrade;
4
- proxy_set_header Connection $connection_upgrade;
5
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
6
- proxy_set_header X-Forwarded-Proto $upstream_x_forwarded_proto;
7
- proxy_set_header Host $final_host;
8
- proxy_set_header Referer $http_referer;
9
- proxy_set_header User-Agent $http_user_agent;
10
-
11
- add_header Cache-Control "no-cache, no-store" always;
12
- proxy_cache_bypass $http_upgrade;
13
-
14
- proxy_connect_timeout 600;
15
- proxy_send_timeout 600;
16
- proxy_read_timeout 600;
17
- send_timeout 600;
@@ -1,6 +0,0 @@
1
- add_header Cache-Control "no-store, no-cache, must-revalidate" always;
2
- add_header X-Robots-Tag "noindex, nofollow" always;
3
-
4
- if_modified_since off;
5
- expires off;
6
- etag off;
@@ -1,21 +0,0 @@
1
- add_header Cache-Control "public" always;
2
- add_header X-Content-Type-Options "nosniff" always;
3
-
4
- access_log off;
5
- autoindex off;
6
-
7
- # Force potentially renderable uploaded files to download.
8
- location ~* \.(?:htm|html|svg|svgz|xhtml)$ {
9
- add_header Cache-Control "public" always;
10
- add_header X-Content-Type-Options "nosniff" always;
11
- add_header Content-Disposition "attachment" always;
12
- }
13
-
14
- # Let Markdown files render as plain Markdown text.
15
- location ~* \.md$ {
16
- default_type text/markdown;
17
-
18
- add_header Cache-Control "public" always;
19
- add_header X-Content-Type-Options "nosniff" always;
20
- add_header Content-Disposition "inline" always;
21
- }
package/scripts/build.mjs DELETED
@@ -1,34 +0,0 @@
1
- import { copyFileSync, mkdirSync, readdirSync, rmSync } from 'node:fs';
2
- import { createRequire } from 'node:module';
3
- import path from 'node:path';
4
- import { spawnSync } from 'node:child_process';
5
- import { fileURLToPath } from 'node:url';
6
-
7
- const require = createRequire(import.meta.url);
8
- const scriptsDir = path.dirname(fileURLToPath(import.meta.url));
9
- const packageRoot = path.resolve(scriptsDir, '..');
10
- const distDir = path.join(packageRoot, 'dist');
11
- const srcLocaleDir = path.join(packageRoot, 'src', 'locale');
12
- const distLocaleDir = path.join(distDir, 'locale');
13
- const tscBin = require.resolve('typescript/bin/tsc');
14
-
15
- rmSync(distDir, { recursive: true, force: true });
16
-
17
- const compile = spawnSync(process.execPath, [tscBin, '-p', path.join(packageRoot, 'tsconfig.json')], {
18
- cwd: packageRoot,
19
- stdio: 'inherit',
20
- });
21
-
22
- if (compile.status !== 0) {
23
- process.exit(compile.status ?? 1);
24
- }
25
-
26
- mkdirSync(distLocaleDir, { recursive: true });
27
-
28
- for (const entry of readdirSync(srcLocaleDir, { withFileTypes: true })) {
29
- if (!entry.isFile() || !entry.name.endsWith('.json')) {
30
- continue;
31
- }
32
-
33
- copyFileSync(path.join(srcLocaleDir, entry.name), path.join(distLocaleDir, entry.name));
34
- }
package/scripts/clean.mjs DELETED
@@ -1,9 +0,0 @@
1
- import { rmSync } from 'node:fs';
2
- import path from 'node:path';
3
- import { fileURLToPath } from 'node:url';
4
-
5
- const scriptsDir = path.dirname(fileURLToPath(import.meta.url));
6
- const packageRoot = path.resolve(scriptsDir, '..');
7
- const distDir = path.join(packageRoot, 'dist');
8
-
9
- rmSync(distDir, { recursive: true, force: true });
package/tsconfig.json DELETED
@@ -1,19 +0,0 @@
1
- {
2
- "compilerOptions": {
3
- "target": "ES2022",
4
- "module": "NodeNext",
5
- "moduleResolution": "NodeNext",
6
- "rewriteRelativeImportExtensions": true,
7
- "rootDir": "src",
8
- "outDir": "dist",
9
- "declaration": false,
10
- "resolveJsonModule": true,
11
- "esModuleInterop": true,
12
- "allowSyntheticDefaultImports": true,
13
- "types": ["node"],
14
- "skipLibCheck": true,
15
- "strict": false
16
- },
17
- "include": ["src/**/*.ts"],
18
- "exclude": ["src/**/__tests__/**"]
19
- }