Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow envvar 'ORDERLY_ROOT' to use alternative root by default #189

Merged
merged 6 commits into from
Oct 22, 2024

Conversation

richfitz
Copy link
Member

@richfitz richfitz commented Oct 22, 2024

Add support for an environment variable ORDERLY_ROOT that we look up when root is not provided (i.e., is NULL). This allows us to control the apparent root of orderly in documentation (see usage in the vignettes here), and appears more usable in quarto docs than the previous setwd hack, which is now removed. This is not documented or advertised anywhere, but we can do do if we think it makes sense to allow users to work this way too.

@richfitz richfitz marked this pull request as ready for review October 22, 2024 08:06
@richfitz richfitz requested a review from plietar October 22, 2024 08:07
@@ -114,26 +114,31 @@ Both Alice and Bob clone this repo onto their machines, using their favourite gi

At the moment, including hidden files (except `.git`), Alice sees:

```{r, as = "alice", inwd = path_alice}
```{r, as = "alice", orderly_root = path_alice}
fs::dir_tree(".", all = TRUE, glob = ".git", invert = TRUE)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't that affect the output of this block?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, fixed that

@richfitz richfitz merged commit 167e4a6 into main Oct 22, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants