@youcan/theme 1.2.0-beta.9 → 2.0.0
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/dist/cli/commands/theme/delete.d.ts +1 -0
- package/dist/cli/commands/theme/delete.js +1 -0
- package/dist/cli/commands/theme/dev.d.ts +1 -0
- package/dist/cli/commands/theme/dev.js +1 -0
- package/dist/cli/commands/theme/init.js +2 -2
- package/dist/cli/commands/theme/list.d.ts +1 -0
- package/dist/cli/commands/theme/list.js +1 -0
- package/dist/cli/commands/theme/pack.d.ts +1 -0
- package/dist/cli/commands/theme/pack.js +1 -0
- package/dist/cli/services/dev/worker.js +3 -1
- package/package.json +2 -2
|
@@ -2,6 +2,7 @@ import { Session, Http, Env, Tasks } from '@youcan/cli-kit';
|
|
|
2
2
|
import { ThemeCommand } from '../../../util/theme-command.js';
|
|
3
3
|
|
|
4
4
|
class Delete extends ThemeCommand {
|
|
5
|
+
static description = 'Select remote development themes to delete';
|
|
5
6
|
async run() {
|
|
6
7
|
await Session.authenticate(this);
|
|
7
8
|
const { dev: themes } = await Http.get(`${Env.apiHostname()}/themes`);
|
|
@@ -4,6 +4,7 @@ import { load } from '../../../util/theme-loader.js';
|
|
|
4
4
|
import ThemeWorker from '../../services/dev/worker.js';
|
|
5
5
|
|
|
6
6
|
class Dev extends ThemeCommand {
|
|
7
|
+
static description = 'Start a theme development server and preview your changes';
|
|
7
8
|
async run() {
|
|
8
9
|
const theme = await load();
|
|
9
10
|
await Session.authenticate(this);
|
|
@@ -5,7 +5,7 @@ import { THEME_FLAGS } from '../../../flags.js';
|
|
|
5
5
|
import { THEME_CONFIG_FILENAME } from '../../../constants.js';
|
|
6
6
|
|
|
7
7
|
class Init extends ThemeCommand {
|
|
8
|
-
static description = 'Clones a theme template
|
|
8
|
+
static description = 'Clones a theme template git repo';
|
|
9
9
|
static args = {
|
|
10
10
|
name: Args.string({
|
|
11
11
|
name: 'name',
|
|
@@ -20,7 +20,7 @@ class Init extends ThemeCommand {
|
|
|
20
20
|
char: 'u',
|
|
21
21
|
env: 'YC_FLAG_CLONE_URL',
|
|
22
22
|
description: 'The Git URL to clone from',
|
|
23
|
-
default: 'https://github.com/youcan-shop/
|
|
23
|
+
default: 'https://github.com/youcan-shop/dusk',
|
|
24
24
|
}),
|
|
25
25
|
};
|
|
26
26
|
async run() {
|
|
@@ -8,6 +8,7 @@ const formatter = Intl.NumberFormat('en', {
|
|
|
8
8
|
unitDisplay: 'narrow',
|
|
9
9
|
});
|
|
10
10
|
class List extends ThemeCommand {
|
|
11
|
+
static description = 'List remote development themes';
|
|
11
12
|
async run() {
|
|
12
13
|
await Session.authenticate(this);
|
|
13
14
|
const { dev: themes } = await Http.get(`${Env.apiHostname()}/themes`);
|
|
@@ -129,7 +129,9 @@ class ThemeWorker extends Worker.Abstract {
|
|
|
129
129
|
}, 100)();
|
|
130
130
|
}
|
|
131
131
|
catch (err) {
|
|
132
|
-
|
|
132
|
+
if (err instanceof Error) {
|
|
133
|
+
this.logger.write(`[error] - ${Path.join(type, name)}\n${err.message}`);
|
|
134
|
+
}
|
|
133
135
|
}
|
|
134
136
|
});
|
|
135
137
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@youcan/theme",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "2.0.0",
|
|
5
5
|
"description": "OCLIF plugin for building themes",
|
|
6
6
|
"author": "YouCan <contact@youcan.shop> (https://youcan.shop)",
|
|
7
7
|
"license": "MIT",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"@oclif/core": "^2.15.0",
|
|
19
19
|
"debounce": "^2.0.0",
|
|
20
20
|
"socket.io": "^4.7.2",
|
|
21
|
-
"@youcan/cli-kit": "
|
|
21
|
+
"@youcan/cli-kit": "2.0.0"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
24
24
|
"@oclif/plugin-legacy": "^1.3.0",
|