Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

sfdx-cli

Package Overview
Dependencies
Maintainers
2
Versions
481
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sfdx-cli

Salesforce CLI

  • 7.209.6
  • latest
  • latest-rc
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
30K
decreased by-26.93%
Maintainers
2
Weekly downloads
 
Created
Source

Salesforce CLI

Warning
The sfdx CLI entered maintenance mode on July 12th, 2023. Use sf instead at salesforce/cli.

Check out this blog post for information and context about this change.
See the Move from sfdx (v7) to sf (v2) section of the Salesforce CLI Setup Guide for details on how to make the switch.


This is was the latest sfdx CLI application, based on the oclif CLI engine. By default it comes installed with various plugins.

Releases

We publish the latest CLI on Thursdays. At the same time we also publish the latest-rc release candidate CLI. The release candidates contain changes that will likely be in the final official version for the next release. To Install the latest-rc version, run npm install sfdx-cli@latest-rc. We suggest having your CI/CD pipeline use the latest-rc in addition to the latest release tags.

Run sfdx version to display the version of Salesforce CLI installed on your computer. Run sfdx plugins --core to display the versions of the installed plug-ins.

Run sfdx update to update the CLI to the latest available version.

Installation

You can install this by either using an OS-specific installer available here, by directly installing it with npm or yarn (see the instructions below).

Installing with npm or yarn

To get started, you'll need to install node v12 or greater, though we recommend using the latest v14 (LTS) for the best experience. While this can be done using an installer from nodejs.com or via an OS-specific package manager, we recommend using nvm to easily manage multiple node versions.

If using nvm, be sure that you've selected the appropriate version with something like nvm use v14.x.y, where x and y are specific to the version that you installed. If you want to use this version by default run nvm alias default node -- otherwise, when you restart your shell nvm will revert to whatever version configured prior to installing the latest.

npm

npm is installed automatically with Node.js. Install the CLI using npm as follows:

> npm install --global sfdx-cli

yarn

yarn is another popular Node.js package manager that can be used to install the CLI, but it needs to be installed separately from Node.js if you choose to use it.

Note that by default yarn will attempt to install the binary in a location that may conflict with the location used by the installers, so you may additionally want to run the following command to avoid collision should you want to maintain two separate installations: yarn config set prefix ~/.yarn (macOS and Linux). Then, use the following:

> yarn global add sfdx-cli

Docker Images

We provide versioned images on dockerhub. They come in 2 flavors

  1. slim is just the CLI installed using the installer for linux and openjdk11
  2. full includes other utilities and a full node/npm installation

Interactive Example

# choose a tag to pull and run
docker pull salesforce/salesforcedx:latest-rc-slim
docker run -it salesforce/salesforcedx:latest-rc-slim

# then run any sfdx command you like
sfdx version

# when done, type exit to leave the container
exit

Remote Execution Example

# using the ID of a running container, execute some command like "sfdx version"
docker exec -it 8b1e2696a243 bin/bash sfdx version



Development

If you would like to contribute, please see also the internal developer documentation.

FAQs

Package last updated on 12 Jul 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc