Skip to content

Release/v2.0.0 beta 1 #27

Release/v2.0.0 beta 1

Release/v2.0.0 beta 1 #27

Workflow file for this run

name: Publish
on:
pull_request:
branches:
- main
types: [closed]
jobs:
publish:
runs-on: ubuntu-latest
if: startsWith(github.head_ref, 'release/v') && github.event.pull_request.merged == true
env:
REPO: https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: main
fetch-depth: 0
- name: Initialize
shell: bash
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
auth_header="$(git config --local --get http.https://github.com/.extraheader)"
git submodule sync --recursive
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1
- name: Get tag name
id: vars
run: |
HEAD_REF=${{ github.head_ref }}
echo "tag=${HEAD_REF##*/v}" >> $GITHUB_OUTPUT
- name: setup rust
run: |
rustup update stable
cargo build --release
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: '0.85.0'
extended: true
- name: Build Site
run: |
(cd docs ; hugo)
- name: Create Distributions
run:
make dist
- name: Create release
id: create_release
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
automatic_release_tag: v${{ steps.vars.outputs.tag }}
title: Release v${{ steps.vars.outputs.tag }}
draft: false
prerelease: false
files: |
dist/sibling-${{ steps.vars.outputs.tag }}_*.tar.gz