-
Notifications
You must be signed in to change notification settings - Fork 679
fix(cli-test)!: remove default "--app deployed" global flag from commands #2624
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+29
−9
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
51b65cc
test(cli-test): remove --app global flag from create command tests
srtaalej 9c25b8e
chore: chagneset
zimeg 978731a
Update packages/cli-test/src/cli/cli-process.ts
srtaalej 8dda1e2
remove app defaults and update test
srtaalej 95b50b2
fix: lint formatting
srtaalej 593c88a
Update .changeset/silver-papers-lick.md
srtaalej c625cbe
Update .changeset/silver-papers-lick.md
srtaalej 16ed1ef
Update packages/cli-test/src/cli/cli-process.ts
srtaalej File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| --- | ||
| "@slack/cli-test": major | ||
| --- | ||
|
|
||
| fix: remove default "--app deployed" global flag from commands | ||
|
|
||
| Commands running for a specific app must now provide the "app" argument: | ||
|
|
||
| ```diff | ||
| await SlackCLI.app.delete({ | ||
| appPath: "my-app", | ||
| team: "T0123456789", | ||
| + app: "deployed", | ||
| }); | ||
| ``` | ||
|
|
||
| The options "local" or "deployed" or app ID all remain available to use. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -131,11 +131,9 @@ export class SlackCLIProcess { | |
| if (opts.team) { | ||
| cmd = cmd.concat(['--team', opts.team]); | ||
| } | ||
| // App instance; defaults to `deployed` | ||
| // App instance | ||
| if (opts.app) { | ||
| cmd = cmd.concat(['--app', opts.app]); | ||
| } else { | ||
| cmd = cmd.concat(['--app', 'deployed']); | ||
| } | ||
| // Ignore warnings via --force; defaults to true | ||
| if (opts.force || typeof opts.force === 'undefined') { | ||
|
|
@@ -149,9 +147,10 @@ export class SlackCLIProcess { | |
| cmd = cmd.concat(['--verbose']); | ||
| } | ||
| } else { | ||
| cmd = cmd.concat(['--skip-update', '--force', '--app', 'deployed']); | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🪓 praise: Nice! 🔮 note: I have hope to split "force" into more meaningful flags and perhaps we use an environment variable to skip updates in later changes. I'm hoping we avoid having defaults exposed for each command. |
||
| cmd = cmd.concat(['--skip-update', '--force']); | ||
| } | ||
| cmd = cmd.concat(this.command); | ||
|
|
||
| if (this.commandOptions) { | ||
| for (const [key, value] of Object.entries(this.commandOptions)) { | ||
| if (key && value) { | ||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧪 praise: Thanks for covering these cases!