Skip to content

Commit

Permalink
chore: rename npm version command for nightlies to work (#1742)
Browse files Browse the repository at this point in the history
## Description

We run `npm version --no-git-tag-version "$FULL_VERSION"` to update the
version in package.json before a release. In Pepr Core, we accidentally
had overridden that command with a custom command that we use when we
publish SLSA. This fixes it and SLSA will still work

## Related Issue

Fixes #
<!-- or -->
Relates to #

## Type of change

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [x] Other (security config, docs update, etc)

## Checklist before merging
- [x] Unit,
[Journey](https://github.com/defenseunicorns/pepr/tree/main/journey),
[E2E Tests](https://github.com/defenseunicorns/pepr-excellent-examples),
[docs](https://github.com/defenseunicorns/pepr/tree/main/docs),
[adr](https://github.com/defenseunicorns/pepr/tree/main/adr) added or
updated as needed
- [x] [Contributor Guide
Steps](https://docs.pepr.dev/main/contribute/#submitting-a-pull-request)
followed

---------

Signed-off-by: Case Wylie <[email protected]>
  • Loading branch information
cmwylie19 authored Jan 29, 2025
1 parent 967eb05 commit 52bf35d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
npm install -g npm
npm run version
npm run set:version
# Build Controller Image
docker buildx build --push --platform linux/arm64/v8,linux/amd64 --tag ghcr.io/defenseunicorns/pepr/controller:${{ github.ref_name }} .
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
"ci": "npm ci",
"gen-data-json": "node hack/build-template-data.js",
"prebuild": "rm -fr dist/* && npm run gen-data-json",
"version": "node scripts/set-version.js",
"build": "tsc && node build.mjs && npm pack",
"build:image": "npm run build && docker buildx build --output type=docker --tag pepr:dev .",
"set:version": "node scripts/set-version.js",
"test": "npm run test:unit && npm run test:journey",
"test:unit": "npm run gen-data-json && jest src --coverage --detectOpenHandles --coverageDirectory=./coverage --testPathIgnorePatterns='cosign.e2e.test.ts'",
"test:integration": "npm run test:integration:prep && npm run test:integration:run",
Expand Down
2 changes: 1 addition & 1 deletion scripts/nightlies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,6 @@ echo "FULL_VERSION=$FULL_VERSION" >> "$GITHUB_ENV"

npm version --no-git-tag-version "$FULL_VERSION"

docker buildx build --push --platform linux/arm64/v8,linux/amd64 --tag ghcr.io/defenseunicorns/pepr/controller:"$FULL_VERSION" .
docker buildx build --push --platform linux/arm64/v8,linux/amd64 --tag ghcr.io/defenseunicorns/pepr/controller:v"$FULL_VERSION" .

npm publish --tag "nightly"

0 comments on commit 52bf35d

Please sign in to comment.