rdbumstead/Setup Salesforce CLI
Enterprise-grade Salesforce CLI setup with authentication, caching, and optional tooling
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Maintainedlast commit Jan 21, 2026
- License
- MIT
Pinned Snippet
uses: rdbumstead/setup-salesforce-action@2a05fc6d6434e05c6e57197732123e0a4030b5cb # v3.0.0tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| node_version | Node.js version | no | 20 |
| cli_version | Salesforce CLI version (latest or explicit version like 2.x.x) | no | latest |
| cli_version_for_cache | CLI version granularity for cache key (major, minor, or exact). Controls cache reuse vs freshness. | no | minor |
| strict | Fail pipeline on optional tool installation errors | no | false |
| dry_run | Dry-run mode: skip authentication and mutations, validate detection only | no | false |
| debug | Enable verbose debug output for troubleshooting | no | false |
| skip_auth | Skip authentication (CLI installation only) | no | false |
| auth_method | Authentication method: 'jwt', 'sfdx-url', or 'access-token' (required unless skip_auth is true) | no | jwt |
| jwt_key | SFDX JWT Private Key (required when auth_method is 'jwt') | no | — |
| client_id | Connected App Client ID (required for 'jwt' and 'access-token' auth methods) | no | — |
| username | Salesforce Username (required when auth_method is 'jwt') | no | — |
| sfdx_auth_url | SFDX Auth URL (required when auth_method is 'sfdx-url') | no | — |
| allow_access_token_auth | Explicitly allow direct access token authentication. Advanced use only. | no | true |
| access_token | Salesforce Access Token (required when auth_method is 'access-token') | no | — |
| alias | Org alias for authenticated org | no | TargetOrg |
| is_dev_hub | Set org as default Dev Hub | no | false |
| instance_url | Salesforce instance URL (required for 'jwt' and 'access-token' methods, e.g., https://login.salesforce.com) | no | https://login.salesforce.com |
| install_delta | Install sfdx-git-delta for delta deployments | no | false |
| install_scanner | Install Salesforce Code Analyzer for static analysis | no | false |
| install_prettier | Install Prettier with Salesforce plugins for code formatting | no | false |
| install_eslint | Install ESLint with Salesforce plugins for linting | no | false |
| install_lwc_jest | Install @salesforce/sfdx-lwc-jest for LWC unit testing | no | false |
| custom_sf_plugins | Comma-separated list of additional Salesforce CLI plugins to install (e.g., 'sfdx-hardis,@salesforce/plugin-packaging') | no | "" |
| source_dirs | Comma-separated source directories (e.g., 'force-app,packages/core') | no | force-app |
Outputs
| name | description |
|---|---|
| org_id | Authenticated Salesforce Org ID |
| org_edition | Salesforce Edition (Developer, Enterprise, Unlimited, etc.) |
| org_type | Organization type (Production, Sandbox, or Scratch) |
| username | Authenticated username |
| instance_url | Org instance URL |
| api_version | Salesforce API version for the org |
| auth_performed | Whether authentication was performed (true) or skipped (false) |
| sf_cli_version | Installed Salesforce CLI version |
| source_flags | Resolved source directory flags for SF CLI commands |
| used_default_node | Whether the default Node.js version was used (true) or explicit version specified (false) |
| used_default_cli_version | Whether the default CLI version was used (true) or explicit version specified (false) |
| used_default_api_version | Whether the API version was auto-detected (true) or explicitly provided (false) |
| cli_binary_path | Absolute path to the sf executable (for custom tooling integration) |
| validated_config | JSON summary of the final configuration (debug/audit use) |