Skip to content

Commit d6337f7

Browse files
authored
Merge pull request #977 from salesforcecli/sh/refresh-sandbox
test: change to no-auto-activate flag
2 parents 39914ac + 86a60d2 commit d6337f7

File tree

3 files changed

+11
-8
lines changed

3 files changed

+11
-8
lines changed

command-snapshot.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,10 +187,10 @@
187187
"flagChars": ["f", "i", "n", "o", "w"],
188188
"flags": [
189189
"async",
190-
"auto-activate",
191190
"definition-file",
192191
"json",
193192
"name",
193+
"no-auto-activate",
194194
"no-prompt",
195195
"poll-interval",
196196
"target-org",

messages/refresh.sandbox.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,13 @@ You're not allowed to change the sandbox name when you refresh it with this comm
2222

2323
<%= config.bin %> <%= command.id %> --definition-file devSbx3-config.json --target-org prodOrg
2424

25-
# flags.auto-activate.summary
25+
# flags.no-auto-activate.summary
2626

27-
Activates the sandbox after a successful refresh.
27+
Disable auto-activation of the sandbox after a successful refresh.
28+
29+
# flags.no-auto-activate.description
30+
31+
By default, a sandbox auto-activates after a refresh. Use this flag to control sandbox activation manually.
2832

2933
# flags.targetOrg.summary
3034

src/commands/org/refresh/sandbox.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,9 @@ export default class RefreshSandbox extends SandboxCommandBase<SandboxProcessObj
4747
public static examples = messages.getMessages('examples');
4848

4949
public static flags = {
50-
'auto-activate': Flags.boolean({
51-
summary: messages.getMessage('flags.auto-activate.summary'),
52-
default: true,
53-
allowNo: true,
50+
'no-auto-activate': Flags.boolean({
51+
summary: messages.getMessage('flags.no-auto-activate.summary'),
52+
description: messages.getMessage('flags.no-auto-activate.description'),
5453
}),
5554
wait: Flags.duration({
5655
char: 'w',
@@ -214,7 +213,7 @@ export default class RefreshSandbox extends SandboxCommandBase<SandboxProcessObj
214213
// assign overrides
215214
sandboxInfo = Object.assign(sandboxInfo, defFileContent, {
216215
SandboxName: sbxName,
217-
AutoActivate: this.flags['auto-activate'],
216+
AutoActivate: !this.flags['no-auto-activate'],
218217
});
219218

220219
return sandboxInfo;

0 commit comments

Comments
 (0)