generated from nmfs-opensci/NOAA-quarto-simple
-
Notifications
You must be signed in to change notification settings - Fork 3
38 lines (29 loc) · 1.19 KB
/
run-pollock-tests-by-fleet.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Run pollock tests (by fleet)
on:
workflow_dispatch:
push:
jobs:
build-deploy:
runs-on: macos-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Check out repository
uses: actions/checkout@v2
- name: Set up R (needed for Rmd)
uses: r-lib/actions/setup-r@v2
- name: Run pollock tests
run: |
# Names of required packages
packages <- c("dplyr", "tidyr", "ggplot2", "TMB", "reshape2", "here", "devtools", "lubridate")
# Install packages not yet installed
installed_packages <- packages %in% rownames(installed.packages())
if (any(installed_packages == FALSE)) {
install.packages(packages[!installed_packages], repos = "http://cran.us.r-project.org")
}
# install.packages("FIMS", repos = c("https://noaa-fims.r-universe.dev", "https://cloud.r-project.org"))
devtools::install_github("NOAA-FIMS/FIMS")
# Load packages
invisible(lapply(packages, library, character.only = TRUE))
source(file.path(getwd(), "content", "run_pollock_tests_by_fleet.R"))
shell: Rscript {0}