Skip to content

Commit

Permalink
Add venv setup on ci
Browse files Browse the repository at this point in the history
  • Loading branch information
sukso96100 committed Oct 20, 2024
1 parent a3aa110 commit b39fb93
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ name: CI

env:
PYTHON_VERSION: '3.12'
UV_SYSTEM_PYTHON: 1

on:
push:
Expand Down Expand Up @@ -36,6 +35,13 @@ jobs:

- name: Set up Python
run: uv python install ${{ env.PYTHON_VERSION }}

- name: Setup and Activate virtualenv
run: |
uv venv venv --python ${{ env.PYTHON_VERSION }}
source venv/bin/activate
echo "VIRTUAL_ENV=$(pwd)/.venv" >> $GITHUB_ENV
echo "$(pwd)/.venv/bin" >> $GITHUB_PATH
- name: Install system dependencies
run: sudo apt-get install postgresql-client libpq-dev redis-server
Expand Down Expand Up @@ -89,6 +95,13 @@ jobs:

- name: Set up Python
run: uv python install ${{ env.PYTHON_VERSION }}

- name: Setup and Activate virtualenv
run: |
uv venv venv --python ${{ env.PYTHON_VERSION }}
source venv/bin/activate
echo "VIRTUAL_ENV=$(pwd)/.venv" >> $GITHUB_ENV
echo "$(pwd)/.venv/bin" >> $GITHUB_PATH
- name: Install system dependencies
run: sudo apt-get install postgresql-client libpq-dev redis-server
Expand Down

0 comments on commit b39fb93

Please sign in to comment.