cicd - bump #102
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 0.6.0 - Prepare, Install, Validate | |
on: | |
push: | |
branches: [ "mono/0.6.0.dev1" ] | |
jobs: | |
install-prepare-validate: | |
runs-on: ubuntu-latest | |
env: | |
UNIQUE_VENV_PATH: "${{ github.workspace }}/.venv_core_${{ github.run_id }}" | |
steps: | |
# 1. Check out the repository | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
# 2. Set up Python | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Create and Activate Virtual Environment | |
run: | | |
python -m venv $UNIQUE_VENV_PATH | |
source $UNIQUE_VENV_PATH/bin/activate | |
# 3. Install project dependencies via Poetry | |
- name: Install dependencies | |
run: | | |
source $UNIQUE_VENV_PATH/bin/activate | |
python -m pip install --upgrade pip | |
pip install poetry | |
pip install soliloquy=="0.1.3.dev6" | |
## This will create one lock file | |
# - name: Poetry Lock Regenerate | |
# run: | | |
# source $UNIQUE_VENV_PATH/bin/activate | |
# cd pkgs | |
# poetry lock --regenerate | |
# 4. Run the install phase | |
## This will create one lock file | |
## If we want to create a lock file per folder then we use "recursive" | |
- name: Run install phase | |
run: | | |
source $UNIQUE_VENV_PATH/bin/activate | |
cd pkgs | |
soliloquy install --file pyproject.toml | |
- name: Pip freeze | |
run: | | |
source $UNIQUE_VENV_PATH/bin/activate | |
pip freeze | |
# 5. Run the prepare phase | |
- name: Run prepare phase | |
run: | | |
source $UNIQUE_VENV_PATH/bin/activate | |
git config user.name "github-actions[bot]" | |
git config user.email "github-actions[bot]@users.noreply.github.com" | |
cd pkgs | |
soliloquy prepare --directory . --recursive --bump patch --commit-msg "chore: auto prepare" | |
# 6. Run the validate phase | |
- name: Run validate phase | |
run: | | |
source $UNIQUE_VENV_PATH/bin/activate | |
cd pkgs | |
soliloquy validate --file pyproject.toml --test-mode each --num-workers 4 |