eas-cli 12.5.1 → 12.5.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.
Files changed (45) hide show
  1. package/README.md +66 -62
  2. package/build/build/build.js +4 -4
  3. package/build/commandUtils/flags.d.ts +10 -0
  4. package/build/commandUtils/flags.js +15 -8
  5. package/build/commands/env/create.d.ts +4 -1
  6. package/build/commands/env/create.js +133 -74
  7. package/build/commands/env/delete.d.ts +2 -2
  8. package/build/commands/env/delete.js +37 -26
  9. package/build/commands/env/exec.js +2 -1
  10. package/build/commands/env/get.d.ts +2 -2
  11. package/build/commands/env/get.js +44 -28
  12. package/build/commands/env/link.d.ts +4 -2
  13. package/build/commands/env/link.js +53 -14
  14. package/build/commands/env/list.d.ts +2 -2
  15. package/build/commands/env/list.js +59 -42
  16. package/build/commands/env/pull.js +1 -1
  17. package/build/commands/env/unlink.d.ts +3 -2
  18. package/build/commands/env/unlink.js +48 -21
  19. package/build/commands/env/update.d.ts +6 -2
  20. package/build/commands/env/update.js +134 -70
  21. package/build/commands/update/index.js +0 -1
  22. package/build/commands/worker/deploy.js +31 -11
  23. package/build/graphql/generated.d.ts +103 -15
  24. package/build/graphql/mutations/EnvironmentVariableMutation.d.ts +13 -22
  25. package/build/graphql/mutations/EnvironmentVariableMutation.js +18 -2
  26. package/build/graphql/queries/EnvironmentVariablesQuery.d.ts +24 -11
  27. package/build/graphql/queries/EnvironmentVariablesQuery.js +40 -17
  28. package/build/graphql/types/EnvironmentVariable.js +3 -1
  29. package/build/graphql/types/EnvironmentVariableWithSecret.d.ts +1 -0
  30. package/build/graphql/types/EnvironmentVariableWithSecret.js +18 -0
  31. package/build/prompts.d.ts +1 -0
  32. package/build/prompts.js +2 -0
  33. package/build/update/republish.js +1 -0
  34. package/build/utils/prompts.d.ts +16 -3
  35. package/build/utils/prompts.js +52 -8
  36. package/build/utils/variableUtils.d.ts +6 -0
  37. package/build/utils/variableUtils.js +62 -0
  38. package/build/worker/assets.d.ts +6 -1
  39. package/build/worker/assets.js +1 -2
  40. package/build/worker/upload.d.ts +1 -0
  41. package/build/worker/upload.js +25 -1
  42. package/oclif.manifest.json +98 -41
  43. package/package.json +3 -3
  44. package/build/utils/formatVariable.d.ts +0 -2
  45. package/build/utils/formatVariable.js +0 -16
@@ -6,50 +6,89 @@ const core_1 = require("@oclif/core");
6
6
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
7
7
  const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
8
8
  const flags_1 = require("../../commandUtils/flags");
9
+ const generated_1 = require("../../graphql/generated");
9
10
  const EnvironmentVariableMutation_1 = require("../../graphql/mutations/EnvironmentVariableMutation");
10
11
  const EnvironmentVariablesQuery_1 = require("../../graphql/queries/EnvironmentVariablesQuery");
11
12
  const log_1 = tslib_1.__importDefault(require("../../log"));
12
13
  const projectUtils_1 = require("../../project/projectUtils");
13
14
  const prompts_1 = require("../../prompts");
14
15
  const prompts_2 = require("../../utils/prompts");
16
+ const variableUtils_1 = require("../../utils/variableUtils");
15
17
  class EnvironmentVariableLink extends EasCommand_1.default {
16
18
  async runAsync() {
17
- let { flags: { name, 'non-interactive': nonInteractive, environment }, } = await this.parse(_a);
19
+ let { flags: { 'variable-name': name, 'variable-environment': currentEnvironment, 'non-interactive': nonInteractive, environment: environments, }, } = await this.parse(_a);
18
20
  const { privateProjectConfig: { projectId }, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
19
21
  nonInteractive,
20
22
  });
21
23
  const projectDisplayName = await (0, projectUtils_1.getDisplayNameForProjectIdAsync)(graphqlClient, projectId);
22
24
  const variables = await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedAsync(graphqlClient, {
23
25
  appId: projectId,
26
+ environment: currentEnvironment,
27
+ filterNames: name ? [name] : undefined,
24
28
  });
25
- if (!name) {
26
- name = await (0, prompts_1.selectAsync)('Select shared variable', variables.map(variable => ({
27
- title: variable.name,
28
- value: variable.name,
29
+ let selectedVariable = variables[0];
30
+ if (variables.length > 1) {
31
+ selectedVariable = await (0, prompts_1.selectAsync)('Select shared variable', variables.map(variable => ({
32
+ title: (0, variableUtils_1.formatVariableName)(variable),
33
+ value: variable,
29
34
  })));
30
35
  }
31
- const selectedVariable = variables.find(variable => variable.name === name);
32
36
  if (!selectedVariable) {
33
37
  throw new Error(`Shared variable ${name} doesn't exist`);
34
38
  }
35
- if (!environment) {
36
- environment = await (0, prompts_2.promptVariableEnvironmentAsync)(nonInteractive);
39
+ let explicitSelect = false;
40
+ if (!nonInteractive && !environments) {
41
+ const selectedEnvironments = (selectedVariable.linkedEnvironments ?? []).length > 0
42
+ ? selectedVariable.linkedEnvironments
43
+ : selectedVariable.environments;
44
+ environments = await (0, prompts_2.promptVariableEnvironmentAsync)({
45
+ nonInteractive,
46
+ multiple: true,
47
+ selectedEnvironments: selectedEnvironments ?? [],
48
+ });
49
+ explicitSelect = true;
37
50
  }
38
- const linkedVariable = await EnvironmentVariableMutation_1.EnvironmentVariableMutation.linkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
39
- if (!linkedVariable) {
40
- throw new Error(`Could not link variable with name ${selectedVariable.name} to project with id ${projectId}`);
51
+ if (!environments) {
52
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.linkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId);
53
+ log_1.default.withTick(`Linked variable ${chalk_1.default.bold(selectedVariable.name)} to project ${chalk_1.default.bold(projectDisplayName)} in ${selectedVariable.environments?.join(', ').toLocaleLowerCase()}.`);
54
+ return;
55
+ }
56
+ for (const environment of Object.values(generated_1.EnvironmentVariableEnvironment)) {
57
+ try {
58
+ if (selectedVariable.linkedEnvironments?.includes(environment) ===
59
+ environments.includes(environment)) {
60
+ if (!explicitSelect && environments.includes(environment)) {
61
+ log_1.default.withTick(`Variable ${chalk_1.default.bold(selectedVariable.name)} is already linked to ${environment.toLocaleLowerCase()}.`);
62
+ }
63
+ continue;
64
+ }
65
+ if (environments.includes(environment)) {
66
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.linkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
67
+ log_1.default.withTick(`Linked variable ${chalk_1.default.bold(selectedVariable.name)} to project ${chalk_1.default.bold(projectDisplayName)} in ${environment.toLocaleLowerCase()}.`);
68
+ }
69
+ else if (explicitSelect) {
70
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.unlinkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
71
+ log_1.default.withTick(`Unlinked variable ${chalk_1.default.bold(selectedVariable.name)} from project ${chalk_1.default.bold(projectDisplayName)} in ${environment.toLocaleLowerCase()}.`);
72
+ }
73
+ }
74
+ catch (err) {
75
+ log_1.default.warn(err.message);
76
+ }
41
77
  }
42
- log_1.default.withTick(`Linked variable ${chalk_1.default.bold(linkedVariable.name)} to project ${chalk_1.default.bold(projectDisplayName)}.`);
43
78
  }
44
79
  }
45
80
  _a = EnvironmentVariableLink;
46
81
  EnvironmentVariableLink.description = 'link a shared environment variable to the current project';
47
82
  EnvironmentVariableLink.hidden = true;
48
83
  EnvironmentVariableLink.flags = {
49
- name: core_1.Flags.string({
84
+ 'variable-name': core_1.Flags.string({
50
85
  description: 'Name of the variable',
51
86
  }),
52
- ...flags_1.EASEnvironmentFlag,
87
+ 'variable-environment': core_1.Flags.enum({
88
+ ...flags_1.EasEnvironmentFlagParameters,
89
+ description: 'Current environment of the variable to link',
90
+ }),
91
+ ...flags_1.EASMultiEnvironmentFlag,
53
92
  ...flags_1.EASNonInteractiveFlag,
54
93
  };
55
94
  EnvironmentVariableLink.contextDefinition = {
@@ -8,11 +8,11 @@ export default class EnvironmentValueList extends EasCommand {
8
8
  privateProjectConfig: import("../../commandUtils/context/PrivateProjectConfigContextField").PrivateProjectConfigContextField;
9
9
  };
10
10
  static flags: {
11
- environment: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableEnvironment | undefined>;
11
+ environment: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableEnvironment[] | undefined>;
12
12
  scope: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableScope>;
13
13
  format: import("@oclif/core/lib/interfaces").OptionFlag<string>;
14
14
  'include-sensitive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
15
+ 'include-file-content': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
15
16
  };
16
17
  runAsync(): Promise<void>;
17
- private getVariablesForScopeAsync;
18
18
  }
@@ -9,58 +9,71 @@ const flags_1 = require("../../commandUtils/flags");
9
9
  const generated_1 = require("../../graphql/generated");
10
10
  const EnvironmentVariablesQuery_1 = require("../../graphql/queries/EnvironmentVariablesQuery");
11
11
  const log_1 = tslib_1.__importDefault(require("../../log"));
12
- const formatVariable_1 = require("../../utils/formatVariable");
13
12
  const prompts_1 = require("../../utils/prompts");
13
+ const variableUtils_1 = require("../../utils/variableUtils");
14
+ async function getVariablesForScopeAsync(graphqlClient, { scope, includingSensitive, includeFileContent, environment, projectId, }) {
15
+ if (scope === generated_1.EnvironmentVariableScope.Project) {
16
+ if (includingSensitive) {
17
+ return await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.byAppIdWithSensitiveAsync(graphqlClient, {
18
+ appId: projectId,
19
+ environment,
20
+ includeFileContent,
21
+ });
22
+ }
23
+ return await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.byAppIdAsync(graphqlClient, {
24
+ appId: projectId,
25
+ environment,
26
+ includeFileContent,
27
+ });
28
+ }
29
+ return includingSensitive
30
+ ? await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedWithSensitiveAsync(graphqlClient, {
31
+ appId: projectId,
32
+ environment,
33
+ includeFileContent,
34
+ })
35
+ : await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedAsync(graphqlClient, {
36
+ appId: projectId,
37
+ environment,
38
+ includeFileContent,
39
+ });
40
+ }
14
41
  class EnvironmentValueList extends EasCommand_1.default {
15
42
  async runAsync() {
16
- let { flags: { environment, format, scope, 'include-sensitive': includeSensitive }, } = await this.parse(_a);
43
+ let { flags: { environment: environments, format, scope, 'include-sensitive': includeSensitive, 'include-file-content': includeFileContent, 'non-interactive': nonInteractive, }, } = await this.parse(_a);
17
44
  const { privateProjectConfig: { projectId }, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
18
45
  nonInteractive: true,
19
46
  });
20
- if (scope === generated_1.EnvironmentVariableScope.Project && !environment) {
21
- environment = await (0, prompts_1.promptVariableEnvironmentAsync)(false);
47
+ if (!environments) {
48
+ environments = await (0, prompts_1.promptVariableEnvironmentAsync)({ nonInteractive, multiple: true });
22
49
  }
23
- const variables = await this.getVariablesForScopeAsync(graphqlClient, {
24
- scope,
25
- includingSensitive: includeSensitive,
26
- environment,
27
- projectId,
28
- });
29
- if (format === 'short') {
30
- for (const variable of variables) {
31
- // TODO: Add Learn more link
32
- log_1.default.log(`${chalk_1.default.bold(variable.name)}=${variable.value ??
33
- "***** (This is a secret env variable that can only be accessed on EAS builder and can't be read in any UI. Learn more.)"}`);
50
+ await (0, variableUtils_1.performForEnvironmentsAsync)(environments, async (environment) => {
51
+ const variables = await getVariablesForScopeAsync(graphqlClient, {
52
+ scope,
53
+ includingSensitive: includeSensitive,
54
+ includeFileContent,
55
+ environment,
56
+ projectId,
57
+ });
58
+ log_1.default.addNewLineIfNone();
59
+ if (environment) {
60
+ log_1.default.log(chalk_1.default.bold(`Environment: ${environment}`));
34
61
  }
35
- }
36
- else {
37
- if (scope === generated_1.EnvironmentVariableScope.Shared) {
38
- log_1.default.log(chalk_1.default.bold('Shared variables for this account:'));
62
+ if (format === 'short') {
63
+ for (const variable of variables) {
64
+ log_1.default.log(`${chalk_1.default.bold(variable.name)}=${(0, variableUtils_1.formatVariableValue)(variable)}`);
65
+ }
39
66
  }
40
67
  else {
41
- log_1.default.log(chalk_1.default.bold(`Variables for this project for environment ${environment}:`));
68
+ if (scope === generated_1.EnvironmentVariableScope.Shared) {
69
+ log_1.default.log(chalk_1.default.bold('Shared variables for this account:'));
70
+ }
71
+ else {
72
+ log_1.default.log(chalk_1.default.bold(`Variables for this project:`));
73
+ }
74
+ log_1.default.log(variables.map(variable => (0, variableUtils_1.formatVariable)(variable)).join(`\n\n${chalk_1.default.dim('———')}\n\n`));
42
75
  }
43
- log_1.default.log(variables.map(variable => (0, formatVariable_1.formatVariable)(variable)).join(`\n\n${chalk_1.default.dim('———')}\n\n`));
44
- }
45
- }
46
- async getVariablesForScopeAsync(graphqlClient, { scope, includingSensitive, environment, projectId, }) {
47
- if (scope === generated_1.EnvironmentVariableScope.Project && environment) {
48
- if (includingSensitive) {
49
- return await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.byAppIdWithSensitiveAsync(graphqlClient, {
50
- appId: projectId,
51
- environment,
52
- });
53
- }
54
- return await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.byAppIdAsync(graphqlClient, {
55
- appId: projectId,
56
- environment,
57
- });
58
- }
59
- return includingSensitive
60
- ? await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedWithSensitiveAsync(graphqlClient, {
61
- appId: projectId,
62
- })
63
- : await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedAsync(graphqlClient, { appId: projectId });
76
+ });
64
77
  }
65
78
  }
66
79
  _a = EnvironmentValueList;
@@ -75,8 +88,12 @@ EnvironmentValueList.flags = {
75
88
  description: 'Display sensitive values in the output',
76
89
  default: false,
77
90
  }),
91
+ 'include-file-content': core_1.Flags.boolean({
92
+ description: 'Display files content in the output',
93
+ default: false,
94
+ }),
78
95
  ...flags_1.EASVariableFormatFlag,
79
96
  ...flags_1.EASVariableScopeFlag,
80
- ...flags_1.EASEnvironmentFlag,
97
+ ...flags_1.EASMultiEnvironmentFlag,
81
98
  };
82
99
  exports.default = EnvironmentValueList;
@@ -14,7 +14,7 @@ class EnvironmentVariablePull extends EasCommand_1.default {
14
14
  async runAsync() {
15
15
  let { flags: { environment, path: targetPath, 'non-interactive': nonInteractive }, } = await this.parse(_a);
16
16
  if (!environment) {
17
- environment = await (0, prompts_2.promptVariableEnvironmentAsync)(nonInteractive);
17
+ environment = await (0, prompts_2.promptVariableEnvironmentAsync)({ nonInteractive });
18
18
  }
19
19
  const { privateProjectConfig: { projectId }, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
20
20
  nonInteractive,
@@ -1,11 +1,12 @@
1
1
  import EasCommand from '../../commandUtils/EasCommand';
2
+ import { EnvironmentVariableEnvironment } from '../../graphql/generated';
2
3
  export default class EnvironmentVariableUnlink extends EasCommand {
3
4
  static description: string;
4
5
  static hidden: boolean;
5
6
  static flags: {
6
7
  'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
7
- environment: import("@oclif/core/lib/interfaces").OptionFlag<import("../../graphql/generated").EnvironmentVariableEnvironment | undefined>;
8
- name: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
8
+ environment: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableEnvironment[] | undefined>;
9
+ 'variable-name': import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
9
10
  };
10
11
  static contextDefinition: {
11
12
  loggedIn: import("../../commandUtils/context/LoggedInContextField").default;
@@ -13,49 +13,76 @@ const log_1 = tslib_1.__importDefault(require("../../log"));
13
13
  const projectUtils_1 = require("../../project/projectUtils");
14
14
  const prompts_1 = require("../../prompts");
15
15
  const prompts_2 = require("../../utils/prompts");
16
+ const variableUtils_1 = require("../../utils/variableUtils");
16
17
  class EnvironmentVariableUnlink extends EasCommand_1.default {
17
18
  async runAsync() {
18
- let { flags: { name, 'non-interactive': nonInteractive, environment }, } = await this.parse(_a);
19
+ let { flags: { 'variable-name': name, 'non-interactive': nonInteractive, environment: unlinkEnvironments, }, } = await this.parse(_a);
19
20
  const { privateProjectConfig: { projectId }, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
20
21
  nonInteractive,
21
22
  });
22
- if (!environment) {
23
- environment = await (0, prompts_2.promptVariableEnvironmentAsync)(nonInteractive);
24
- }
25
23
  const projectDisplayName = await (0, projectUtils_1.getDisplayNameForProjectIdAsync)(graphqlClient, projectId);
26
- const appVariables = await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.byAppIdAsync(graphqlClient, {
24
+ const variables = await EnvironmentVariablesQuery_1.EnvironmentVariablesQuery.sharedAsync(graphqlClient, {
27
25
  appId: projectId,
28
- environment,
26
+ filterNames: name ? [name] : undefined,
29
27
  });
30
- const linkedVariables = appVariables.filter(({ scope }) => scope === generated_1.EnvironmentVariableScope.Shared);
31
- if (linkedVariables.length === 0) {
32
- throw new Error(`There are no linked shared env variables for project ${projectDisplayName}`);
33
- }
34
- if (!name) {
35
- name = await (0, prompts_1.selectAsync)('Select shared variable to unlink', linkedVariables.map(variable => ({
36
- title: variable.name,
37
- value: variable.name,
28
+ let selectedVariable = variables[0];
29
+ if (variables.length > 1) {
30
+ if (nonInteractive) {
31
+ throw new Error("Multiple variables found, please select one using '--variable-name'");
32
+ }
33
+ selectedVariable = await (0, prompts_1.selectAsync)('Select shared variable', variables.map(variable => ({
34
+ title: (0, variableUtils_1.formatVariableName)(variable),
35
+ value: variable,
38
36
  })));
39
37
  }
40
- const selectedVariable = linkedVariables.find(variable => variable.name === name);
41
38
  if (!selectedVariable) {
42
39
  throw new Error(`Shared variable ${name} doesn't exist`);
43
40
  }
44
- const unlinkedVariable = await EnvironmentVariableMutation_1.EnvironmentVariableMutation.unlinkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
45
- if (!unlinkedVariable) {
46
- throw new Error(`Could not unlink variable with name ${selectedVariable.name} from project ${projectDisplayName}`);
41
+ let explicitSelect = false;
42
+ if (!nonInteractive && !unlinkEnvironments) {
43
+ const selectedEnvironments = (selectedVariable.linkedEnvironments ?? []).length > 0
44
+ ? selectedVariable.linkedEnvironments
45
+ : selectedVariable.environments;
46
+ const environments = await (0, prompts_2.promptVariableEnvironmentAsync)({
47
+ nonInteractive,
48
+ multiple: true,
49
+ selectedEnvironments: selectedEnvironments ?? [],
50
+ });
51
+ explicitSelect = true;
52
+ unlinkEnvironments = Object.values(generated_1.EnvironmentVariableEnvironment).filter(env => !environments.includes(env));
53
+ }
54
+ if (!unlinkEnvironments) {
55
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.unlinkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId);
56
+ log_1.default.withTick(`Unlinked variable ${chalk_1.default.bold(selectedVariable.name)} from project ${chalk_1.default.bold(projectDisplayName)} in ${selectedVariable.environments?.join(', ').toLocaleLowerCase()}.`);
57
+ return;
58
+ }
59
+ for (const environment of Object.values(generated_1.EnvironmentVariableEnvironment)) {
60
+ if (selectedVariable.linkedEnvironments?.includes(environment) !==
61
+ unlinkEnvironments.includes(environment)) {
62
+ if (!explicitSelect && unlinkEnvironments.includes(environment)) {
63
+ log_1.default.withTick(`Variable ${chalk_1.default.bold(selectedVariable.name)} is already unlinked from ${environment.toLocaleLowerCase()}.`);
64
+ }
65
+ continue;
66
+ }
67
+ if (unlinkEnvironments.includes(environment)) {
68
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.unlinkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
69
+ log_1.default.withTick(`Unlinked variable ${chalk_1.default.bold(selectedVariable.name)} from project ${chalk_1.default.bold(projectDisplayName)} in ${environment.toLocaleLowerCase()}.`);
70
+ }
71
+ else if (explicitSelect) {
72
+ await EnvironmentVariableMutation_1.EnvironmentVariableMutation.linkSharedEnvironmentVariableAsync(graphqlClient, selectedVariable.id, projectId, environment);
73
+ log_1.default.withTick(`Linked variable ${chalk_1.default.bold(selectedVariable.name)} to project ${chalk_1.default.bold(projectDisplayName)} in ${environment.toLocaleLowerCase()}.`);
74
+ }
47
75
  }
48
- log_1.default.withTick(`Unlinked variable ${chalk_1.default.bold(unlinkedVariable.name)} from the project ${chalk_1.default.bold(projectDisplayName)}.`);
49
76
  }
50
77
  }
51
78
  _a = EnvironmentVariableUnlink;
52
79
  EnvironmentVariableUnlink.description = 'unlink a shared environment variable to the current project';
53
80
  EnvironmentVariableUnlink.hidden = true;
54
81
  EnvironmentVariableUnlink.flags = {
55
- name: core_1.Flags.string({
82
+ 'variable-name': core_1.Flags.string({
56
83
  description: 'Name of the variable',
57
84
  }),
58
- ...flags_1.EASEnvironmentFlag,
85
+ ...flags_1.EASMultiEnvironmentFlag,
59
86
  ...flags_1.EASNonInteractiveFlag,
60
87
  };
61
88
  EnvironmentVariableUnlink.contextDefinition = {
@@ -1,15 +1,18 @@
1
1
  import EasCommand from '../../commandUtils/EasCommand';
2
- import { EnvironmentVariableScope, EnvironmentVariableVisibility } from '../../graphql/generated';
2
+ import { EnvironmentVariableEnvironment, EnvironmentVariableScope, EnvironmentVariableVisibility } from '../../graphql/generated';
3
3
  export default class EnvironmentVariableUpdate extends EasCommand {
4
4
  static description: string;
5
5
  static hidden: boolean;
6
6
  static flags: {
7
7
  'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
8
- environment: import("@oclif/core/lib/interfaces").OptionFlag<import("../../graphql/generated").EnvironmentVariableEnvironment | undefined>;
8
+ environment: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableEnvironment[] | undefined>;
9
9
  scope: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableScope>;
10
10
  visibility: import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableVisibility | undefined>;
11
+ 'variable-name': import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
12
+ 'variable-environment': import("@oclif/core/lib/interfaces").OptionFlag<EnvironmentVariableEnvironment | undefined>;
11
13
  name: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
12
14
  value: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
15
+ type: import("@oclif/core/lib/interfaces").OptionFlag<"string" | "file" | undefined>;
13
16
  };
14
17
  static contextDefinition: {
15
18
  loggedIn: import("../../commandUtils/context/LoggedInContextField").default;
@@ -18,4 +21,5 @@ export default class EnvironmentVariableUpdate extends EasCommand {
18
21
  };
19
22
  runAsync(): Promise<void>;
20
23
  private validateFlags;
24
+ private promptForMissingFlagsAsync;
21
25
  }