Skip to content

rename rate limit params #31

rename rate limit params

rename rate limit params #31

Workflow file for this run

on:
workflow_dispatch:
branches: [main]
push:
tags:
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
name: Create Release
permissions:
contents: write
jobs:
autorelease:
name: Create Release
runs-on: "ubuntu-latest"
services:
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 6379:6379
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- uses: astral-sh/setup-uv@v3
with:
enable-cache: true
- name: Add version to environment vars
run: |
PROJECT_VERSION=$(uvx dunamai from any --format "{base}")
echo "PROJECT_VERSION=$PROJECT_VERSION" >> $GITHUB_ENV
- name: Check if tag version matches project version
run: |
TAG=$(git describe HEAD --tags --abbrev=0)
echo $TAG
echo $PROJECT_VERSION
if [[ "$TAG" != "v$PROJECT_VERSION" ]]; then exit 1; fi
- name: Install deps
run: uv sync --frozen
- name: Run tests
run: uv run --no-sync pytest -v
- name: Build
run: uv build
- name: Create Release Draft
uses: softprops/action-gh-release@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: Release ${{ github.ref }}
draft: true
generate_release_notes: true
files: |
dist/taskbadger-${{env.PROJECT_VERSION}}-py3-none-any.whl
dist/taskbadger-${{env.PROJECT_VERSION}}.tar.gz