Skip to content

Commit

Permalink
0.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
chayim committed Feb 14, 2023
1 parent a3a3e14 commit f04964e
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 25 deletions.
58 changes: 34 additions & 24 deletions .github/workflows/pypi-publish.yaml
Original file line number Diff line number Diff line change
@@ -1,34 +1,44 @@
name: Publish tag to Pypi

name: Publish Pypi
on:
release:
types: [published]

permissions:
contents: read # to fetch code (actions/checkout)
types: [ published ]

jobs:

build_and_package:
pytest:
name: Publish to PyPi
runs-on: ubuntu-latest
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
steps:
- uses: actions/checkout@v3
- name: install python
uses: actions/setup-python@v4
- uses: actions/checkout@master

- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.9
- name: Install dev tools
run: |
pip install -r dev_requirements.txt
pip install twine wheel
python-version: 3.8

- name: Build package
run: |
python setup.py build
python setup.py sdist bdist_wheel
- name: Install Poetry
uses: dschep/[email protected]

- name: Publish to Pypi
uses: pypa/gh-action-pypi-publish@release/v1
- name: Cache Poetry virtualenv
uses: actions/cache@v1
id: cache
with:
user: __token__
password: ${{ secrets.PYPI_TOKEN }}
path: ~/.virtualenvs
key: poetry-${{ hashFiles('**/poetry.lock') }}
restore-keys: |
poetry-${{ hashFiles('**/poetry.lock') }}
- name: Set Poetry config
run: |
poetry config virtualenvs.in-project false
poetry config virtualenvs.path ~/.virtualenvs
- name: Install Dependencies
run: poetry install
if: steps.cache.outputs.cache-hit != 'true'

- name: Publish to PyPI
if: github.event_name == 'release'
run: |
poetry publish -u __token__ -p ${{ secrets.PYPI_TOKEN }} --build
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "redisenv"
version = "0.1.1"
version = "0.1.2"
description = "A tool for building redis test environments"
authors = ["Redis OSS <[email protected]>"]
readme = "README.md"
Expand Down

0 comments on commit f04964e

Please sign in to comment.