Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save curiositycasualty/ac89fb070cd042c88dae7c70839f4b8c to your computer and use it in GitHub Desktop.
Save curiositycasualty/ac89fb070cd042c88dae7c70839f4b8c to your computer and use it in GitHub Desktop.
#{package_vector},
Ncpus = #{new_resource.ncpus},
repos = c("CRAN" = "#{new_resource.cran_repo}"),
clean = #{new_resource.clean.to_s.upcase},
destdir = "#{new_resource.destdir}",
keep_outputs = TRUE,
method = "wget",
extra = " >/dev/null 2>&1 || true;
cd #{new_resource.destdir};
__wget() {
if echo $1 | grep -qs '.tar.gz'; then
wget \
--no-verbose \
--timestamping \
--no-if-modified-since \
$1 || true;
else
wget $1 $2 $3 $4 $5 $6 $7 $8;
fi;
};
__wget "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment