Skip to content
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

feat: add --target-org to deploy cancel #945

Merged
merged 5 commits into from
Mar 25, 2024
Merged

Conversation

WillieRuemmele
Copy link
Contributor

What does this PR do?

adds --target-org flag to deploy cancel

What issues does this PR fix or reference?

@W-14776888@

@mdonnalley
Copy link
Collaborator

QA

setup: checkout branch, yarn && yarn build && sf plugins link --no-install

🟢 Deploy and cancel without --target-org

❯ sf project deploy start --source-dir force-app --async && sf project deploy cancel --use-most-recent
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Deploying v60.0 metadata to [email protected] using the v60.0 REST API.
Deploy ID: 0AfDR00003Bk1If0AJ
Deploy has been queued.

Run "sf project deploy resume --job-id 0AfDR00003Bk1If0AJ" to resume watching the deploy.
Run "sf project deploy report --job-id 0AfDR00003Bk1If0AJ" to get the latest status.
Run "sf project deploy cancel --job-id 0AfDR00003Bk1If0AJ" to cancel the deploy.
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Successfully canceled 0AfDR00003Bk1If0AJ

🟢 Deploy and cancel with --target-org

❯ sf project deploy start --source-dir force-app --async && sf project deploy cancel --use-most-recent --target-org my-scratch-org
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Deploying v60.0 metadata to [email protected] using the v60.0 REST API.
Deploy ID: 0AfDR00003Bk1JP0AZ
Deploy has been queued.

Run "sf project deploy resume --job-id 0AfDR00003Bk1JP0AZ" to resume watching the deploy.
Run "sf project deploy report --job-id 0AfDR00003Bk1JP0AZ" to get the latest status.
Run "sf project deploy cancel --job-id 0AfDR00003Bk1JP0AZ" to cancel the deploy.
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Successfully canceled 0AfDR00003Bk1JP0AZ

🟢 Gracefully handles non-existent org

❯ sf project deploy start --source-dir force-app --async && sf project deploy cancel --use-most-recent --target-org DOES_NOT_EXIST
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Deploying v60.0 metadata to [email protected] using the v60.0 REST API.
Deploy ID: 0AfDR00003Bk1K90AJ
Deploy has been queued.

Run "sf project deploy resume --job-id 0AfDR00003Bk1K90AJ" to resume watching the deploy.
Run "sf project deploy report --job-id 0AfDR00003Bk1K90AJ" to get the latest status.
Run "sf project deploy cancel --job-id 0AfDR00003Bk1K90AJ" to cancel the deploy.
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Error (2): Parsing --target-org
	No authorization information found for DOES_NOT_EXIST.
See more help with --help

🟡 Gracefully handles incorrect org???

❯ sf project deploy start --source-dir force-app --ignore-conflicts --async && sf project deploy cancel --use-most-recent --target-org my-other-org
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Deploying v60.0 metadata to [email protected] using the v60.0 REST API.
Deploy ID: 0AfDR00003Bk1OT0AZ
Deploy has been queued.

Run "sf project deploy resume --job-id 0AfDR00003Bk1OT0AZ" to resume watching the deploy.
Run "sf project deploy report --job-id 0AfDR00003Bk1OT0AZ" to get the latest status.
Run "sf project deploy cancel --job-id 0AfDR00003Bk1OT0AZ" to cancel the deploy.
 ›   Warning: @salesforce/plugin-deploy-retrieve is a linked ESM module and cannot be auto-transpiled. Existing compiled source will
 ›   be used instead.
Successfully canceled 0AfDR00003Bk1OT0AZ

@WillieRuemmele WillieRuemmele merged commit 8fbf9e6 into main Mar 25, 2024
38 checks passed
@WillieRuemmele WillieRuemmele deleted the wr/cancelWithOrg branch March 25, 2024 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants