百科.dev
全部条目AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
S

sfpowerkit

> DevOps
开源

一款 Salesforce DX 插件,具有多种功能,旨在改进开发和运营工作流程

386 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

一款 Salesforce DX 插件,具有多种功能,旨在改进开发和运营工作流程

:warning: Deprecation Notice

This project is currently being deprecated. Some of the existing functionality is already migrated to sfpowerscripts and rest of them will be available as standalone libraries / sfp-cli in a short span. Stay tuned!

Check issues for details and timeline. Thanks everyone for the support!

sfpowerkit

A Salesforce DX Plugin with multiple functionalities aimed at improving development and operational workflows

Installation

To install the stable version from the release branch, use the following command

$ sfdx plugins:install sfpowerkit

If you need to install automatically the plugin, via a CI process or Dockerfile, use the following line:

$ echo 'y' | sfdx plugins:install sfpowerkit

Beta versions are the latest versions that are in being reviewed/ undergoing testing etc and built from the master branch and can be downloaded using the following command

$ sfdx plugins:install sfpowerkit@beta

To review a pull request (for contributors/reviewers), the best option is to clone the repository, checkout to the particular branch and utilize the following command from the project directory

$ sfdx plugins:link

Commands

  • sfpowerkit
    • Installation
    • Commands
    • Source Related Functionalities
      • sfpowerkit:source:pmd
      • sfpowerkit:source:profile:retrieve
      • sfpowerkit:source:profile:reconcile
      • sfpowerkit:source:profile:merge
      • sfpowerkit:source:customlabel:create
      • sfpowerkit:source:customlabel:reconcile
      • sfpowerkit:source:customlabel:buildmanifest
      • sfpowerkit:source:apextest:list
      • sfpowerkit:source:apextestsuite:convert
      • sfpowerkit:source:picklist:generatepatch
      • sfpowerkit:project:diff
      • sfpowerkit:project:orgdiff
      • sfpowerkit:project:manifest:diff
      • sfpowerkit:project:manifest:merge
      • sfpowerkit:project:datamodel:diff [BETA]
    • Unlocked Package Related Functionalities
      • sfpowerkit:package:dependencies:install
      • sfpowerkit:package:dependencies:list
      • sfpowerkit:package:version:codecoverage
      • sfpowerkit:package:version:info
      • sfpowerkit:package:valid
      • sfpowerkit:package:applypatch
    • Org Related Functionalities
      • sfpowerkit:org:connectedapp:create
      • sfpowerkit:org:connectedapp:retrieve
      • sfpowerkit:org:duplicaterule:deactivate
      • sfpowerkit:org:duplicaterule:activate
      • sfpowerkit:org:matchingrule:deactivate
      • sfpowerkit:org:matchingrule:activate
      • sfpowerkit:org:trigger:deactivate
      • sfpowerkit:org:trigger:activate
      • sfpowerkit:org:healthcheck
      • sfpowerkit:org:cleartestresult
      • sfpowerkit:org:orgcoverage
      • sfpowerkit:org:profile:diff
      • sfpowerkit:org:sandbox:create
      • sfpowerkit:org:sandbox:info
      • sfpowerkit:org:sandbox:refresh
      • sfpowerkit:org:scratchorg:usage
      • sfpowerkit:org:scratchorg:delete
      • sfpowerkit:org:relaxiprange
      • sfpowerkit:auth:login
    • Dependency Functionalities
      • sfpowerkit:dependency:tree:package [BETA]
    • ScratchOrg Pooling Related Functionalities
      • sfpowerkit:pool:create
      • sfpowerkit:pool:fetch
      • sfpowerkit:pool:list
      • sfpowerkit:pool:delete

Source Related Functionalities

These commands manipulate the metadata configuration/code locally or during the packaging process.

sfpowerkit:source:pmd

This command is a wrapper around PMD ( downloads PMD for the first time) with some predefined defaults, such as ruleset, output format, output file. The command is to be run from the project directory

…

See code: src\commands\sfpowerkit\source\pmd.ts

sfpowerkit:source:profile:retrieve

Retrieve profiles from the salesforce org with all its associated permissions. Common use case for this command is to migrate profile changes from a integration environment to other higher environments [overcomes SFDX CLI Profile retrieve issue where it doesnt fetch the full profile unless the entire metadata is present in source], or retrieving profiles from production to lower environments for testing.

…

See code: src\commands\sfpowerkit\source\profile\retrieve.ts

sfpowerkit:source:profile:reconcile

This command is used in the lower environments such as ScratchOrgs , Development / System Testing Sandboxes, where a retrieved profile from production has to be cleaned up only for the metadata that is contained in the environment or base it only as per the metadata that is contained in the packaging directory.

Please read more about the command especially for ignoring user permissions here

…

See code: src\commands\sfpowerkit\source\profile\reconcile.ts

sfpowerkit:source:profile:merge

This command is used in the lower environments such as ScratchOrgs , Development / System Testing Sandboxes, inorder to apply the changes made in the environment to retrieved profile, so that it can be deployed to the higher environments

…

See code: src\commands\sfpowerkit\profile\merge.ts

sfpowerkit:source:customlabel:create

Custom Labels are org wide, hence when the metadata is pulled down from scratch org, the entire custom label metadata file is pulled down in a package repo. This results in often packaging failures, when developers forget to clean the customlabels only to contain what the package needs, as unlocked package does not support duplicate items.The custom labels has to be then cleaned up per package.

This command is a helper command to create customlabel with pacakage names prepended for easy reconcilation.

…

sfpowerkit:source:customlabel:reconcile

Custom Labels are org wide, hence when the metadata is pulled down from scratch org, the entire custom label metadata file is pulled down in a package repo. This results in often packaging failures, when developers forget to clean the customlabels only to contain what the package needs, as unlocked package does not support duplicate items.The custom labels has to be then cleaned up per package.

This command reconcile the updated custom labels to include only the labels that have the API name starting with package name (packagename_ ) or created using the custom label create command

…

sfpowerkit:source:customlabel:buildmanifest

This Command is used to build package.xml with all customlabels as members rather than wildcard *. sfdx force:source:convert creates a package.xml with customlabels wildcard, this command helps to update the package.xml with list of label names.

…

sfpowerkit:source:apextest:list

This command helps to get list of all apex text classes located in source path

…

sfpowerkit:source:apextestsuite:convert

Converts an apex test suite to its consituent apex classes as a single line separated by commas, so that it can be used along with metadata validate only deployment

USAGE
  $ sfdx sfpowerkit:source:apextestsuite:convert  -n  [--json] [--loglevel trace|debug|info|warn|error|fatal]

OPTIONS
  -n, --name=name                                 (required) the name of the apextestsuite (the file name minus the apex test suite)

  --json                                          format output as json
  --loglevel=(trace|debug|info|warn|error|fatal)  [default: warn] logging level for this command invocation

EXAMPLE
  $  sfdx sfpowerkit:source:apextestsuite:convert -n MyApexTestSuite
    "ABC2,ABC1Test"

sfpowerkit:source:picklist:generatepatch

Search picklist fields inside project and create a static resource file with picklist fields, used to solve the picklist upgrade issue in dx unlock package https://trailblazer.salesforce.com/issues_view?id=a1p3A0000003Uk2QAE

…

sfpowerkit:project:diff

Generate a delta 'changeset' between two diff commits so that the incremental changes can be deployed to the target org.To be used for an org based deployment when the size of the metadata is large that the project cannot not be deployed in a single attempt.

This command works with a source format based repository only. Utilize the command during a transition phase where an org is transformed to a modular architecture composing of multiple projects.

…

sfpowerkit:project:orgdiff

Compare source files of a project against the salesforce org and display differences. The command also add diff conflict markers in changed files to let the developer accept or reject changes manually using a git merge tool. The idea behind this command is used to track changes done on an unlocked package or a modular repo against the changes done in a higher environment. This command is not yet ready to work on a single repo against the whole metadata in the org

…

sfpowerkit:project:manifest:diff

Generate a diff between two manifest files. This command is used to useful to generate a report on what is the difference between two org's.

…

sfpowerkit:project:manifest:merge

Merge multiple package.xml into single collective package.xml

…

sfpowerkit:project:datamodel:diff [BETA]

Provides an audit history of the metadata change between two commit ID's for data model ( CustomFields, RecordTypes, BusinessProcess)

…

Unlocked Package Related Functionalities

Various helper commands in aiding with Salesforce DX Unlocked Package Development

sfpowerkit:package:dependencies:install

Install unlocked package dependencies of a package

…

_See code: [src\com

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

TypeScriptdeveloper-toolsdevopshacktoberfestmetadata

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类DevOps
定价开源

> 相关工具

D
Docker
容器化平台,标准化应用交付
G
GitHub Actions
GitHub 原生 CI/CD 工作流
N
Nginx
高性能 Web 服务器与反向代理