Skip to content

Commit 4546704

Browse files
committed
qdui: release.yml includes poetry build and publish for quantinuum-sphinx
1 parent 8a931a0 commit 4546704

1 file changed

Lines changed: 15 additions & 5 deletions

File tree

.github/workflows/release.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,18 +32,16 @@ jobs:
3232

3333
release_pypi:
3434
runs-on: ubuntu-latest
35+
needs: release_node
3536
steps:
3637
- uses: actions/checkout@v4
3738
- name: Set up Python
3839
uses: actions/setup-python@v5
3940
with:
4041
python-version: "3.12"
41-
- name: Install dependencies
42+
- name: Generate UI Assets
4243
run: |
4344
cd sphinx-ui
44-
rm -rf ./dist
45-
mkdir ./dist
46-
cp -a quantinuum_sphinx/. dist/
4745
echo "🔨 Generating UI assets..."
4846
cd ./react
4947
npm update @quantinuum/documentation-ui
@@ -53,5 +51,17 @@ jobs:
5351
cp ./build/syncTheme.global.js ../quantinuum_sphinx/static/syncTheme.global.js
5452
cp ./node_modules/@quantinuum/quantinuum-ui/dist/tokens.css ../quantinuum_sphinx/static/styles/quantinuum-ui-tokens.css
5553
npx tailwindcss --postcss ./postcss.config.cjs -i ./index.css -o ../quantinuum_sphinx/static/styles/quantinuum-ui-tailwind.css
56-
echo ✅ "Done. Added UI assets to dist."
54+
echo ✅ "Done. Generated UI assets."
55+
- name: Build and Publish to PyPI
56+
env:
57+
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
58+
PYPI_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
59+
run: |
60+
echo "📦 Building and publishing to PyPI..."
61+
mkdir ./dist
62+
cp -a quantinuum_sphinx/. dist/
63+
poetry config http-basic.pypi_local ${{ secrets.PYPI_USERNAME }} ${{ secrets.PYPI_API_TOKEN }}
64+
poetry build
65+
poetry publish
66+
echo ✅ "Done. Published Package to PyPI."
5767

0 commit comments

Comments
 (0)