npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@salesforce/change-case-management

v2.1.1

Published

Manage change case records in a release management system in Salesforce using something like [Agile Accelerator](https://appexchange.salesforce.com/appxListingDetail?listingId=a0N30000000ps3jEAA). This uses two record types on Case that to manage changes

Downloads

291

Readme

Salesforce Change Case Management

Manage change case records in a release management system in Salesforce using something like Agile Accelerator. This uses two record types on Case that to manage changes to tools and services during a release; Change Case and Change Case Template. It creates the change case, checks the release is approved, and closes the change case when the release is in the wild.

The typical flow would be:

  1. Build and test staged artifacts.
  2. Create a change case before doing a release. - sfchangecase create
  3. Check the release is approved. - sfchangecase check
  4. Release the artifacts to production.
  5. Close the change case that the release is deployed. - sfchangecase close

If there is a lot of time during stage 2 (not part of the same CD process), record the change case ID to be used in step 3 and 5.

Configuration

All options are configurable by environment variables and are prefixed with SF_CHANGE_CASE. All command parameters can use environment variable as defaults. They are snake cased with the prefix.

The most important environment variable is for authentication. Set SF_CHANGE_CASE_SFDX_AUTH_URL to the SFDX auth url to the org in which the change cases will be created.

All command configuration: | Environment Variable | Description | | ---------------------------- | ----------- | | SF_CHANGE_CASE_SFDX_AUTH_URL | The SFDX auth url to authenticate to a Salesforce org that the change cases belong to. | | SF_CHANGE_CASE_BYPASS | Skip the change case command. | | SF_CHANGE_CASE_DRYRUN | Run the command without making any DML to an org. Authentication is still required. |

Create command configuration: | Environment Variable | Description | | --------------------------------------------- | ----------- | | SF_CHANGE_CASE_CHANGE_RECORD_TYPE_ID | The case record type ID for a change case. This will be the different for different orgs. | | SF_CHANGE_CASE_CHANGE_TEMPLATE_RECORD_TYPE_ID | The case record type ID for a change case template. This will be the different for different orgs. | | SF_CHANGE_CASE_CONFIGURATION_ITEM | Full path from the configuration item, ex: Salesforce.SF_Off_Core.DeveloperTools.NPM. |

Installing

$ npm install -g @salesforce/change-case-management
$ sfchangecase COMMAND
running command...
$ sfchangecase (-v|--version|version)
@salesforce/change-case-management/1.4.0 linux-x64 node-v12.22.10
$ sfchangecase --help [COMMAND]
USAGE
  $ sfchangecase COMMAND
...

Commands

sfchangecase check [-i <id>] [-r <string> -l <url>] [--bypass] [--dryrun] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

check the status of a change case record

USAGE
  $ sfchangecase check [-i <id>] [-r <string> -l <url>] [--bypass] [--dryrun] [-u <string>] [--apiversion <string>]
  [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

OPTIONS
  -i, --changecaseid=changecaseid                                                   change case id
  -l, --location=location                                                           url of the source control location
  -r, --release=release                                                             schedule build of the new release

  -u, --targetusername=targetusername                                               username or alias for the target
                                                                                    org; overrides default target org

  --apiversion=apiversion                                                           override the api version used for
                                                                                    api requests made by this command

  --bypass                                                                          bypass the change case commands

  --dryrun                                                                          run the command without making any
                                                                                    API calls - all calls will be
                                                                                    'successful'

  --json                                                                            format output as json

  --loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)  [default: warn] logging level for
                                                                                    this command invocation

See code: src/commands/check.ts

sfchangecase close [-i <id>] [-r <string> -l <url>] [-s Implemented - per plan|Not Implemented|Rolled back - with no impact] [--bypass] [--dryrun] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

stops the implementation steps, and closes the change case record

USAGE
  $ sfchangecase close [-i <id>] [-r <string> -l <url>] [-s Implemented - per plan|Not Implemented|Rolled back - with no
  impact] [--bypass] [--dryrun] [-u <string>] [--apiversion <string>] [--json] [--loglevel
  trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

OPTIONS
  -i, --changecaseid=changecaseid                                                     change case id
  -l, --location=location                                                             url of the source control location
  -r, --release=release                                                               schedule build of the new release

  -s, --status=(Implemented - per plan|Not Implemented|Rolled back - with no impact)  [default: Implemented - per plan]
                                                                                      What the status of the
                                                                                      implementation steps should be set
                                                                                      to

  -u, --targetusername=targetusername                                                 username or alias for the target
                                                                                      org; overrides default target org

  --apiversion=apiversion                                                             override the api version used for
                                                                                      api requests made by this command

  --bypass                                                                            bypass the change case commands

  --dryrun                                                                            run the command without making any
                                                                                      API calls - all calls will be
                                                                                      'successful'

  --json                                                                              format output as json

  --loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)    [default: warn] logging level for
                                                                                      this command invocation

See code: src/commands/close.ts

sfchangecase create -i <id> -r <string> -c <string> [-l <url>] [--bypass] [--dryrun] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

create a change case record based on a template ID with one implementation step

USAGE
  $ sfchangecase create -i <id> -r <string> -c <string> [-l <url>] [--bypass] [--dryrun] [-u <string>] [--apiversion
  <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

OPTIONS
  -c, --configurationitem=configurationitem                                         (required) Full path from the
                                                                                    configuration item, ex:
                                                                                    Salesforce.SF_Off_Core.DeveloperTool
                                                                                    s.NPM

  -i, --templateid=templateid                                                       (required) change case template id

  -l, --location=location                                                           url of the source control location

  -r, --release=release                                                             (required) schedule build of the new
                                                                                    release

  -u, --targetusername=targetusername                                               username or alias for the target
                                                                                    org; overrides default target org

  --apiversion=apiversion                                                           override the api version used for
                                                                                    api requests made by this command

  --bypass                                                                          bypass the change case commands

  --dryrun                                                                          run the command without making any
                                                                                    API calls - all calls will be
                                                                                    'successful'

  --json                                                                            format output as json

  --loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)  [default: warn] logging level for
                                                                                    this command invocation

See code: src/commands/create.ts

sfchangecase updateScheduledBuild -i <string> -b <string> [--bypass] [--dryrun] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

updateScheduledBuild

USAGE
  $ sfchangecase updateScheduledBuild -i <string> -b <string> [--bypass] [--dryrun] [-u <string>] [--apiversion
  <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

OPTIONS
  -b, --scheduledbuild=scheduledbuild                                               (required) enter scheduledbuild
  -i, --workitemid=workitemid                                                       (required) enter workitem id

  -u, --targetusername=targetusername                                               username or alias for the target
                                                                                    org; overrides default target org

  --apiversion=apiversion                                                           override the api version used for
                                                                                    api requests made by this command

  --bypass                                                                          bypass the change case commands

  --dryrun                                                                          run the command without making any
                                                                                    API calls - all calls will be
                                                                                    'successful'

  --json                                                                            format output as json

  --loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)  [default: warn] logging level for
                                                                                    this command invocation

See code: src/commands/updateScheduledBuild.ts