Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Add Release action #1159

Closed
wants to merge 1 commit into from
Closed
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
55 changes: 55 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: 🚀 release
run-name: Release ${{ inputs.ref || github.ref_name }} (${{ github.event_name }})

on:
workflow_dispatch:
inputs:
ref:
description: Tag to release
required: true
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"

permissions: {}

jobs:
dist:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.ref }}
- name: Build package
run: pipx run build
- uses: actions/upload-artifact@v4
with:
name: dist
path: dist
upload_pypi:
name: Upload
needs: [ dist ]
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/project/rpmlint/
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v4
with:
name: dist
path: dist
- uses: pypa/gh-action-pypi-publish@release/v1
release:
needs: [ upload_pypi ]
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: softprops/action-gh-release@v1
with:
name: RPMLint ${{ github.ref_name }}
draft: true
generate_release_notes: true