dr_here() shows a message that by default also includes the reason why here() is set to a particular directory. Use this function if here() gives unexpected results.

dr_here(show_reason = TRUE)

Arguments

show_reason

[logical(1)]
Include reason in output of dr_here(), defaults to TRUE.

Examples

dr_here()
#> here() starts at /cluster-data/user-homes/elizabethb/projects/prism-pkgdocs-build.
#> - This directory contains a directory '.git'
#> - Initial working directory: /cluster-data/user-homes/elizabethb/projects/prism-pkgdocs-build
#> - Current working directory: /cluster-data/user-homes/elizabethb/projects/prism-pkgdocs-build/installed-pkgs/2025-09-15/here_1.0.2/docs/reference