-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add python initialization and dependency install to CI
- Loading branch information
r.jaepel
committed
Oct 23, 2023
1 parent
449138f
commit 91b4621
Showing
1 changed file
with
30 additions
and
4 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,38 @@ | ||
on: push | ||
on: | ||
push: | ||
branches: | ||
- dev | ||
- test-ci | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
python ./workshop_git_tools/process_repo.py | ||
git commit -m "generated" | ||
git push | ||
- name: Cache conda | ||
uses: actions/cache@v3 | ||
env: | ||
# Increase this value to reset cache if etc/example-environment.yml has not changed | ||
CACHE_NUMBER: 2 | ||
with: | ||
path: ~/conda_pkgs_dir | ||
key: | ||
Ubuntu-python_3.10-${{ env.CACHE_NUMBER }}-${{ hashFiles('etc/example-environment.yml') }} | ||
- uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
python-version: '3.10' | ||
miniforge-variant: Mambaforge | ||
use-mamba: true | ||
auto-update-conda: true | ||
channels: conda-forge | ||
auto-activate-base: false | ||
environment-file: environment.yml | ||
activate-environment: cadet_workshop | ||
- name: Generate teaching and solution branches | ||
run: | | ||
python ./workshop_git_tools/process_repo.py --commit --push |