@cloud-cli/env 1.3.4 → 1.4.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/index.d.ts +17 -0
- package/dist/index.js +18 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -34,5 +34,22 @@ declare const _default: {
|
|
|
34
34
|
show: typeof show;
|
|
35
35
|
apps: typeof apps;
|
|
36
36
|
list: typeof list;
|
|
37
|
+
help: () => {
|
|
38
|
+
description: string;
|
|
39
|
+
commands: {
|
|
40
|
+
'env get [name]': string;
|
|
41
|
+
'env set [name] --app <app> --key <key> --value <value>': string;
|
|
42
|
+
'env remove [name] --app <app> --key <key>': string;
|
|
43
|
+
'env show [name]': string;
|
|
44
|
+
'env list': string;
|
|
45
|
+
'env apps': string;
|
|
46
|
+
};
|
|
47
|
+
options: {
|
|
48
|
+
name: string;
|
|
49
|
+
app: string;
|
|
50
|
+
key: string;
|
|
51
|
+
value: string;
|
|
52
|
+
};
|
|
53
|
+
};
|
|
37
54
|
};
|
|
38
55
|
export default _default;
|
package/dist/index.js
CHANGED
|
@@ -62,9 +62,8 @@ function getVar(options) {
|
|
|
62
62
|
}
|
|
63
63
|
return get(computeId(app, key));
|
|
64
64
|
}
|
|
65
|
-
const invalidRe = /[^a-z09-]/gi;
|
|
66
65
|
function computeId(app, key) {
|
|
67
|
-
return `${app}.${key}
|
|
66
|
+
return `${app}.${key}`;
|
|
68
67
|
}
|
|
69
68
|
export default {
|
|
70
69
|
get: getVar,
|
|
@@ -73,4 +72,21 @@ export default {
|
|
|
73
72
|
show,
|
|
74
73
|
apps,
|
|
75
74
|
list,
|
|
75
|
+
help: () => ({
|
|
76
|
+
description: 'Manage environment variables',
|
|
77
|
+
commands: {
|
|
78
|
+
'env get [name]': "Get a value for an app's environment variable",
|
|
79
|
+
'env set [name] --app <app> --key <key> --value <value>': 'Set an env var for an app',
|
|
80
|
+
'env remove [name] --app <app> --key <key>': 'Remove an env var for an app',
|
|
81
|
+
'env show [name]': 'Show all env vars for an app',
|
|
82
|
+
'env list': 'List all apps with their env vars',
|
|
83
|
+
'env apps': 'List all defined apps',
|
|
84
|
+
},
|
|
85
|
+
options: {
|
|
86
|
+
name: 'App name',
|
|
87
|
+
app: 'Application name',
|
|
88
|
+
key: 'Environment variable key',
|
|
89
|
+
value: 'Environment variable value',
|
|
90
|
+
},
|
|
91
|
+
}),
|
|
76
92
|
};
|