Skip to contents

Searches upward from start for a directory containing the current Sphinx/package-root markers, while still tolerating legacy Quarto-era markers in older checkouts.

Usage

morie_find_project_root(start = getwd(), max_up = 10L)

Arguments

start

Starting directory.

max_up

Maximum number of parent traversals.

Value

Absolute path to the detected project root.

Examples

tryCatch(morie_find_project_root(),
  error = function(e) message("not inside a morie project tree")
)
#> not inside a morie project tree