Skip to content

Commit e839e55

Browse files
committed
Updated for CI
1 parent 8d81e02 commit e839e55

File tree

4 files changed

+75
-3
lines changed

4 files changed

+75
-3
lines changed

.github/workflows/publish-pypi.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Upload to pypi.org
2+
3+
on:
4+
# Triggers the workflow when a release is created
5+
release:
6+
types: [created]
7+
8+
workflow_dispatch:
9+
10+
jobs:
11+
upload:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
# Install Python
18+
- uses: actions/setup-python@v2
19+
with:
20+
python-version: "3.10"
21+
22+
- name: Installs and upgrades pip and the build dependencies
23+
run: |
24+
python3 -m pip install --upgrade pip
25+
python3 -m pip install .[dev]
26+
27+
- name: Build and Upload to PyPI
28+
continue-on-error: true
29+
run: |
30+
python3 -m build
31+
python3 -m twine upload dist/*
32+
env:
33+
TWINE_USERNAME: __token__
34+
TWINE_PASSWORD: ${{ secrets.TWINE_TOKEN }}
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Upload to test.pypi.org
2+
3+
on:
4+
# Triggers the workflow on push to the master branch
5+
push:
6+
branches: [ master ]
7+
8+
workflow_dispatch:
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
# Install Python
18+
- uses: actions/setup-python@v2
19+
with:
20+
python-version: "3.10"
21+
22+
- name: Installs and upgrades pip and the build dependencies
23+
run: |
24+
python3 -m pip install --upgrade pip
25+
python3 -m pip install .[dev]
26+
27+
- name: Build and Upload to PyPI
28+
continue-on-error: true
29+
run: |
30+
python3 -m build
31+
python3 -m twine upload dist/*
32+
env:
33+
TWINE_USERNAME: __token__
34+
TWINE_PASSWORD: ${{ secrets.TWINE_TEST_TOKEN }}
35+
TWINE_REPOSITORY: testpypi

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
[![pylint](https://github.com/PatrickBaus/pyAsyncGpib/actions/workflows/pylint.yml/badge.svg)](https://github.com/PatrickBaus/pyAsyncGpib/actions/workflows/pylint.yml)
2+
[![PyPI](https://img.shields.io/pypi/v/async_gpib)](https://pypi.org/project/async_gpib/)
3+
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/async_gpib)
4+
![PyPI - Status](https://img.shields.io/pypi/status/async_gpib)
25
[![code style](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
36
# async_gpib
47
Python3 AsyncIO [Linux GPIB Wrapper](https://linux-gpib.sourceforge.io/). The library requires Python [asyncio](https://docs.python.org/3/library/asyncio.html) and is a thin wrapper for the threaded Linux GPIB Wrapper library.
@@ -49,11 +52,11 @@ python3 -m venv env # virtual environment, optional
4952
source env/bin/activate
5053
python3 pip install .
5154
```
52-
Alternatively the package can be directly installed via pip:
55+
Alternatively the package can be directly installed via Pypi:
5356
```bash
5457
python3 -m venv env # virtual environment, optional
5558
source env/bin/activate
56-
pip install -e git+https://github.com/PatrickBaus/pyAsyncGpib#egg=async_gpib
59+
pip install async_gpib
5760
```
5861

5962
## Usage

async_gpib/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# pylint: disable=missing-module-docstring
2-
__version__ = "2.1.0"
2+
__version__ = "2.1.1"

0 commit comments

Comments
 (0)