Created
January 17, 2018 16:41
-
-
Save mshanemc/0407d184e818d3e106b6b4decf035a4b to your computer and use it in GitHub Desktop.
working with an existing org in sfdx/vscode
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
//add this to your ~/.bash_profile | |
alias cdp="mkdir src;sfdx force:source:convert -d src;sfdx force:mdapi:deploy -w 5 -d src" | |
//then, when you want to deploy something to your default alias, | |
cdp | |
//The alias is setup so that you can add other flags on the end, like | |
cdp -u cg2 (deploy somewhere else) | |
cdp -c (just check that it would, but don't really deploy...useful for validation | |
//Sometimes I get confused between force-app/main/default/classes/myClass.cls (that I should be editing) and /src/classes/myClass.cls (which always gets overwritten) | |
//So I often run the alias as | |
rm -rf src; cdp; rm -rf src |
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
// let's get the all code down from a real org | |
//install from https://github.com/mshanemc/sfdx-msm-plugins | |
first, auth your org and give it a handy alias, and -s makes it the default for the current folder | |
sfdx force:auth:web:login -a cg1 -s | |
sfdx msm:mdapi:pull -u cg1 -c | |
// -c is for code. It'll pull apex, VF, components, static resources, then unzip them, and convert to sfdx format | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment