Skip to content

Commit

Permalink
temp test
Browse files Browse the repository at this point in the history
  • Loading branch information
Oscilloscope98 committed Jun 11, 2024
1 parent d0bb383 commit ed284b2
Showing 1 changed file with 21 additions and 8 deletions.
29 changes: 21 additions & 8 deletions .github/workflows/publish_sub_package.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
name: Publish Sub-Package to PyPI if Needed

on:
push:
branches:
- main
pull_request:
branches: [main, ipex-llm-gpu-dependency-windows-update]
paths:
- "llama-index-integrations/**"

env:
POETRY_VERSION: "1.6.1"
PYTHON_VERSION: "3.10"

jobs:
publish_subpackage_if_needed:
if: github.repository == 'run-llama/llama_index'
# if: github.repository == 'run-llama/llama_index'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand All @@ -29,15 +32,25 @@ jobs:
id: changed-files
run: |
echo "changed_files=$(git diff --name-only ${{ github.event.before }} ${{ github.event.after }} | grep -v llama-index-core | grep llama-index | grep pyproject | xargs)" >> $GITHUB_OUTPUT
- name: Publish changed packages
env:
PYPI_TOKEN: ${{ secrets.LLAMA_INDEX_PYPI_TOKEN }}
- name: Publish changed packages (llm)
# env:
# PYPI_TOKEN: ${{ secrets.LLAMA_INDEX_PYPI_TOKEN }}
run: |
for file in llama-index-integrations/llms/llama-index-llms-ipex-llm/pyproject.toml; do
cd `echo $file | sed 's/\/pyproject.toml//g'`
poetry lock
pip install -e .
poetry publish --build --dry-run
cd -
done
- name: Publish changed packages (embedding)
# env:
# PYPI_TOKEN: ${{ secrets.LLAMA_INDEX_PYPI_TOKEN }}
run: |
for file in ${{ steps.changed-files.outputs.changed_files }}; do
for file in llama-index-integrations/embeddings/llama-index-embeddings-ipex-llm/pyproject.toml; do
cd `echo $file | sed 's/\/pyproject.toml//g'`
poetry lock
pip install -e .
poetry config pypi-token.pypi $PYPI_TOKEN
poetry publish --build
poetry publish --build --dry-run
cd -
done

0 comments on commit ed284b2

Please sign in to comment.