Skip to content
Open
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
62 changes: 62 additions & 0 deletions .github/workflows/create_release_tag.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Create Release Tag

permissions:
contents: write

on:
workflow_dispatch:
inputs:
version:
description: "Version to release (e.g., 1.2.3)"
required: true
type: string

jobs:
create-tag:
runs-on: ubuntu-latest
steps:
- name: Checkout Main Branch
uses: actions/checkout@v4
with:
ref: "main"
fetch-depth: 0

- name: Install poetry
run: pipx install poetry

- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: "3.11"
cache: "poetry"

- name: Get Current Version
id: get_version
run: |
echo "CURRENT_VERSION=$(poetry version -s)" >> $GITHUB_ENV

- name: Validate Version Match
run: |
if [ "${{ github.event.inputs.version }}" != "${{ env.CURRENT_VERSION }}" ]; then
echo "Error: Input version (${{ github.event.inputs.version }}) does not match pyproject.toml version (${{ env.CURRENT_VERSION }})"
echo "Please update the version in pyproject.toml first by running: poetry version ${{ github.event.inputs.version }}"
exit 1
fi

- name: Setup Git Config
run: |
git config user.name "GitHub Actions"
git config user.email "actions@github.com"

- name: Create and Push Tag
run: |
git tag -a "v${{ github.event.inputs.version }}" -m "Release version ${{ github.event.inputs.version }}"
git push origin "v${{ github.event.inputs.version }}"

- name: Create GitHub Release
run: |
gh release create "v${{ github.event.inputs.version }}" \
--title "v${{ github.event.inputs.version }}" \
--generate-notes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
73 changes: 0 additions & 73 deletions .github/workflows/prod_patches_to_main.yaml

This file was deleted.

6 changes: 3 additions & 3 deletions .github/workflows/pypi.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# This worklfow pushes the ValidMind Library package to PyPI
# This workflow pushes the ValidMind Library package to PyPI when a tag is created

name: Publish to PyPI

on:
push:
branches:
- prod
tags:
- 'v*.*.*'

permissions:
contents: read
Expand Down
74 changes: 0 additions & 74 deletions .github/workflows/release_prod.yaml

This file was deleted.

Loading