This repo contains the source for the Einstein Analytics Start Pack template of the dashboards developed by Yuji Yamamoto.
The structure of this repo and scripts can also be used as a template for Einstein Analytics Template development.
Before trying the steps detailed here, please clone and see the README for https://github.com/ttse-sfdc/sfdc-ea-sfdx-scripts
- Clone this repo: https://github.com/ttse-sfdc/ea-starter-pack.git
- Run
python3 ./scripts/initOrg.py -t Einstein_Analytics_Starter_Pack -s -p ../ea-starter-pack/force-app/main/default
from the cloned scripts project, to create a new Scratch Org with assets from repo. (Scratch Orgs are defaulted to expire in 1 day, override with argumentpython3 ./scripts/initOrg.py -t Einstein_Analytics_Starter_Pack -s -p ../ea-starter-pack/force-app/main/default -d 7
) - Do your development in the scratch org or VS Code.
- Edit dashboards in the org and pull source to local (see step 4i below)
- Edit template metadata in VS Code and push source to scratch org and update (see step 4ii below)
- Use the commands
SFDX: Push Source to Org
(VS Code) orsfdx force:source:push
(Salesforce CLI) to push changes from local into the Scratch Org. For example changes to template metadata (i.e. template-info.json)SFDX: Pull Source from Org
(VS Code) orsfdx force:source:pull
(Salesforce CLI) to pull changes down from Scratch Org to local. For example, dashboard edits.
- Run
./scripts/updateTemplate.sh
from the cloned scripts project, to update template with latest changes - Sync code with git
- Use
sfdx force:auth:web:login --setalias [ALIAS]
to add your dev org used for managing the package for this template (First time only) (i.e.sfdx force:auth:web:login --setalias myNonScratchOrg
) - Use the commands
SFDX: Deploy Source to Org
(VS Code) orsfdx force:source:deploy -u [ALIAS] -p force-app/main/default/waveTemplates/[TEMPLATE NAME]
(Salesforce CLI) to deploy the latest changes to Dev org for packaging (i.e.sfdx force:source:deploy -u myNonScratchOrg -p force-app/main/default/waveTemplates/Einstein_Analytics_Started_Pack
) - Log into Dev org and create/update package with template assets