mirror of
https://github.com/khoj-ai/khoj.git
synced 2024-11-27 17:35:07 +01:00
Check wheel contents in workflow before publishing it to PyPI
This commit is contained in:
parent
25a749ca1d
commit
f83cf4ebc6
1 changed files with 19 additions and 4 deletions
23
.github/workflows/publish.yml
vendored
23
.github/workflows/publish.yml
vendored
|
@ -33,7 +33,7 @@ jobs:
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pip
|
python -m pip install --upgrade pip
|
||||||
pip install build twine
|
pip install build twine check-wheel-contents
|
||||||
|
|
||||||
- name: Install Application
|
- name: Install Application
|
||||||
run: |
|
run: |
|
||||||
|
@ -49,10 +49,15 @@ jobs:
|
||||||
export PYTHONHASHSEED=42
|
export PYTHONHASHSEED=42
|
||||||
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
||||||
|
|
||||||
# Build and Upload PyPi Package
|
# Build PyPi Package
|
||||||
rm -rf dist
|
rm -rf dist
|
||||||
python -m build
|
python -m build
|
||||||
|
|
||||||
|
# Validate PyPi Package
|
||||||
|
check-wheel-contents dist/*.whl
|
||||||
twine check dist/*
|
twine check dist/*
|
||||||
|
|
||||||
|
# Upload PyPi Package
|
||||||
twine upload --verbose dist/*
|
twine upload --verbose dist/*
|
||||||
|
|
||||||
- name: Publish Master to PyPI
|
- name: Publish Master to PyPI
|
||||||
|
@ -68,10 +73,15 @@ jobs:
|
||||||
export PYTHONHASHSEED=42
|
export PYTHONHASHSEED=42
|
||||||
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
||||||
|
|
||||||
# Build and Upload PyPi Package
|
# Build PyPi Package
|
||||||
rm -rf dist
|
rm -rf dist
|
||||||
python -m build
|
python -m build
|
||||||
|
|
||||||
|
# Validate PyPi Package
|
||||||
|
check-wheel-contents dist/*.whl
|
||||||
twine check dist/*
|
twine check dist/*
|
||||||
|
|
||||||
|
# Upload PyPi Package
|
||||||
twine upload --verbose dist/*
|
twine upload --verbose dist/*
|
||||||
|
|
||||||
- name: Publish Repo PR to Test PyPI
|
- name: Publish Repo PR to Test PyPI
|
||||||
|
@ -88,8 +98,13 @@ jobs:
|
||||||
export PYTHONHASHSEED=42
|
export PYTHONHASHSEED=42
|
||||||
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
||||||
|
|
||||||
# Build and Upload PyPi Package
|
# Build PyPi Package
|
||||||
rm -rf dist
|
rm -rf dist
|
||||||
python -m build
|
python -m build
|
||||||
|
|
||||||
|
# Validate PyPi Package
|
||||||
|
check-wheel-contents dist/*.whl
|
||||||
twine check dist/*
|
twine check dist/*
|
||||||
|
|
||||||
|
# Upload PyPi Package
|
||||||
twine upload -r testpypi --verbose dist/*
|
twine upload -r testpypi --verbose dist/*
|
Loading…
Reference in a new issue