Skip to content

Commit 4e99f9f

Browse files
authored
Merge pull request #239 from saeyslab/development
Development
2 parents 60e33f6 + da232f8 commit 4e99f9f

20 files changed

Lines changed: 626 additions & 319295 deletions

.github/workflows/deploy-pypi.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: deploy-pypi
2+
3+
# deploy after a merge to main was succesfully done
4+
on:
5+
pull_request:
6+
types:
7+
- closed
8+
branches:
9+
- main
10+
11+
# Allows you to run this workflow manually from the Actions tab
12+
workflow_dispatch:
13+
14+
15+
# security: restrict permissions for CI jobs.
16+
permissions:
17+
contents: read
18+
19+
jobs:
20+
build:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- uses: actions/checkout@v6
24+
with:
25+
persist-credentials: false
26+
- uses: actions/setup-python@v6
27+
with:
28+
python-version: '3.12'
29+
- run: |
30+
pip install --upgrade pip
31+
pip install -r requirements.txt
32+
pip install hatch
33+
pip install -e
34+
- run: |
35+
hatch build
36+
37+
pypi-publish:
38+
name: Upload release to PyPI
39+
needs: build
40+
runs-on: ubuntu-latest
41+
environment:
42+
name: pypi
43+
url: https://pypi.org/p/nichenetpy
44+
permissions:
45+
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
46+
steps:
47+
- name: Publish package to TestPyPI
48+
uses: pypa/gh-action-pypi-publish@release/v1
49+
with:
50+
password: ${{ secrets.NICHENET_API_TOKEN_PYPI }}
51+
repository-url: https://upload.pypi.org/legacy/

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<!-- badges: start -->
22
[![pytest](https://github.com/saeyslab/nichenetpy/actions/workflows/python-package.yml/badge.svg?branch=main)](https://github.com/saeyslab/nichenetpy/actions/workflows/python-package.yml)
33
[![pdoc](https://github.com/saeyslab/nichenetpy/actions/workflows/pdoc.yml/badge.svg?branch=main)](https://github.com/saeyslab/nichenetpy/actions/workflows/pdoc.yml)
4+
[![pypi](https://github.com/saeyslab/nichenetpy/actions/workflows/deploy-pypi.yml/badge.svg?branch=main)](https://github.com/saeyslab/nichenetpy/actions/workflows/deploy-pypi.yml)
45
<!-- badges: end -->
56

67
**NicheNetPy: the python implementation of the NicheNet method. (ported from [NicheNetR](https://github.com/saeyslab/nichenetr/tree/master))** The goal of

0 commit comments

Comments
 (0)