-
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.
adapted normal preprocessing workflow to work with docker
- Loading branch information
1 parent
21fb16a
commit 5770593
Showing
1 changed file
with
9 additions
and
39 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 |
---|---|---|
|
@@ -11,10 +11,14 @@ on: | |
jobs: | ||
preprocess: | ||
name: Preprocess raw data | ||
# NOTE: on windows as computing of descriptors has a bug on linux right now | ||
runs-on: windows-2019 | ||
env: | ||
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} # needed for pulling R packages from github | ||
runs-on: ubuntu-latest | ||
container: | ||
image: ghcr.io/${{ github.actor }}/repo_rt_preprocessing:latest | ||
env: | ||
RENV_PATHS_LIBRARY: '/renv/library' | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- name: Checkout fork repository | ||
|
@@ -36,46 +40,11 @@ jobs: | |
run: echo "files=$(for f in ${{ steps.files.outputs.all }}; do basename $(dirname $f); done | grep -E '^[0-9]+$' | sort | uniq | tr '\n' ' ')" >> $GITHUB_OUTPUT | ||
|
||
- name: List all added files | ||
shell: bash {0} | ||
run: | | ||
for f in ${{ steps.filesfolders.outputs.files }}; do | ||
ls -lh raw_data/$f | ||
done | ||
- name: Pyton dependencies | ||
run: pip install -r scripts/Python/requirements.txt | ||
|
||
- name: Setup java | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: 'temurin' | ||
java-version: '17' | ||
|
||
- name: Set RENV_PATHS_ROOT | ||
shell: bash | ||
run: | | ||
echo "RENV_PATHS_ROOT=${{ runner.temp }}/renv" >> $GITHUB_ENV | ||
- name: Setup R | ||
uses: r-lib/actions/setup-r@v2 | ||
with: | ||
use-public-rspm: true | ||
r-version: 4.2.2 | ||
|
||
- name: Restore Renv package cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.RENV_PATHS_ROOT }} | ||
key: ${{ runner.os }}-renv-${{ hashFiles('**/renv.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-renv- | ||
- name: Activate renv | ||
shell: Rscript {0} | ||
run: | | ||
options(renv.config.mran.enabled = FALSE) | ||
renv::restore() | ||
- name: Standardize compounds | ||
run: Rscript scripts/R_ci/compounds_standardize.R ${{ steps.filesfolders.outputs.files }} | ||
|
||
|
@@ -117,6 +86,7 @@ jobs: | |
run: | | ||
git config --global user.email '[email protected]' | ||
git config --global user.name 'Github Actions' | ||
git config --global safe.directory '*' | ||
# Use LFS storage of main repository: no push access to fork LFS storage | ||
# TODO: change once repository is moved | ||
git config lfs.url 'https://github.com/f-kretschmer/pr_test_repo.git/info/lfs' | ||
|