Compare commits
6 Commits
test-tag
...
test-docu-
| Author | SHA1 | Date | |
|---|---|---|---|
| eb40e352fb | |||
| d19954bb4c | |||
| 662ccd1fc3 | |||
| eb429cf014 | |||
| 6cd2ad4f9e | |||
| e046384d78 |
@@ -4,6 +4,8 @@ on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
tags:
|
||||
- '**'
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
@@ -50,6 +52,11 @@ jobs:
|
||||
else
|
||||
echo "No packages found to move"
|
||||
fi
|
||||
- name: Upload documentation
|
||||
if: github.ref_type == 'tag'
|
||||
shell: bash
|
||||
run: |
|
||||
|
||||
python-client:
|
||||
name: Generate python client
|
||||
runs-on: jfjoch_rocky8
|
||||
@@ -58,6 +65,16 @@ jobs:
|
||||
- name: Build python client
|
||||
shell: bash
|
||||
run: bash gen_python_client.sh
|
||||
- name: Upload Package to Gitea PyPI
|
||||
if: github.ref_type == 'tag'
|
||||
env:
|
||||
TWINE_USERNAME: "__token__" # Username for Twine when using token-based auth
|
||||
TWINE_PASSWORD: ${{ secrets.PIP_REPOSITORY_API_TOKEN }} # Use the secret for authentication
|
||||
run: |
|
||||
python3 -m venv .twine
|
||||
source .twine/bin/activate
|
||||
pip3 install twine
|
||||
twine upload --repository-url https://gitea.psi.ch/api/packages/mx/pypi dist/*
|
||||
documentation:
|
||||
name: Build documentation
|
||||
runs-on: jfjoch_rocky8
|
||||
@@ -66,20 +83,24 @@ jobs:
|
||||
- name: Build documentation
|
||||
shell: bash
|
||||
run: bash make_doc.sh
|
||||
- name: Tag-only step
|
||||
- name: Upload documentation
|
||||
if: github.ref_type == 'tag'
|
||||
shell: bash
|
||||
run: echo "This runs only when the workflow is triggered by a tag"
|
||||
gpu-test:
|
||||
name: GPU test
|
||||
runs-on: jfjoch_rocky8
|
||||
container:
|
||||
image: gitea.psi.ch/leonarski_f/jfjoch_rocky8:2509
|
||||
options: --gpus all
|
||||
steps:
|
||||
- name: List GPUs
|
||||
shell: bash
|
||||
run: nvidia-smi
|
||||
run: |
|
||||
git config --global user.email "filip.leonarski@psi.ch"
|
||||
git config --global user.name "Filip Leonarski (Gitea)"
|
||||
git checkout --orphan gitea-pages
|
||||
git reset --hard
|
||||
# Remove everything except .git and public
|
||||
git clean -fdx -e public -e .git
|
||||
|
||||
# Move public contents to root and remove the now-empty public dir
|
||||
shopt -s dotglob nullglob
|
||||
mv public/* .
|
||||
rm -rf public
|
||||
git add .
|
||||
git commit -m "Deploy site"
|
||||
git push -f https://${{secrets.GITHUB_TOKEN}}@gitea.psi.ch/${{ github.repository }}.git gitea-pages
|
||||
unit-tests:
|
||||
name: Unit tests
|
||||
runs-on: jfjoch_rocky8
|
||||
|
||||
@@ -8,4 +8,3 @@ java -jar openapi-generator-cli.jar generate -i broker/jfjoch_api.yaml -o python
|
||||
cd python-client
|
||||
sed -i s/"NAME = \"jfjoch-client\""/"NAME = \"jfjoch_client\""/ setup.py
|
||||
python3 setup.py sdist bdist_wheel
|
||||
mv dist/* ..
|
||||
Reference in New Issue
Block a user