mirror of
https://github.com/sonr-io/sonr.git
synced 2026-08-04 18:31:41 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
63dc68caac | ||
|
|
ec57c76a2a | ||
|
|
99e9eefffb | ||
|
|
eb0777ebb4 | ||
|
|
ed5ee034b8 | ||
|
|
bb2972b527 | ||
|
|
45b474c9a6 | ||
|
|
99747c022e |
@@ -2,7 +2,7 @@
|
|||||||
name = "cz_conventional_commits"
|
name = "cz_conventional_commits"
|
||||||
tag_format = "v$version"
|
tag_format = "v$version"
|
||||||
version_scheme = "semver"
|
version_scheme = "semver"
|
||||||
version = "0.5.22"
|
version = "0.5.25"
|
||||||
update_changelog_on_bump = true
|
update_changelog_on_bump = true
|
||||||
major_version_zero = true
|
major_version_zero = true
|
||||||
changelog_file = "./docs/docs/changelog/index.md"
|
changelog_file = "./docs/docs/changelog/index.md"
|
||||||
|
|||||||
@@ -1,17 +1,49 @@
|
|||||||
name: Scheduled Release
|
name: Versioned Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
|
||||||
push:
|
push:
|
||||||
tags:
|
tags: ["v*"]
|
||||||
- v*
|
branches: ["develop"]
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
check-release:
|
||||||
|
name: Check Existing Release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
outputs:
|
||||||
|
release_exists: ${{ steps.check.outputs.release_exists }}
|
||||||
|
is_tag: ${{ steps.check-ref.outputs.is_tag }}
|
||||||
|
ref_name: ${{ steps.check-ref.outputs.ref_name }}
|
||||||
|
steps:
|
||||||
|
- name: Determine ref type and name
|
||||||
|
id: check-ref
|
||||||
|
run: |
|
||||||
|
if [[ $GITHUB_REF == refs/tags/* ]]; then
|
||||||
|
echo "is_tag=true" >> "$GITHUB_OUTPUT"
|
||||||
|
echo "ref_name=${GITHUB_REF#refs/tags/}" >> "$GITHUB_OUTPUT"
|
||||||
|
else
|
||||||
|
echo "is_tag=false" >> "$GITHUB_OUTPUT"
|
||||||
|
echo "ref_name=${GITHUB_REF#refs/heads/}" >> "$GITHUB_OUTPUT"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: Check if release exists
|
||||||
|
id: check
|
||||||
|
if: steps.check-ref.outputs.is_tag == 'true'
|
||||||
|
run: |
|
||||||
|
RELEASE_EXISTS=$(curl -s -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
|
||||||
|
"https://api.github.com/repos/onsonr/sonr/releases/tags/${GITHUB_REF#refs/tags/}" \
|
||||||
|
| jq -r 'if .message == "Not Found" then "false" else "true" end')
|
||||||
|
echo "release_exists=$RELEASE_EXISTS" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
goreleaser:
|
goreleaser:
|
||||||
name: Release motr, sonrd, and DWN
|
name: Run GoReleaser
|
||||||
|
needs: check-release
|
||||||
|
if: |
|
||||||
|
(needs.check-release.outputs.is_tag == 'true' && needs.check-release.outputs.release_exists == 'false') ||
|
||||||
|
(needs.check-release.outputs.is_tag == 'false')
|
||||||
permissions: write-all
|
permissions: write-all
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
@@ -22,6 +54,18 @@ jobs:
|
|||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
fetch-tags: true
|
fetch-tags: true
|
||||||
|
|
||||||
|
- name: Set up release configuration
|
||||||
|
id: setup
|
||||||
|
run: |
|
||||||
|
if [[ "${{ needs.check-release.outputs.is_tag }}" == "true" ]]; then
|
||||||
|
echo "Using tag configuration"
|
||||||
|
git checkout ${{ needs.check-release.outputs.ref_name }}
|
||||||
|
echo "args=release --clean" >> "$GITHUB_OUTPUT"
|
||||||
|
else
|
||||||
|
echo "Using snapshot configuration"
|
||||||
|
echo "args=release --snapshot --clean" >> "$GITHUB_OUTPUT"
|
||||||
|
fi
|
||||||
|
|
||||||
- uses: actions/setup-go@v5
|
- uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: "1.23"
|
go-version: "1.23"
|
||||||
@@ -38,7 +82,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
distribution: goreleaser-pro
|
distribution: goreleaser-pro
|
||||||
version: latest
|
version: latest
|
||||||
args: release --clean
|
args: ${{ steps.setup.outputs.args }}
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GH_RELEASER_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GH_RELEASER_TOKEN }}
|
||||||
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
|
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
|
||||||
|
|||||||
@@ -64,7 +64,6 @@ archives:
|
|||||||
format: tar.gz
|
format: tar.gz
|
||||||
files:
|
files:
|
||||||
- src: README*
|
- src: README*
|
||||||
- src: CHANGELOG*
|
|
||||||
wrap_in_directory: true
|
wrap_in_directory: true
|
||||||
|
|
||||||
- id: hway
|
- id: hway
|
||||||
@@ -77,7 +76,6 @@ archives:
|
|||||||
format: tar.gz
|
format: tar.gz
|
||||||
files:
|
files:
|
||||||
- src: README*
|
- src: README*
|
||||||
- src: CHANGELOG*
|
|
||||||
wrap_in_directory: true
|
wrap_in_directory: true
|
||||||
|
|
||||||
nfpms:
|
nfpms:
|
||||||
@@ -171,17 +169,8 @@ release:
|
|||||||
replace_existing_draft: true
|
replace_existing_draft: true
|
||||||
replace_existing_artifacts: true
|
replace_existing_artifacts: true
|
||||||
extra_files:
|
extra_files:
|
||||||
- glob: ./CHANGELOG*
|
|
||||||
- glob: ./README*
|
- glob: ./README*
|
||||||
|
|
||||||
cloudsmiths:
|
|
||||||
- organization: sonr
|
|
||||||
repository: sonr
|
|
||||||
distributions:
|
|
||||||
deb: "ubuntu/jammy"
|
|
||||||
alpine: "alpine/v3.8"
|
|
||||||
rpm: "el/7"
|
|
||||||
|
|
||||||
announce:
|
announce:
|
||||||
telegram:
|
telegram:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|||||||
@@ -1,3 +1,23 @@
|
|||||||
|
## v0.5.25 (2024-12-11)
|
||||||
|
|
||||||
|
### Feat
|
||||||
|
|
||||||
|
- enable GoReleaser releases on tags and snapshots
|
||||||
|
- automate release on tag and workflow dispatch
|
||||||
|
|
||||||
|
## v0.5.24 (2024-12-11)
|
||||||
|
|
||||||
|
### Feat
|
||||||
|
|
||||||
|
- prevent duplicate releases
|
||||||
|
|
||||||
|
## v0.5.23 (2024-12-11)
|
||||||
|
|
||||||
|
### Refactor
|
||||||
|
|
||||||
|
- rename scheduled release workflow to versioned release
|
||||||
|
- remove changelog from release artifacts
|
||||||
|
|
||||||
## v0.5.22 (2024-12-11)
|
## v0.5.22 (2024-12-11)
|
||||||
|
|
||||||
### Feat
|
### Feat
|
||||||
|
|||||||
Reference in New Issue
Block a user