Skip to content

Instantly share code, notes, and snippets.

View xixiaofinland's full-sized avatar

Xi Xiao xixiaofinland

View GitHub Profile
# Proudly supplied by Salesforce Way Site: https://salesforceway.com
# This cheatsheet contains the most often used sf(v2) commands to get a jumpstart.
# Hint. It is highly recommended to use `sf search` to search for commands, examples, parameters.
# More commands can be found in the official sites:
# https://developer.salesforce.com/docs/atlas.en-us.244.0.sfdx_cli_reference.meta/sfdx_cli_reference/cli_reference_unified.htm
# The old "sfdx" cheatsheet is stored below:
# https://gist.github.com/XiXiaoFinland/e22aad45caf67df33aeafae085810570
@xixiaofinland
xixiaofinland / save.json
Created April 9, 2019 07:29
save current file in vsc for salesforce development
{
"version": "2.0.0",
"tasks": [
{
"label": "ssave",
"type": "shell",
"command": "sfdx force:source:deploy -p ${file}",
"group": {
"kind": "build",
"isDefault": true
@xixiaofinland
xixiaofinland / package-create.sh
Created April 8, 2019 08:18
Salesforce unlocked package scripts
#!/bin/bash
# create package
sfdx force:package:create --name ccm_integration --description "unlocked pacakge1" --packagetype Unlocked --path force-app --nonamespace --targetdevhubusername DevHub
@xixiaofinland
xixiaofinland / setjdk.fish
Created October 2, 2018 09:13 — forked from tobias/setjdk.fish
Manage multiple java versions on the mac from the fish shell
function setjdk
if test -n "$JAVA_HOME"
removeFromPath "$JAVA_HOME/bin"
end
set -gx JAVA_HOME (/usr/libexec/java_home -v $argv[1])
set -gx PATH $JAVA_HOME/bin $PATH
end
function removeFromPath
set -l idx 0
@xixiaofinland
xixiaofinland / sfdx-cheatsheet.sh
Last active March 28, 2024 18:54
Salesforce SFDX Cheat Sheet
# Proudly supplied by Salesforce Way Site: https://salesforceway.com
# This cheatsheet contains the most often used SFDX commands for beginners to get a jumpstart.
# Hint. it is highly recommended to use `-h` to check the usage of any SFDX commands and corresponding parameters.
# For instance, use `sfdx force:auth:web:login -h` to checke what `-d` `-a` parameters do
# List down all supported dx commands:
sfdx force:doc:commands:list
# Check current DebHub and Scratch Org status
sfdx force:org:list