Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 0 additions & 19 deletions .github/workflows/release-minor-trigger.yml

This file was deleted.

19 changes: 0 additions & 19 deletions .github/workflows/release-patch-trigger.yml

This file was deleted.

80 changes: 0 additions & 80 deletions .github/workflows/release-patch.yml

This file was deleted.

22 changes: 22 additions & 0 deletions .github/workflows/release-trigger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: release-trigger

on:
pull_request:
branches:
- master
types: [ closed ]

jobs:
release-trigger:
# Both labels mean the same thing here: the version to publish is read from
# LLama/LLamaSharp.csproj, so they only document the intent of the release.
if: >-
github.event.pull_request.merged == true &&
(contains(github.event.pull_request.labels.*.name, 'minor-release') ||
contains(github.event.pull_request.labels.*.name, 'patch-release'))
runs-on: ubuntu-22.04

steps:
# This job does no work. It exists so that "auto-release" has a successful workflow run
# to fire from, which is what gates the release on the PR labels above.
- run: echo "Release triggered by PR #${{ github.event.pull_request.number }}"
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
name: auto-minor-release
name: auto-release

on:
workflow_run:
workflows: ["release-minor-trigger"]
workflows: ["release-trigger"]
types:
- completed

env:
NUGET_API_TOKEN: ${{ secrets.LLAMA_SHARP_NUGET_KEY_REPO }}

jobs:
minor_release_to_nuget:
release_to_nuget:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-22.04

Expand Down
Loading