shpc update docs #1034
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: shpc update docs | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 2 * * *' | |
push: | |
branches: [main] | |
jobs: | |
generate-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: "gh-pages" | |
- name: Create conda environment | |
run: conda create --quiet -c conda-forge --name shpc spython | |
- name: Check out main | |
uses: "actions/checkout@v3" | |
with: | |
ref: "main" | |
path: "tmp-registry" | |
- name: Install shpc | |
run: | | |
export PATH="/usr/share/miniconda/bin:$PATH" | |
source activate shpc | |
pip install git+https://github.com/singularityhub/singularity-hpc@main | |
pip install setuptools | |
- name: Generate docs | |
run: | | |
export PATH="/usr/share/miniconda/bin:$PATH" | |
source activate shpc | |
mkdir -p _library | |
/bin/bash generate.sh ./tmp-registry | |
git add _library/* | |
rm -r tmp-registry | |
- name: Deploy 🚀 | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: gh-pages | |
folder: . |