Skip to content

Commit c550a46

Browse files
authored
add standard autodeployment (#57) (#63)
* add standard autodeployment (#57) * use OpenID Connect (OIDC) for deploy.yml - trusted PyPi published configured - removed TOKEN-based authentication (note: repo had never any secrets defined) * trusted publisher workflow - update deploy.yaml with @IAlibay's updates in GridDataFormats - added 'deploy' environment in MDAnalysisData settings - updated Trusted Publisher for PyPi project - added pending Trusted Publisher (https://docs.pypi.org/trusted-publishers/) for Test PyPi project
1 parent 657d2b6 commit c550a46

2 files changed

Lines changed: 58 additions & 0 deletions

File tree

.github/workflows/deploy.yaml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Build and upload to PyPi
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
release:
8+
types:
9+
- published
10+
11+
jobs:
12+
testpypi_push:
13+
environment:
14+
name: deploy
15+
url: https://test.pypi.org/p/MDAnalysisData
16+
permissions:
17+
id-token: write
18+
if: |
19+
github.repository == 'MDAnalysis/MDAnalysisData' &&
20+
(github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
21+
name: Build, upload and test pure Python wheels to TestPypi
22+
runs-on: ubuntu-latest
23+
24+
steps:
25+
- uses: actions/checkout@v4
26+
27+
- name: testpypi_deploy
28+
uses: MDAnalysis/pypi-deployment@main
29+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
30+
with:
31+
test_submission: true
32+
package_name: MDAnalysisData
33+
module_name: 'MDAnalysisData'
34+
35+
pypi_push:
36+
environment:
37+
name: deploy
38+
url: https://pypi.org/p/MDAnalysisData
39+
permissions:
40+
id-token: write
41+
if: |
42+
github.repository == 'MDAnalysis/MDAnalysisData' &&
43+
(github.event_name == 'release' && github.event.action == 'published')
44+
name: Build, upload and test pure Python wheels to PyPi
45+
runs-on: ubuntu-latest
46+
47+
steps:
48+
- uses: actions/checkout@v4
49+
50+
- name: pypi_deploy
51+
uses: MDAnalysis/pypi-deployment@main
52+
if: github.event_name == 'release' && github.event.action == 'published'
53+
with:
54+
package_name: MDAnalysisData
55+
module_name: 'MDAnalysisData'

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99
### Changes
1010
- Update package to only support NEP29 range (Python 3.9 - 3.12 as of writing)
1111

12+
### Changes (internal)
13+
- automated deployment (#57)
14+
1215
## [0.8.1] - 2021-10-04
1316

1417
### Added

0 commit comments

Comments
 (0)