Skip to content

Add TOC text2df

Add TOC text2df #56

Workflow file for this run

name: Release
on:
push:
branches:
- master
jobs:
release:
runs-on: ubuntu-latest
env:
version:
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Install dependencies
run: |
pip3 install --upgrade pip
pip3 install -r requirements.txt
- name: Get the current version
id: current-version
run: echo "version=$(python setup.py --version)" >> $GITHUB_ENV
- name: Check if the commit message matches the release pattern
run: |
if [[ $(git log -1 --pretty=%B) != "Release v${{ env.version }}" ]]; then
echo "Commit message does not match the release pattern."
exit 1
fi
- name: Setup PyPI Package using poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
poetry build
poetry config http-basic.pypi ${{ secrets.PYPI_USERNAME }} ${{ secrets.PYPI_PASSWORD }}
poetry publish
- name: Create a new release
uses: CupOfTea696/[email protected]
with:
title: "Release $version"
tag: "v$semver"
draft: false
regex: "/^Release #{semver}$/i"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload to GitHub Packages using Docker
run: |
docker build -t data-preprocessors .
docker login docker.pkg.github.com -u musfiqdehan -p ${{ secrets.PACKAGE_MANAGEMENT }}
docker tag data-preprocessors docker.pkg.github.com/musfiqdehan/data-preprocessors/data-preprocessors-image:v${{ env.version }}
docker push docker.pkg.github.com/musfiqdehan/data-preprocessors/data-preprocessors-image:v${{ env.version }}