Skip to content
No description, website, or topics provided.
Branch: master
Clone or download
Pull request Compare This branch is 2 commits ahead, 16 commits behind forcedotcom:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

SFDX Simple App

Important: Salesforce DX is available as a Beta. Salesforce DX isn’t generally available unless or until Salesforce announces its general availability in documentation or in press releases or public statements. All commands, parameters, and other features are subject to change or deprecation at any time, with or without notice. Don't implement functionality developed with these commands or tools.

The Salesforce Developer Experience (SFDX) starts with source code living in your version control system.

Set Up the Salesforce DX Project

Our first goal is to set up a developer project which we'll use to modify our application. It starts by cloning the repository. Use the command ...

git clone

… or ...

git clone

… to clone the repository. Then, open the directory.

cd sfdx-simple


Authorize to your Developer Hub (Dev Hub) org.

sfdx force:auth:web:login -d -a "Hub Org"

If you already have an authorized Dev Hub, set it as the default:

sfdx force:config:set defaultdevhubusername=<username|alias>

Create a scratch org.

sfdx force:org:create -s -f config/project-scratch-def.json

If you want to use an existing scratch org, set it as the default:

sfdx force:config:set defaultausername=<username|alias>

Push your source.

sfdx force:source:push

Run your tests.

sfdx force:apex:test:run
sfdx force:apex:test:report -i <id>

Open the scratch org.

sfdx force:org:open --path one/


For details on using sfdx-simple, please review the Salesforce DX Developer Guide.

Description of Files and Directories

  • sfdx-project.json: Required by Salesforce DX. Configures your project. Use this file to specify the parameters that affect your Salesforce development project.
  • config/project-scratch-def.json: Sample file that shows how to define the shape of a scratch org. You reference this file when you create your scratch org with the force:org:create command.
  • force-app: Directory that contains the source for the sample app and tests.
  • .project: Required by the Eclipse IDE. Describes the Eclipse project.
  • .gitignore: Optional Git file. Specifies intentionally untracked files that you want Git (or in this case GitHub) to ignore.


Please log issues related to this repository here.

You can’t perform that action at this time.