@eik/cli 3.0.2 → 3.1.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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ # [3.1.0](https://github.com/eik-lib/cli/compare/v3.0.2...v3.1.0) (2024-08-15)
2
+
3
+
4
+ ### Features
5
+
6
+ * add support for image namespace publishing and aliasing ([a1a7e4c](https://github.com/eik-lib/cli/commit/a1a7e4c676cc45d30c63f4e522771298947dc47d))
7
+
1
8
  ## [3.0.2](https://github.com/eik-lib/cli/compare/v3.0.1...v3.0.2) (2024-08-14)
2
9
 
3
10
 
@@ -19,7 +19,7 @@ import Cleanup from './tasks/cleanup.js';
19
19
  * @property {string} token
20
20
  * @property {boolean} [dryRun=false]
21
21
  * @property {string} server
22
- * @property {"package" | "map" | "npm"} [type="package"]
22
+ * @property {"package" | "map" | "npm" | "image"} [type="package"]
23
23
  * @property {string} name
24
24
  * @property {string} [version="1.0.0"]
25
25
  * @property {string[]} [map]
@@ -11,6 +11,10 @@ function colorType(type) {
11
11
  return chalk.white.bgYellow.bold(' PACKAGE ');
12
12
  }
13
13
 
14
+ if (type === 'img') {
15
+ return chalk.white.bgYellow.bold(' IMAGE ');
16
+ }
17
+
14
18
  return chalk.white.bgBlue.bold(' IMPORT MAP ');
15
19
  }
16
20
 
@@ -16,6 +16,10 @@ function colorType(type) {
16
16
  return chalk.white.bgYellow.bold(' PACKAGE ');
17
17
  }
18
18
 
19
+ if (type === 'img') {
20
+ return chalk.white.bgYellow.bold(' IMAGE ');
21
+ }
22
+
19
23
  return chalk.white.bgBlue.bold(' IMPORT MAP ');
20
24
  }
21
25
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eik/cli",
3
- "version": "3.0.2",
3
+ "version": "3.1.0",
4
4
  "description": "CLI tool for publishing assets to an Eik server",
5
5
  "main": "./classes/index.js",
6
6
  "types": "./types/classes/index.d.ts",
@@ -28,7 +28,7 @@ export default class Alias {
28
28
  log: abslog.ValidLogger;
29
29
  server: string;
30
30
  token: string;
31
- type: any;
31
+ type: string;
32
32
  name: string;
33
33
  alias: string;
34
34
  version: string;
@@ -5,7 +5,7 @@
5
5
  * @property {string} token
6
6
  * @property {boolean} [dryRun=false]
7
7
  * @property {string} server
8
- * @property {"package" | "map" | "npm"} [type="package"]
8
+ * @property {"package" | "map" | "npm" | "image"} [type="package"]
9
9
  * @property {string} name
10
10
  * @property {string} [version="1.0.0"]
11
11
  * @property {string[]} [map]
@@ -57,7 +57,7 @@ export type PublishOptions = {
57
57
  token: string;
58
58
  dryRun?: boolean;
59
59
  server: string;
60
- type?: "package" | "map" | "npm";
60
+ type?: "package" | "map" | "npm" | "image";
61
61
  name: string;
62
62
  version?: string;
63
63
  map?: string[];
@@ -1,6 +1,6 @@
1
1
  import logger from './logger.js';
2
2
  export const getDefaults: typeof helpers.getDefaults;
3
- import typeSlug from './type-slug.js';
3
+ export const typeSlug: typeof helpers.typeSlug;
4
4
  import typeTitle from './type-title.js';
5
5
  import { helpers } from '@eik/common';
6
- export { logger, typeSlug, typeTitle };
6
+ export { logger, typeTitle };
package/utils/index.js CHANGED
@@ -1,8 +1,7 @@
1
1
  import { helpers } from '@eik/common';
2
2
  import logger from './logger.js';
3
- import typeSlug from './type-slug.js';
4
3
  import typeTitle from './type-title.js';
5
4
 
6
- const { getDefaults } = helpers;
5
+ const { getDefaults, typeSlug } = helpers;
7
6
 
8
7
  export { logger, getDefaults, typeSlug, typeTitle };
@@ -1,2 +0,0 @@
1
- declare function _default(type: any): any;
2
- export default _default;
@@ -1,4 +0,0 @@
1
- export default (type) => {
2
- if (type === 'package') return 'pkg';
3
- return type;
4
- };