update release version to be pep-440

This commit is contained in:
Her Email 2023-11-30 18:17:08 -05:00 committed by Henri Dickson
parent 3d200814d4
commit c0c26b7729
4 changed files with 20 additions and 8 deletions

View file

@ -3,7 +3,7 @@ name: Release Image
on: on:
push: push:
tags: tags:
- "v*" - "[0-9]*"
concurrency: concurrency:
group: ${{ github.workflow }}-${{ github.ref }} group: ${{ github.workflow }}-${{ github.ref }}
@ -27,13 +27,18 @@ jobs:
cd neodb-takahe cd neodb-takahe
echo "takahe=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT echo "takahe=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Overwrite version in code
env:
REF_NAME: ${{ github.ref_name }}
run: echo '__version__ = "'$REF_NAME'"' > boofilsic/__init__.py
- name: Send Discord notification - name: Send Discord notification
uses: appleboy/discord-action@master uses: appleboy/discord-action@master
with: with:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }} webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
color: "#1857a4" color: "#1857a4"
message: Building release image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }} message: Building release image ${{ github.ref_name }}-${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}
- name: Set up QEMU - name: Set up QEMU
uses: docker/setup-qemu-action@v2 uses: docker/setup-qemu-action@v2
@ -48,8 +53,9 @@ jobs:
images: neodb/neodb images: neodb/neodb
tags: | tags: |
type=raw,value=latest type=raw,value=latest
type=semver,pattern={{version}} type=pep440,pattern={{version}}
type=raw,value=${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }} type=pep440,pattern={{major}}.{{minor}}
# type=raw,value=${{ steps.version.outputs.version }}-${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}
- name: Login to DockerHub - name: Login to DockerHub
if: github.event_name != 'pull_request' if: github.event_name != 'pull_request'
@ -73,4 +79,4 @@ jobs:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }} webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
color: "#1857a4" color: "#1857a4"
message: Published release image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }} message: Published release image ${{ github.ref_name }}-${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}

View file

@ -31,13 +31,18 @@ jobs:
cd neodb-takahe cd neodb-takahe
echo "takahe=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT echo "takahe=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Overwrite version in code
env:
REF_NAME: ${{ github.ref_name }}
run: echo '__version__ = "'$REF_NAME'"' > boofilsic/__init__.py
- name: Send Discord notification - name: Send Discord notification
uses: appleboy/discord-action@master uses: appleboy/discord-action@master
with: with:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }} webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
color: "#1857a4" color: "#1857a4"
message: Building development image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }} message: Building development image ${{ github.ref_name }}-${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}
- name: Set up QEMU - name: Set up QEMU
uses: docker/setup-qemu-action@v2 uses: docker/setup-qemu-action@v2
@ -75,4 +80,4 @@ jobs:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }} webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
color: "#1857a4" color: "#1857a4"
message: Published development image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }} message: Published development image ${{ github.ref_name }}-${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}

View file

@ -3,6 +3,7 @@
![](https://github.com/neodb-social/neodb/actions/workflows/check.yml/badge.svg?branch=main) ![](https://github.com/neodb-social/neodb/actions/workflows/check.yml/badge.svg?branch=main)
![](https://github.com/neodb-social/neodb/actions/workflows/tests.yml/badge.svg?branch=main) ![](https://github.com/neodb-social/neodb/actions/workflows/tests.yml/badge.svg?branch=main)
![](https://github.com/neodb-social/neodb/actions/workflows/publish.yml/badge.svg?branch=main) ![](https://github.com/neodb-social/neodb/actions/workflows/publish.yml/badge.svg?branch=main)
![](https://github.com/neodb-social/neodb/actions/workflows/publish-tags.yml/badge.svg)
NeoDB (fka boofilsic) is an open source project and free service to help users manage, share and discover collections, reviews and ratings for culture products (e.g. books, movies, music, podcasts, games and performances) in Fediverse. NeoDB (fka boofilsic) is an open source project and free service to help users manage, share and discover collections, reviews and ratings for culture products (e.g. books, movies, music, podcasts, games and performances) in Fediverse.

View file

@ -1 +1 @@
__version__ = "0.9.0" __version__ = "dev"