-
Notifications
You must be signed in to change notification settings - Fork 41
How‐to Create a SAF CLI Release
Emily Rodriguez edited this page Jul 15, 2025
·
8 revisions
Important
If a Draft Release isn't available, it is because there hasn't been any human content (PR's) pushed to the repository or the dependabot has not made any updates to the Draft Release. Verify the Actions and ensure that all dependabot actions have executed successfully.
Tip
Executing Step 1 is conducted via the appropriate script, if executing the release in a Darwin or Linux platform use the release-prep.sh script, if using a Windows platform use the release-pre.sh1. The scripts are located at the root of the repository.
- Run the appropriate script that prepares the repository for a release. The following are performed:
- Retrieve the latest main content
- Bump the SAF CLI version number in the package.json file (version tag)
- Update MITRE dependencies to latest versions
- Installs all supporting modules (removes if previously installed)
- Build and run all tests
- Add unstaged files to the staging area (package.json) or any other file with the modified flag (M) set
- Commit previously staged files with 'signoff' tag (new version number)
- Tag the commit with new release version
- Push and updated the repository three references (new version number)
Manually Execute Step 1
a. Make sure you're on the most recent commit on the SAF CLI by running `git pull`.
b. Bump the SAF CLI version number in the `VERSION` file and `package.json`
- It is a good idea to manually check and update the version of any `@mitre` dependencies in the `package.json` file.
c. Run `npm install`
d. Validate the build and unit tests
- Run `npm pack`
- Does a fresh build, checks for type issues, etc.
- Run `npm run test`
e. Add these changes, commit this change, associate a version tag with the commit (for example, "1.0.0"), and push them up
- `git add` the relevant files ***(Do not add the .tgz file that may have been created by the `npm run prepack` step)***
- `git commit -sm "[version]"`
- `git tag -am "brief description of change" [version]`
- `git push --atomic origin main [version]`
- Github actions will fire to produce executable versions of the SAF CLI for several OSes. Wait for the workflows for the macOS builds (.pkg), Windows builds (.exe), Apt-based build (.deb) and Dnf-based builds (.rpm) to finish. Download, and unzip the artifacts (local directory):
- Mac OS (zip file containing the following)
saf-v[version]-x64.pkgsaf-v[version]-arm64.pkg
- Windows (individual downloads - not zipped)
saf-v[version]-x64.exesaf-v[version]-x86.exe
- APT-based distros like Debian (zip file containing the following)
saf-v[version]-amd64.debsaf-v[version]-arm64.debsaf-v[version]-armel.deb
- DNF-based distros like RHEL (single file)
saf-v[version]-noarch.rpm
- Mac OS (zip file containing the following)
- Go to the SAF CLI GitHub Releases page
- click on the Draft release edit button
- Make sure that the appropriate tag number is selected
- click on the Draft release edit button
- Associate the tags with the drafted release (Combine all updates, except for "## Dependency Updates", under a "## What's New" section in the description)
- Attach the aforementioned, renamed artifacts to the draft release (Note: Attaching files using the drag and drop feature is much slower than attaching files by clicking on the link directly to upload files)
- Make sure that the
is selected - Publish release
- Wait for push-to-npm on release to complete
- Update the SAF Github Action Dependency by creating a release:
- Validate that the Homebrew Formula at https://github.com/mitre/homebrew-saf was automatically updated
- The
Formuladirectory should have been updated by saf-cli <X.X.X>, where <X.X.X> is the current SAF CLI Tag number
- The
Streamline security automation for systems and DevOps pipelines with the SAF CLI
- Home
- How to create a release
- Splunk Configuration
- Supplement HDF Configuration
- Validation with Thresholds
- Development Standards & References
- SAF CLI Delta Process
- Mapper Creation Guide for HDF Converters
- How to create a SAF CLI
- How to recommend development of a mapper
- Using an unreleased version of select packages from the SAF ecosystem in the SAF CLI
- Troubleshooting
