@travetto/pack 2.2.2 → 2.2.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.
package/bin/cli-pack.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { BaseOptions,
|
|
1
|
+
import { BaseOptions, BasePackCommand } from './pack-base';
|
|
2
2
|
import { Pack, AllConfig } from './operation/pack';
|
|
3
3
|
|
|
4
|
-
export class
|
|
4
|
+
export class PackCommand extends BasePackCommand<BaseOptions, AllConfig> {
|
|
5
5
|
operation = Pack;
|
|
6
6
|
|
|
7
7
|
getOptions(): BaseOptions {
|
package/bin/cli-pack_assemble.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { OptionConfig } from '@travetto/cli/src/
|
|
1
|
+
import { OptionConfig } from '@travetto/cli/src/command';
|
|
2
2
|
|
|
3
|
-
import { BaseOptions,
|
|
3
|
+
import { BaseOptions, BasePackCommand } from './pack-base';
|
|
4
4
|
import { Assemble, AssembleConfig } from './operation/assemble';
|
|
5
5
|
|
|
6
6
|
type Options = BaseOptions & {
|
|
@@ -8,7 +8,7 @@ type Options = BaseOptions & {
|
|
|
8
8
|
readonly: OptionConfig<boolean>;
|
|
9
9
|
};
|
|
10
10
|
|
|
11
|
-
export class
|
|
11
|
+
export class PackAssembleCommand extends BasePackCommand<Options, AssembleConfig> {
|
|
12
12
|
operation = Assemble;
|
|
13
13
|
|
|
14
14
|
getOptions(): Options {
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import * as fs from 'fs/promises';
|
|
2
2
|
|
|
3
3
|
import { FsUtil, PathUtil } from '@travetto/boot';
|
|
4
|
-
import {
|
|
4
|
+
import { CliCommand, OptionConfig, ListOptionConfig } from '@travetto/cli/src/command';
|
|
5
5
|
|
|
6
6
|
type Options = {
|
|
7
7
|
app: OptionConfig<string>;
|
|
8
8
|
image: OptionConfig<string>;
|
|
9
9
|
port: OptionConfig<number>;
|
|
10
|
-
add:
|
|
10
|
+
add: ListOptionConfig<string>;
|
|
11
11
|
output: OptionConfig<string>;
|
|
12
12
|
};
|
|
13
13
|
|
|
14
|
-
export class
|
|
14
|
+
export class PackDockerExportCommand extends CliCommand<Options> {
|
|
15
15
|
|
|
16
16
|
name = 'pack:docker-export';
|
|
17
17
|
|
package/bin/cli-pack_docker.ts
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { OptionConfig } from '@travetto/cli/src/
|
|
1
|
+
import { OptionConfig, ListOptionConfig } from '@travetto/cli/src/command';
|
|
2
2
|
|
|
3
|
-
import { BaseOptions,
|
|
3
|
+
import { BaseOptions, BasePackCommand } from './pack-base';
|
|
4
4
|
import { Docker, DockerConfig } from './operation/docker';
|
|
5
5
|
|
|
6
6
|
type Options = BaseOptions & {
|
|
7
7
|
image: OptionConfig<string>;
|
|
8
8
|
name: OptionConfig<string>;
|
|
9
|
-
tag:
|
|
10
|
-
port:
|
|
9
|
+
tag: ListOptionConfig<string>;
|
|
10
|
+
port: ListOptionConfig<string>;
|
|
11
11
|
push: OptionConfig<boolean>;
|
|
12
12
|
registry: OptionConfig<string>;
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
-
export class
|
|
15
|
+
export class PackDockerCommand extends BasePackCommand<Options, DockerConfig> {
|
|
16
16
|
operation = Docker;
|
|
17
17
|
|
|
18
18
|
getOptions(): Options {
|
package/bin/cli-pack_zip.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { OptionConfig } from '@travetto/cli/src/
|
|
1
|
+
import { OptionConfig } from '@travetto/cli/src/command';
|
|
2
2
|
|
|
3
|
-
import { BaseOptions,
|
|
3
|
+
import { BaseOptions, BasePackCommand } from './pack-base';
|
|
4
4
|
import { Zip, ZipConfig } from './operation/zip';
|
|
5
5
|
|
|
6
6
|
type Options = BaseOptions & {
|
|
7
7
|
output: OptionConfig<string>;
|
|
8
8
|
};
|
|
9
9
|
|
|
10
|
-
export class
|
|
10
|
+
export class PackZipCommand extends BasePackCommand<Options, ZipConfig> {
|
|
11
11
|
operation = Zip;
|
|
12
12
|
|
|
13
13
|
getOptions(): Options {
|
package/bin/pack-base.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as os from 'os';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { CliCommand, OptionConfig } from '@travetto/cli/src/command';
|
|
4
4
|
import { color } from '@travetto/cli/src/color';
|
|
5
5
|
import { PathUtil, Package, FsUtil } from '@travetto/boot';
|
|
6
6
|
|
|
@@ -19,7 +19,7 @@ export type BaseOptions = {
|
|
|
19
19
|
/**
|
|
20
20
|
* Supports packing a project into a directory, ready for archiving
|
|
21
21
|
*/
|
|
22
|
-
export abstract class
|
|
22
|
+
export abstract class BasePackCommand<V extends BaseOptions, C extends CommonConfig> extends CliCommand<V> {
|
|
23
23
|
|
|
24
24
|
/**
|
|
25
25
|
* Package stage name
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/pack",
|
|
3
3
|
"displayName": "Pack",
|
|
4
|
-
"version": "2.2.
|
|
4
|
+
"version": "2.2.3",
|
|
5
5
|
"description": "Code packing utilities",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"travetto",
|
|
@@ -25,12 +25,12 @@
|
|
|
25
25
|
"directory": "module/pack"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@travetto/base": "^2.2.
|
|
28
|
+
"@travetto/base": "^2.2.3",
|
|
29
29
|
"@types/picomatch": "^2.3.0",
|
|
30
30
|
"picomatch": "^2.3.1"
|
|
31
31
|
},
|
|
32
32
|
"optionalPeerDependencies": {
|
|
33
|
-
"@travetto/cli": "^2.2.
|
|
33
|
+
"@travetto/cli": "^2.2.3"
|
|
34
34
|
},
|
|
35
35
|
"docDependencies": {
|
|
36
36
|
"@travetto/rest": true
|