Package: scriptloc 1.0.0

scriptloc: Get the Location of the R Script that is Being Sourced/Executed

Provides functions to retrieve the location of R scripts loaded through the source() function or run from the command line using the Rscript command. This functionality is analogous to the Bash shell's ${BASH_SOURCE[0]}. Users can first set the project root's path relative to the script path and then all subsequent paths relative to the root. This system ensures that all paths lead to the same location regardless of where any script is executed/loaded from without resorting to the use of setwd() at the top of the scripts.

Authors:Naren Chandran Sakthivel [aut, cre]

scriptloc_1.0.0.tar.gz
scriptloc_1.0.0.zip(r-4.5)scriptloc_1.0.0.zip(r-4.4)scriptloc_1.0.0.zip(r-4.3)
scriptloc_1.0.0.tgz(r-4.4-any)scriptloc_1.0.0.tgz(r-4.3-any)
scriptloc_1.0.0.tar.gz(r-4.5-noble)scriptloc_1.0.0.tar.gz(r-4.4-noble)
scriptloc_1.0.0.tgz(r-4.4-emscripten)scriptloc_1.0.0.tgz(r-4.3-emscripten)
scriptloc.pdf |scriptloc.html
scriptloc/json (API)

# Install 'scriptloc' in R:
install.packages('scriptloc', repos = c('https://narenschandran.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

On CRAN:

This package does not link to any Github/Gitlab/R-forge repository. No issue tracker or development information is available.

2.70 score 6 scripts 128 downloads 2 exports 0 dependencies

Last updated 1 years agofrom:92b3354615. Checks:OK: 3 NOTE: 4. Indexed: yes.

TargetResultDate
Doc / VignettesOKOct 11 2024
R-4.5-winNOTEOct 11 2024
R-4.5-linuxNOTEOct 11 2024
R-4.4-winNOTEOct 11 2024
R-4.4-macNOTEOct 11 2024
R-4.3-winOKOct 11 2024
R-4.3-macOKOct 11 2024

Exports:script_dir_getscriptloc

Dependencies:

scriptloc

Rendered fromscriptloc.Rmdusingknitr::rmarkdownon Oct 11 2024.

Last update: 2023-08-17
Started: 2023-08-17