Some cleanup
This commit is contained in:
@@ -45,7 +45,7 @@ jobs:
|
||||
|
||||
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
|
||||
if [[ "$TAG" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
|
||||
echo "Error: DOCKER_TAG ($TAG) is not allowed to match `MAJOR.MINOR.PATCH` inside a pull request."
|
||||
echo "Error: DOCKER_TAG ($TAG) is not allowed to match `MAJOR.MINOR.PATCH` format inside a pull request."
|
||||
echo "Please rename the docker tag in `action.yml` and try again."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Vendored
+1
-1
@@ -123585,7 +123585,7 @@ module.exports = JSON.parse('{"eN":{"H":"https://github.com/elastic/require-in-t
|
||||
/***/ ((module) => {
|
||||
|
||||
"use strict";
|
||||
module.exports = JSON.parse('{"name":"action-release","version":"1.10.5","private":true,"description":"GitHub Action for creating a release on Sentry","main":"dist/index.js","scripts":{"start":"node dist/index.js","build":"ncc build src/main.ts -e @sentry/cli","format":"prettier --write **/*.ts **/*.md","format-check":"prettier --check **/*.ts **/*.md","lint":"eslint src/**/*.ts","test":"jest","all":"yarn run format && yarn run lint && yarn run build && yarn test","bump-docker-tag":"./scripts/set-docker-tag.sh","bump-docker-tag-from-branch":"./scripts/set-branch-docker-tag.sh"},"repository":{"type":"git","url":"git+https://github.com/getsentry/action-release.git"},"keywords":["actions","sentry","release"],"author":"Sentry","license":"MIT","dependencies":{"@actions/core":"^1.11.1","@sentry/node":"^8.54.0","@sentry/cli":"^2.41.1"},"devDependencies":{"@types/jest":"^29.5.6","@types/node":"^20.8.9","@typescript-eslint/parser":"^6.9.0","@vercel/ncc":"^0.38.1","eslint":"^8.52.0","eslint-plugin-github":"^4.10.1","eslint-plugin-jest":"^27.4.3","jest":"^29.7.0","jest-circus":"^29.7.0","js-yaml":"^4.1.0","prettier":"^3.0.3","ts-jest":"^29.1.1","typescript":"^5.2.2"},"volta":{"node":"18.17.0","yarn":"1.22.4"}}');
|
||||
module.exports = JSON.parse('{"name":"action-release","version":"1.10.5","private":true,"description":"GitHub Action for creating a release on Sentry","main":"dist/index.js","scripts":{"all":"yarn run format && yarn run lint && yarn run build && yarn test","build":"ncc build src/main.ts -e @sentry/cli","format":"prettier --write **/*.ts **/*.md","format-check":"prettier --check **/*.ts **/*.md","lint":"eslint src/**/*.ts","set-docker-tag":"./scripts/set-docker-tag.sh","set-docker-tag-from-branch":"./scripts/set-docker-tag-from-branch.sh","start":"node dist/index.js","test":"jest"},"repository":{"type":"git","url":"git+https://github.com/getsentry/action-release.git"},"keywords":["actions","sentry","release"],"author":"Sentry","license":"MIT","dependencies":{"@actions/core":"^1.11.1","@sentry/node":"^8.54.0","@sentry/cli":"^2.41.1"},"devDependencies":{"@types/jest":"^29.5.6","@types/node":"^20.8.9","@typescript-eslint/parser":"^6.9.0","@vercel/ncc":"^0.38.1","eslint":"^8.52.0","eslint-plugin-github":"^4.10.1","eslint-plugin-jest":"^27.4.3","jest":"^29.7.0","jest-circus":"^29.7.0","js-yaml":"^4.1.0","prettier":"^3.0.3","ts-jest":"^29.1.1","typescript":"^5.2.2"},"volta":{"node":"18.17.0","yarn":"1.22.4"}}');
|
||||
|
||||
/***/ })
|
||||
|
||||
|
||||
+5
-6
@@ -40,14 +40,13 @@ Telemetry for internal development is collected using `@sentry/node`, see `src/t
|
||||
Members of this repo will not have to set anything up since [the integration](https://sentry-ecosystem.sentry.io/settings/developer-settings/end-to-end-action-release-integration-416eb2/) is already set-up. Just open the PR and you will see [a release created](https://sentry-ecosystem.sentry.io/releases/?project=4505075304693760) for your PR.
|
||||
|
||||
> [!WARNING]
|
||||
> After you create a branch **ALWAYS** run `yarn bump-docker-tag-from-branch`.
|
||||
> This is **very important**. You should avoid publishing changes to an already existing docker image,
|
||||
> especially to docker images tagged with release versions, e.g. `1.11.0`.
|
||||
>
|
||||
> **Never** write a version tag into `action.yml` yourself, let the release process handle this.
|
||||
> After you create a branch **ALWAYS** run `yarn set-docker-tag-from-branch`.
|
||||
> This is **very important**. You should avoid publishing changes to an already existing docker image.
|
||||
>
|
||||
> Docker tags in action.yml that match `MAJOR.MINOR.PATCH` will be rejected by the CI on pull requests.
|
||||
|
||||
1. Create a branch
|
||||
2. Run `yarn bump-docker-tag-from-branch` to set a docker tag based on your github branch name. This is important so that the action gets its own Docker image, allowing you to test the action in a different repo.
|
||||
2. Run `yarn set-docker-tag-from-branch` to set a docker tag based on your github branch name. This is important so that the action gets its own Docker image, allowing you to test the action in a different repo.
|
||||
3. Make changes
|
||||
4. If possible, add unit and E2E tests (inside `.github/workflows/build.yml`)
|
||||
5. Run `yarn install` to install deps
|
||||
|
||||
+5
-5
@@ -5,15 +5,15 @@
|
||||
"description": "GitHub Action for creating a release on Sentry",
|
||||
"main": "dist/index.js",
|
||||
"scripts": {
|
||||
"start": "node dist/index.js",
|
||||
"all": "yarn run format && yarn run lint && yarn run build && yarn test",
|
||||
"build": "ncc build src/main.ts -e @sentry/cli",
|
||||
"format": "prettier --write **/*.ts **/*.md",
|
||||
"format-check": "prettier --check **/*.ts **/*.md",
|
||||
"lint": "eslint src/**/*.ts",
|
||||
"test": "jest",
|
||||
"all": "yarn run format && yarn run lint && yarn run build && yarn test",
|
||||
"bump-docker-tag": "./scripts/set-docker-tag.sh",
|
||||
"bump-docker-tag-from-branch": "./scripts/set-branch-docker-tag.sh"
|
||||
"set-docker-tag": "./scripts/set-docker-tag.sh",
|
||||
"set-docker-tag-from-branch": "./scripts/set-docker-tag-from-branch.sh",
|
||||
"start": "node dist/index.js",
|
||||
"test": "jest"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@@ -18,4 +18,4 @@ npm version "${NEW_VERSION}"
|
||||
yarn install && yarn build
|
||||
|
||||
# Update the docker tag in action.yml
|
||||
yarn bump-docker-tag "${NEW_VERSION}"
|
||||
yarn set-docker-tag "${NEW_VERSION}"
|
||||
|
||||
Reference in New Issue
Block a user