Skip to content

Conversation

@MichaelChirico
Copy link
Contributor

@MichaelChirico MichaelChirico commented Dec 10, 2024

Ran into this ugly output from usethis::use_package_doc() on a GitHub codespace (which is intentionally lightweight):

✔ Setting active project to "/workspaces/lori".
✔ Writing R/lori-package.R.
☐ Modify R/lori-package.R.
sh: 1: vi: not found
☐ Run `devtools::document()` to update package-level documentation.
Warning message:
error in running command

The problem is R prefers EDITOR=vi by default (even if it's not available).

A more advanced fix might instead come up with a {usethis}-internal ordered list of editors to try, iterating over them and using the first found installed. But anyway this PR is a good first improvement.

I started an r-devel thread too:

https://stat.ethz.ch/pipermail/r-devel/2024-December/083717.html

@jennybc
Copy link
Member

jennybc commented Jul 29, 2025

I read through the linked thread and find that I really feel like this is out of scope for usethis. I think it is quite rare that a usethis user is going to run into this and the possible downsides of getting involved with this just don't seem worth it to me.

@jennybc jennybc closed this Jul 29, 2025
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