mirror of
https://github.com/yeasy/docker_practice.git
synced 2026-03-27 12:15:34 +00:00
Auto-create release on tag push
This commit is contained in:
10
.github/workflows/release-pdf.yml
vendored
10
.github/workflows/release-pdf.yml
vendored
@@ -1,8 +1,9 @@
|
||||
name: Build PDF on Release
|
||||
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
@@ -34,10 +35,11 @@ jobs:
|
||||
- name: Build PDF
|
||||
run: mdpress build --format pdf --output docker_practice.pdf
|
||||
|
||||
- name: Upload PDF to Release
|
||||
if: github.event_name == 'release'
|
||||
- name: Create Release and upload PDF
|
||||
if: startsWith(github.ref, 'refs/tags/')
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
generate_release_notes: true
|
||||
files: docker_practice.pdf
|
||||
|
||||
- name: Upload PDF as artifact
|
||||
|
||||
Reference in New Issue
Block a user