Skip to content

Commit

Permalink
WIP: Initial version of shared setup script (not used yet)
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyMcCormick committed Aug 7, 2024
1 parent 05c480c commit 588a688
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/setup.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Setup CI environment

on:
workflow_call:
inputs:
ignore_errors:
description: "Flag to ignore errors"
required: false
default: false
type: boolean

jobs:

setup:

runs-on: ubuntu-latest

steps:
- name: Check out repo
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: "pip"

- name: Install dependencies
run: |
python -m pip install --upgrade pip uv
uv pip install --system -r requirements.txt
- name: Set error flag
run: |
if [ "${{ inputs.ignore_errors }}" = "true" ]; then
echo "Errors will be ignored"
set +e
else
echo "Errors will not be ignored"
set -e
fi

0 comments on commit 588a688

Please sign in to comment.