Skip to content

Release

Release #949

Workflow file for this run

name: Release
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: ^1.22
- name: Build geosite
id: build
run: |
go run -v .
- name: Release rule sets
if: steps.build.outputs.skip != 'true'
run: .github/release-rule-set.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Generate sha256 hash
if: steps.build.outputs.skip != 'true'
run: |
sha256sum geosite.db > geosite.db.sha256sum
sha256sum geosite-cn.db > geosite-cn.db.sha256sum
- name: Release release branch
if: steps.build.outputs.skip != 'true'
run: .github/release-branch.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: dev-drprasad/[email protected]
if: steps.build.outputs.skip != 'true'
with:
keep_latest: 10
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Release geosite
if: steps.build.outputs.skip != 'true'
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ steps.build.outputs.tag }}
files: |
geosite.db
geosite.db.sha256sum
geosite-cn.db
geosite-cn.db.sha256sum