Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 21 additions & 12 deletions .github/workflows/cont_int.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ on:
schedule:
- cron: '0 0 * * *'

env:
RMG_PY_COMMIT: 55464c54d1fa61b531e865682df598d33718597d

jobs:
build:
Expand All @@ -37,22 +39,28 @@ jobs:
- name: Cache RMG-Py
id: cache-rmg-py
uses: actions/cache@v3
env:
CACHE_NUMBER: 2
with:
path: RMG-Py
key: ${{ runner.os }}-rmg-main
key: ${{ runner.os }}-rmg-${{ env.RMG_PY_COMMIT }}
restore-keys: |
${{ runner.os }}-rmg-

- name: Checkout RMG-py
# - name: Checkout RMG-Py at specific commit
# if: steps.cache-rmg-py.outputs.cache-hit != 'true'
# uses: actions/checkout@v3
# with:
# repository: ReactionMechanismGenerator/RMG-Py
# path: RMG-Py
# ref: ${{ env.RMG_PY_COMMIT }}^1
# fetch-depth: 0

- name: Clone & checkout RMG-Py at specific SHA
if: steps.cache-rmg-py.outputs.cache-hit != 'true'
uses: actions/checkout@v3
with:
repository: ReactionMechanismGenerator/RMG-Py
path: RMG-Py
ref: main
fetch-depth: 1
run: |
git clone --filter=blob:none --no-checkout https://github.com/ReactionMechanismGenerator/RMG-Py.git RMG-Py
cd RMG-Py
git fetch --no-tags --prune origin ${RMG_PY_COMMIT}
git checkout --detach ${RMG_PY_COMMIT}

- name: Cache RMG-database
id: cache-rmg-db
Expand All @@ -64,14 +72,15 @@ jobs:
key: ${{ runner.os }}-rmgdb-main
restore-keys: |
${{ runner.os }}-rmgdb-

- name: Checkout RMG-database
if: steps.cache-rmg-db.outputs.cache-hit != 'true'
uses: actions/checkout@v3
with:
repository: ReactionMechanismGenerator/RMG-database
path: RMG-database
ref: main
fetch-depth: 1
fetch-depth: 0

- name: Cache AutoTST
id: cache-autotst
Expand Down Expand Up @@ -135,7 +144,7 @@ jobs:
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.yml') }}

- name: Set up miniconda
uses: conda-incubator/setup-miniconda@v3
uses: conda-incubator/setup-miniconda@v3.2.0
with:
auto-update-conda: true
environment-file: environment.yml
Expand Down
176 changes: 92 additions & 84 deletions .github/workflows/update-cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,128 +2,136 @@ name: Update cache

on:
schedule:
- cron: "0 0 */7 * *"
- cron: '0 0 */7 * *'
push:
branches:
- main
branches: [ main ]

jobs:
update_cache:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
shell: bash -el {0}

steps:
# ────────── source repo ──────────
- name: Checkout ARC
uses: actions/checkout@v3

uses: actions/checkout@v4

# ────────── RMG‑Py ──────────
- name: Cache RMG
id: cache-rmg
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: RMG-Py
key: ${{ runner.os }}-rmg-main

- name: Checkout RMG
uses: actions/checkout@v3
path: RMG-Py
key: ${{ runner.os }}-rmg-main
restore-keys: |
${{ runner.os }}-rmg-
- name: Checkout RMG-Py
if: steps.cache-rmg.outputs.cache-hit != 'true'
uses: actions/checkout@v4
with:
repository: ReactionMechanismGenerator/RMG-Py
path: RMG-Py
ref: main
fetch-depth: 1
repository: ReactionMechanismGenerator/RMG-Py
path: RMG-Py
ref: 55464c54d1fa61b531e865682df598d33718597d
fetch-depth: 1

# ────────── RMG‑database ──────────
- name: Cache RMG-database
id: cache-rmg-db
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: RMG-database
key: ${{ runner.os }}-rmgdb-main

path: RMG-database
key: ${{ runner.os }}-rmgdb-main
restore-keys: |
${{ runner.os }}-rmgdb-
- name: Checkout RMG-database
uses: actions/checkout@v3
if: steps.cache-rmg-db.outputs.cache-hit != 'true'
uses: actions/checkout@v4
with:
repository: ReactionMechanismGenerator/RMG-database
path: RMG-database
ref: main
fetch-depth: 1

repository: ReactionMechanismGenerator/RMG-database
path: RMG-database
ref: main
fetch-depth: 1

# ────────── AutoTST ──────────
- name: Cache AutoTST
id: cache-autotst
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: AutoTST
key: ${{ runner.os }}-autotst-main
restore-keys: |
${{ runner.os }}-autotst-
path: AutoTST
key: ${{ runner.os }}-autotst-main
restore-keys: |
${{ runner.os }}-autotst-
- name: Checkout AutoTST
if: steps.cache-autotst.outputs.cache-hit != 'true'
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ReactionMechanismGenerator/AutoTST
path: AutoTST
ref: main
fetch-depth: 1

repository: ReactionMechanismGenerator/AutoTST
path: AutoTST
ref: main
fetch-depth: 1

# ────────── TS‑GCN ──────────
- name: Cache TS-GCN
id: cache-tsgcn
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: TS-GCN
key: ${{ runner.os }}-tsgcn-main
restore-keys: |
${{ runner.os }}-tsgcn-
path: TS-GCN
key: ${{ runner.os }}-tsgcn-main
restore-keys: |
${{ runner.os }}-tsgcn-
- name: Checkout TS-GCN
if: steps.cache-tsgcn.outputs.cache-hit != 'true'
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ReactionMechanismGenerator/TS-GCN
path: TS-GCN
ref: main
fetch-depth: 1

repository: ReactionMechanismGenerator/TS-GCN
path: TS-GCN
ref: main
fetch-depth: 1

# ────────── KinBot ──────────
- name: Cache KinBot
id: cache-kinbot
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: KinBot
key: ${{ runner.os }}-kinbot-2.0.6
restore-keys: |
${{ runner.os }}-kinbot-

- name: Checkout Kinbot 2.0.6
path: KinBot
key: ${{ runner.os }}-kinbot-2.0.6
restore-keys: |
${{ runner.os }}-kinbot-
- name: Checkout KinBot 2.0.6
if: steps.cache-kinbot.outputs.cache-hit != 'true'
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: zadorlab/KinBot
path: KinBot
ref: v2.0.6
fetch-depth: 1
- name: Cache Packages Packages
uses: actions/cache@v2
env:
CACHE_NUMBER: 0
repository: zadorlab/KinBot
path: KinBot
ref: v2.0.6
fetch-depth: 1

# ────────── Conda package cache ──────────
- name: Cache Conda packages
id: cache-conda-pkgs
uses: actions/cache@v4
with:
path: ~/conda_pkgs_dir
key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.yml') }}
path: ~/conda_pkgs_dir
key: ${{ runner.os }}-conda-0-${{ hashFiles('environment.yml') }}

# ────────── Create / restore env ──────────
- name: Setup ARC Env
uses: conda-incubator/setup-miniconda@v3
uses: conda-incubator/setup-miniconda@v3.2.0
with:
auto-update-conda: true
environment-file: environment.yml
activate-environment: arc_env
miniconda-version: latest
conda-solver: libmamba

auto-update-conda: true
environment-file: environment.yml
activate-environment: arc_env
miniconda-version: latest
conda-solver: libmamba

# ────────── Update env & save to cache ──────────
- name: Update environment
run: mamba env update -n arc_env -f environment.yml

- name: Cache ARC env
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ${{ env.CONDA }}/envs
key: conda-${{ runner.os }}--${{ runner.arch }}--${{ env.CACHE_NUMBER}}
env:
# Increase this value to reset cache if etc/example-environment.yml has not changed
CACHE_NUMBER: 0
id: cache-arc-env
- name: Update environment
run: conda env update -n arc_env -f environment.yml
if: steps.cache-arc-env.outputs.cache-hit != 'true'
path: ${{ env.CONDA }}/envs
key: conda-${{ runner.os }}-${{ runner.arch }}-0
Loading
Loading