Skip to content

Commit 7df1c3f

Browse files
authored
Merge pull request #81 from UpCloudLtd/github-actions
feat(CI): move to github actions
2 parents c444efe + 3a6bbba commit 7df1c3f

File tree

5 files changed

+70
-54
lines changed

5 files changed

+70
-54
lines changed

.github/workflows/main.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: test
2+
3+
on:
4+
- push
5+
- pull_request
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
strategy:
11+
matrix:
12+
tox_env:
13+
- py36
14+
- py37
15+
- py38
16+
- py39
17+
- pypy3
18+
steps:
19+
- uses: actions/checkout@v2
20+
- name: Fedora Tox with ${{ matrix.tox_env }}
21+
uses: fedora-python/tox-github-action@v0.4
22+
with:
23+
tox_env: ${{ matrix.tox_env }}
24+
- uses: actions/setup-python@v2
25+
- uses: actions/cache@v2
26+
with:
27+
path: ~/.cache/pip
28+
key: ${{ runner.os }}-pip
29+
30+
deploy:
31+
name: Build deploy
32+
runs-on: ubuntu-latest
33+
steps:
34+
- uses: actions/checkout@v2
35+
- uses: casperdcl/deploy-pypi@v1
36+
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
37+
with:
38+
password: ${{ secrets.PYPI_TOKEN }}
39+
build: true
40+

.travis.yml

Lines changed: 0 additions & 32 deletions
This file was deleted.

setup.cfg

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,31 @@
11
[metadata]
2-
description-file = README.md
2+
name = upcloud_api
3+
description = UpCloud API Client
4+
long_description = README.md
5+
long_description_content_type = text/markdown
6+
opriginal_author = Elias Nygren
7+
maintainer = UpCloud
8+
maintainer_email = hello@upcloud.com
9+
url = https://github.com/UpCloudLtd/upcloud-python-api
10+
packages=['upcloud_api', 'upcloud_api.cloud_manager']
11+
license = MIT
12+
13+
[options]
14+
python_requires = >=3.6
15+
setup_requires =
16+
setuptools
17+
pytest-runner
18+
install_requires =
19+
requests
20+
six
21+
tests_require =
22+
pytest==4.0.2
23+
packages =
24+
upcloud_api
25+
upcloud_api.cloud_manager
26+
27+
[tox:tox]
28+
envlist = py27, py36, py37, py38, py39, pypy3
329

430
[bdist_wheel]
531
universal = 1

setup.py

Lines changed: 2 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,5 @@ def get_version(rel_path):
2323
with open('README.md') as f:
2424
long_description = f.read()
2525

26-
version = get_version('upcloud_api/__init__.py')
27-
setup(
28-
name='upcloud-api',
29-
version=version,
30-
description='UpCloud API Client',
31-
long_description=long_description,
32-
long_description_content_type='text/markdown',
33-
author='Elias Nygren',
34-
maintainer='UpCloud',
35-
maintainer_email='hello@upcloud.com',
36-
url='https://github.com/UpCloudLtd/upcloud-python-api',
37-
packages=['upcloud_api', 'upcloud_api.cloud_manager'],
38-
download_url='https://github.com/UpCloudLtd/upcloud-python-api/archive/%s.tar.gz' % version,
39-
license='MIT',
40-
python_requires='>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*',
41-
install_requires=[
42-
'requests>=2.24.0',
43-
'six==1.15.0'
44-
]
45-
)
26+
if __name__ == "__main__":
27+
setup(version=get_version('upcloud_api/__init__.py'))

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# and then run "tox" from this directory.
55

66
[tox]
7-
envlist = py27, py36, py37, py38, py39, pypy3
7+
envlist = py36, py37, py38, py39, pypy3
88
skip_missing_interpreters = True
99

1010
[testenv]

0 commit comments

Comments
 (0)