@wocker/core 1.0.12 → 1.0.13

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.
@@ -4,7 +4,7 @@ exports.Command = void 0;
4
4
  require("reflect-metadata");
5
5
  const env_1 = require("../env");
6
6
  const Command = (command) => {
7
- return (target, key, descriptor) => {
7
+ return (_target, _key, descriptor) => {
8
8
  Reflect.defineMetadata(env_1.COMMAND_METADATA, command, descriptor.value);
9
9
  };
10
10
  };
@@ -2,10 +2,11 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Completion = void 0;
4
4
  require("reflect-metadata");
5
+ const env_1 = require("../env");
5
6
  const Completion = (name, command) => {
6
- return (target, propertyKey, descriptor) => {
7
- Reflect.defineMetadata("completion", [
8
- ...Reflect.getMetadata("completion", descriptor.value) || [],
7
+ return (_target, _propertyKey, descriptor) => {
8
+ Reflect.defineMetadata(env_1.COMPLETION_METADATA, [
9
+ ...Reflect.getMetadata(env_1.COMPLETION_METADATA, descriptor.value) || [],
9
10
  {
10
11
  name,
11
12
  command
@@ -1,3 +1,4 @@
1
+ import { PickProperties } from "../types";
1
2
  type TextOption = {
2
3
  type: "string" | "number" | "int";
3
4
  message?: string;
@@ -20,6 +21,7 @@ type SelectOption = {
20
21
  default?: string;
21
22
  };
22
23
  type AnyOption = TextOption | ConfirmOption | SelectOption;
24
+ export type PresetProperties = PickProperties<Preset>;
23
25
  export declare abstract class Preset {
24
26
  id: string;
25
27
  name: string;
@@ -31,9 +33,10 @@ export declare abstract class Preset {
31
33
  envOptions?: {
32
34
  [name: string]: AnyOption;
33
35
  };
36
+ path: string;
34
37
  volumes?: string[];
35
38
  volumeOptions?: string[];
36
- protected constructor(data: any);
39
+ protected constructor(data: PresetProperties);
37
40
  abstract save(): Promise<void>;
38
41
  }
39
42
  export {};
@@ -5,6 +5,7 @@ class Preset {
5
5
  constructor(data) {
6
6
  this.id = data.id;
7
7
  this.name = data.name;
8
+ this.path = data.path;
8
9
  this.version = data.version;
9
10
  this.dockerfile = data.dockerfile;
10
11
  this.buildArgsOptions = data.buildArgsOptions;
@@ -0,0 +1,5 @@
1
+ export type Volume = {
2
+ source: string;
3
+ destination: string;
4
+ options?: string;
5
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +1,4 @@
1
1
  export * from "./AppConfig";
2
2
  export * from "./EnvConfig";
3
3
  export * from "./PickProperties";
4
+ export * from "./Volume";
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./AppConfig"), exports);
18
18
  __exportStar(require("./EnvConfig"), exports);
19
19
  __exportStar(require("./PickProperties"), exports);
20
+ __exportStar(require("./Volume"), exports);
@@ -1,6 +1,2 @@
1
- export type Volume = {
2
- source: string;
3
- destination: string;
4
- options?: string;
5
- };
1
+ import { Volume } from "../types";
6
2
  export declare const volumeFormat: (volume: Volume) => string;
@@ -1,2 +1,2 @@
1
- import { Volume } from "./volumeFormat";
1
+ import { Volume } from "../types";
2
2
  export declare const volumeParse: (volume: string) => Volume;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wocker/core",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "author": "Kris Papercut <krispcut@gmail.com>",
5
5
  "description": "Core of wocker",
6
6
  "license": "MIT",
@@ -21,8 +21,8 @@
21
21
  "prepare": "npm run build",
22
22
  "build": "tsc --project tsconfig.build.json",
23
23
  "watch": "tsc -w --project tsconfig.build.json",
24
- "watch:test": "jest --colors --watchAll --coverage",
25
- "test": "jest --colors"
24
+ "test": "jest --colors",
25
+ "test-watch": "jest --colors --watchAll --coverage"
26
26
  },
27
27
  "dependencies": {
28
28
  "@kearisp/cli": "^2.0.4",