Visual Studio Code - SFDX
Tools and Resources
Setup
Install Visual Studio Code
Install Salesforce Extensions
Set Environment Variables (add all)
SFDX_DISABLE_DNS_CHECK=true
NODE_TLS_REJECT_UNAUTHORIZED=0
http_proxy=http://proxy.toronto.ca:8080
https_proxy=http://proxy.toronto.ca:8080
HTTP_PROXY=http://proxy.toronto.ca:8080
HTTPS_PROXY=http://proxy.toronto.ca:8080
Open Visual Studio Code
File > New Window
Open command pallet (PC: ctrl+shift+p / Mac: cmd+shift+p)
>SFDX: Create Project
Create Project > Standard >
This aligns to the local folder name
You should use a unique name e.g.
struat
and press <enter>For the city we typically use
city-of-toronto--struat.sandbox.lightning.force.com
as our sandbox environments. So I usestruat
Open Command pallet
>SFDX: Authorize an Org
Choose Environment (Sandbox)
Use the default or use the same name used for the folder e.g.
struat
and press <enter>
Browser will launch
test.salesforce.com
or the Environment selected above.Enter userName/Password for the environment that you want to use.
You may need to Authorize SF to use the CLI - choose “Approve”
You should return to VSCode and see a message that SF has been successfully authorized.
Verify Setup by right clicking:
manifest > package.xml
Choose
Retrieve Source in Manifest from Org
The resources defined in the package.xml should be downloaded.