Skip to content

Commit

Permalink
gh actions for all packages
Browse files Browse the repository at this point in the history
  • Loading branch information
jplumail committed Sep 2, 2024
1 parent a85df82 commit d55a109
Show file tree
Hide file tree
Showing 19 changed files with 54 additions and 3,927 deletions.
37 changes: 32 additions & 5 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ jobs:
- name: Install dependencies
run: |
pip install devpi-client
pip install hatch
- name: Authenticate and upload to devpi
run: |
Expand All @@ -41,6 +40,36 @@ jobs:
pip install hatch
echo "version=$(hatch version)" >> "$GITHUB_OUTPUT"
publish-packages:
runs-on: ubuntu-latest

strategy:
matrix:
package: [napari-bbox, napari-spfluo, scipion-app, scipion-fluo, scipion-fluo-singleparticle, scipion-pyworkflow, spfluo]

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Install dependencies
run: |
pip install devpi-client
- name: Authenticate and upload to devpi
run: |
cd packages/${{ matrix.package }}
devpi use https://pypi.spfluo.ovh
devpi login jean --password=${{ secrets.DEVPI_PASSWORD }}
devpi use jean/dev
devpi upload
env:
DEVPI_PASSWORD: ${{ secrets.DEVPI_PASSWORD }}

compile-requirements:
runs-on: ubuntu-latest
needs: publish
Expand All @@ -50,7 +79,7 @@ jobs:
matrix:
platform: [x86_64-unknown-linux-gnu, x86_64-pc-windows-msvc]
gpu: [false, true]
python_version: ["8", "9", "10", "11", "12"]
python_version: ["9", "10", "11", "12"]

steps:
- name: Checkout repository
Expand All @@ -60,7 +89,6 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: |
3.8
3.9
3.10
3.11
Expand Down Expand Up @@ -100,9 +128,8 @@ jobs:
--python-version 3.${{ matrix.python_version }}
--python-platform ${{ matrix.platform }}
-c constraints.txt
--extra=gpu
--emit-index-url
--index-url https://pypi.spfluo.ovh/jean/dev-pytorch-cu124/+simple/ # pytorch is in the deps of spfluo-app[gpu], so we need a custom index
--index-url https://pypi.spfluo.ovh/jean/dev-pytorch-cu124/+simple/ # torch is in the deps we need a custom index to enable CUDA
- name: Append to requirements spfluo-app
run: |
Expand Down
32 changes: 0 additions & 32 deletions packages/napari-bbox/.github/workflows/devpi.yaml

This file was deleted.

32 changes: 0 additions & 32 deletions packages/napari-spfluo/.github/workflows/devpi.yaml

This file was deleted.

1 change: 1 addition & 0 deletions packages/napari-spfluo/hatch.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[version]
source = "vcs"
raw-options = { root = "../.." }

[build.hooks.vcs]
version-file = "src/napari_spfluo/_version.py"
Expand Down
4 changes: 2 additions & 2 deletions packages/napari-spfluo/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "hatchling.build"

[project]
name = "napari-spfluo"
version = "0.0.1"
dynamic = ["version"]
description = "A plugin to use spfluo within napari"
readme = "README.md"
license = "MIT"
Expand Down Expand Up @@ -59,4 +59,4 @@ line-length = 79
target-version = ['py39', 'py310', 'py311']

[tool.uv.sources]
spfluo = {workspace = true}
spfluo = {path = "../spfluo"}
32 changes: 0 additions & 32 deletions packages/scipion-app/.github/workflows/devpi.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion packages/scipion-app/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ guiplugin = "scipion.guiplugin"
"scipion" = ["templates/*.template", "templates/*.json"]

[tool.uv.sources]
scipion-fluo = {workspace = true}
scipion-fluo = {path = "../scipion-fluo"}
38 changes: 0 additions & 38 deletions packages/scipion-fluo-singleparticle/.github/workflows/devpi.yaml

This file was deleted.

3 changes: 3 additions & 0 deletions packages/scipion-fluo-singleparticle/hatch.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
[version]
source = "vcs"
raw-options = { root = "../.." }

[build.targets.sdist]
exclude = [
"/.github",
"/.gitignore",
"/.pre-commit-config.yaml",
]

[build.targets.wheel]
Expand Down
10 changes: 5 additions & 5 deletions packages/scipion-fluo-singleparticle/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ description = "Scipion plugin for single particle reconstruction."
readme = "README.rst"
authors = [{name = "Jean Plumail", email = "[email protected]"}]
keywords = ["scipion", "fluorescence", "imageprocessing", "scipion-3.0"]
version = "0.0.1"
dynamic = ["version"]
dependencies = [
"scipion-pyworkflow",
"scipion-fluo",
Expand All @@ -27,7 +27,7 @@ Repository = "https://github.com/jplumail/scipion-fluo-singleparticle"
singleparticle = "singleparticle"

[tool.uv.sources]
scipion-pyworkflow = {workspace=true}
scipion-fluo = {workspace=true}
spfluo = {workspace=true}
napari-spfluo = {workspace=true}
scipion-pyworkflow = {path="../scipion-pyworkflow"}
scipion-fluo = {path="../scipion-fluo"}
spfluo = {path="../spfluo"}
napari-spfluo = {path="../napari-spfluo"}
32 changes: 0 additions & 32 deletions packages/scipion-fluo/.github/workflows/devpi.yaml

This file was deleted.

1 change: 1 addition & 0 deletions packages/scipion-fluo/hatch.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ metadata.allow-direct-references = true

[version]
source = "vcs"
raw-options = { root = "../.." }

[build.targets.wheel]
packages = ["pwfluo"]
Expand Down
4 changes: 2 additions & 2 deletions packages/scipion-fluo/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build-backend = "hatchling.build"

[project]
name = "scipion-fluo"
version = "0.0.1"
dynamic = ["version"]
requires-python = ">=3.8"
description = "Base pyworkflow plugin for Fluorescence image processing"
readme = "README.rst"
Expand Down Expand Up @@ -35,4 +35,4 @@ scipion-fluo = "pwfluo.__main__:main"
pwfluo = "pwfluo"

[tool.uv.sources]
scipion-pyworkflow = {workspace = true}
scipion-pyworkflow = {path = "../scipion-pyworkflow"}
32 changes: 0 additions & 32 deletions packages/scipion-pyworkflow/.github/workflows/devpi.yaml

This file was deleted.

Loading

0 comments on commit d55a109

Please sign in to comment.