Files
galaxy/.github/workflows/publish_artifacts.yaml
T
dependabot[bot] 4f491d6628 Bump actions/setup-python from 5 to 6
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5 to 6.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-23 21:22:20 +00:00

56 lines
1.9 KiB
YAML

name: Publish release artifacts
on:
release:
types: [released, prereleased]
jobs:
build-and-publish-pypi:
if: github.repository_owner == 'galaxyproject'
name: Build and Publish to PyPI
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.9']
steps:
- uses: actions/checkout@v5
with:
persist-credentials: false
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install script dependencies
run: pip install galaxy-release-util
- name: Build and publish to PyPI
run: |
galaxy-release-util build-and-upload --no-confirm
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ github.event.release.prerelease && secrets.PYPI_TEST_TOKEN || secrets.PYPI_MAIN_TOKEN }}
TWINE_REPOSITORY_URL: ${{ github.event.release.prerelease && 'https://test.pypi.org/legacy/' || 'https://upload.pypi.org/legacy/' }}
build-and-publish-npm:
if: github.repository_owner == 'galaxyproject'
name: Build and Publish to NPM
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/checkout@v5
- name: Read Node.js version
id: node-version
run: echo "version=$(cat client/.node_version)" >> $GITHUB_OUTPUT
- uses: actions/setup-node@v5
with:
node-version: ${{ steps.node-version.outputs.version }}
cache: 'yarn'
cache-dependency-path: 'client/yarn.lock'
registry-url: 'https://registry.npmjs.org'
- name: build client
run: yarn && yarn build-production
working-directory: 'client'
- name: publish client
if: "!github.event.release.prerelease"
run: npm publish --provenance --access public
working-directory: 'client'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}