Add: Salesforce CI/CD reusable workflows (sf-validate, sf-deploy) - #6
Merged
Conversation
Authenticate to a Salesforce org from an SFDX auth URL held in a GitHub secret — no cloud dependency. Outputs org-id, username, instance-url; auth file cleaned up in an if: always() step. JSON parsed with node so the action works inside any container that ships the SF CLI. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Wrap sfdx-git-delta: delta package.xml between two refs with has-changes/component-count outputs, a component table in the step summary and components.md for downstream PR comments. Installs the plugin on the fly when missing (preinstalled in gforceinnovation/sf-ci). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Salesforce PR validation: delta package, check-only deploy with tests against the target org (validation.json quick-deploy handoff), Code Analyzer on changed files via the existing reusable workflow, optional scratch-org validation, sticky PR comment, sf-validate-<run> audit artifact. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Gated deploy bound to a caller GitHub Environment: GitHub Deployment record with the Salesforce deploy-request URL, quick deploy of the PR-validated request (merge commit -> PR -> validation artifact lookup) with delta and full-deploy fallbacks, JUnit test export and the sf-deploy-<env>-<run> audit artifact. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…Access) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ort drift Task 1 added findRelevantTests exports to @gforce/core but never re-ran `npm run bundle:all`, so the committed dist/index.js for these two actions predated that change and failed `npm run dist:verify`. No source changed; this is a mechanical ncc re-bundle to match already-merged core. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…eploy PR events validate the delta against the target org with auto-selected tests and save the deploy request id; push/dispatch events quick-deploy the validated request behind the caller's environment gate, with delta -> full fallbacks. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…workflow layer Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What
A complete reusable Salesforce CI/CD layer, callable from any repo in the org with ~15 lines of YAML per workflow:
sf-org-login(composite) — org auth from an SFDX auth-URL GitHub secret, zero cloud dependencies,if: always()cleanupsf-delta-package(composite) — sfdx-git-delta wrapper withhas-changes/component-countoutputs and a component table for PR commentssf-validate.yml(reusable) — delta check-only deploy with tests against the target org, Code Analyzer on changed files (nested call to the existing reusable workflow), optional scratch-org validation, sticky PR comment,sf-validate-<run>audit artifact carrying the quick-deploy handoff (validation.json)sf-deploy.yml(reusable) — deploy bound to a caller GitHub Environment (reviewer gates apply), GitHub Deployment record linking the Salesforce deploy request, quick deploy of the PR-validated request with delta → full fallbacks, JUnit export,sf-deploy-<env>-<run>audit artifactdocs/consuming-sf-cicd.mdquickstart,examples/sf-validate.yml+examples/sf-deploy.yml, README/CLAUDE.md entriesNotes
@main(they resolve against the caller's checkout) — same documented version-skew caveat assf-jwt-login→get-aws-secret. The refs resolve once this PR merges.gforceinnovation/sf-ciby default (container-imageinput).sf-jwt-login/get-aws-secretuntouched.Verification
npm run allgreen (format, lint, typecheck, bundle, test, dist:verify)actionlintclean across all workflowsv1.2.0is taggedAfter merge
Tag
v1.2.0—release.ymlpublishes the release and movesv1.🤖 Generated with Claude Code