Skip to content

Commit

Permalink
chore: add release system
Browse files Browse the repository at this point in the history
  • Loading branch information
nydragon committed May 23, 2024
1 parent a72b4be commit d1f85a8
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 1 deletion.
33 changes: 33 additions & 0 deletions .github/workflows/cd.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release

on:
push:
tags:
- "*.*.*"

permissions:
contents: write

jobs:
master-guard:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Exit if not on master branch
if: endsWith(github.ref, 'master') == false
run: exit -1
tests:
needs: [master-guard]
uses: ./.github/workflows/ci.yaml
deploy:
needs: [tests]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build
run: cargo build --release --verbose
- name: Release
uses: softprops/action-gh-release@v2
with:
files: ./target/release/rofi-obsidian
4 changes: 3 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: CI

on: pull_request
on:
- pull_request
- workflow_call

jobs:
build:
Expand Down

0 comments on commit d1f85a8

Please sign in to comment.