Monday, August 30, 2021

Mass delete unused flow and process builder versions in Salesforce

Many people wonder how to remove inactive versions flow and process builder.

I also had such a problem as the deployment went all over the branch and the versions accumulatedvery quickly especially on the integration environment.

Hope this helps you.

The URL is the address of your org.

Version restriction made to not touch the old versions.

You can upgrade the query as you like. 

New version for removing flaw from the sandbox using an array.
Added a feature: do not delete the last N versions from the active version.
link 

Execute Anonymous Window:

Thursday, August 26, 2021

Example of a Release and Git strategy

Release Strategy

The release scheme is designed taking into account the specifics of the project and the amount of development.

Main features:

-          source of truth git;

-          Interaction with other vendors via git;

-          maximum transparency of changes;

-          minimum labor costs for deployment;

-          deep automation is possible;

Monday, August 23, 2021

How to find deployed Components in an Org with Deployment ID?

You can use the Rest Explorer in Workbench (https://workbench.developerforce.com/restExplorer.php)

to make a call to retrieve the components included in the deployment. 

When in the Rest Explorer use a Get with a path of 

"/services/data/v49.0/metadata/deployRequest/<DEPLOYMENT_ID>?includeDetails=true"

(replace <DEPLOYMENT_ID> with the id you see in the Deployment Status e.g. Name:0Af1E00009PLDQ)

Monday, August 16, 2021

How to deploy Custom Labels translation

 

  1. Find file force-app/main/default/translations/<language_code>.translation-meta.xml
  2. If you don't have this file create it.
  3. You can find the language code here (ISO Language Code Table):  https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_categorynodelocalization.htm
  4. Use: 
    sfdx force:source:retrieve -p 
    "force-app/main/default/translations/
    <language_code>.translation-meta.xml"  -u   <Alias>
  5. You will get a lot of extra data - choose only what you need
  6. Done  

Friday, August 13, 2021

How to install and update Managed Package CLI

Check which packages are needed and get their ID

sfdx force:package:installed:list -u <Alias>

You will get a list of packages

Pay attention to the Package Version ID

You will need this ID in the next steps

To install, use the command
 

sfdx force:package:install -p <Package Version ID> -u <Alias>

Installing/updating a package may take a long time 

Saturday, August 7, 2021

DevOps PRO conference (May 2021)

The recordings of the DevOps PRO conference (May 2021) were posted.
There are many presentations in English.
Presentation by me (Russian language):

 


 

Friday, August 6, 2021

Basic commands Git

git commit:

git commit -m "<JIRA ticket> <Alias org> SF pull"

git commit a short version of the HASH:   

git log --pretty=format:"%h - %an, %ar : %s"

changing a commit:

Basic commands SFDX

 Run local tests:

sfdx force:apex:test:run -l RunLocalTests -u <alias> -r human

Display org info:

sfdx force:org:display -u <alias>

Password generation: 

Wednesday, August 4, 2021

Recommended Apps

Meld (Meld is a visual diff and merge tool targeted at developers) - link


Workbench (multifunctional solutions for working with environments) - link

Perm-comparator (Compare Salesforce.com Users, Profiles, and Permission Sets) - link


Multi-highlight (for chrome) - link

Grammarly (for chrome) - link

Salesforce inspector (for chrome) - link

 

Write in the comments if something else should be added

SF Materials - if you are a beginner in SF DevOps

Books

Mastering Salesforce DevOps -  link

The DevOps Handbook - link

Pro Git (free) - link


Video

Introduction: The State of Salesforce DevOps - link

Discover Salesforce, DevOps and Copado CI/CD automations - link

Azure DevOps with Salesforce - link


Trailhead SF

If you need to connect to the sandbox SFDX

 You can always view all possible connection methods in sfdx sfdx auth --help