New argument create_if_missing to load_all #852
Closed
Comments
That sounds good to me (although I'd use |
This old issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with reprex) and link to this issue. https://reprex.tidyverse.org/ |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
If
load_all()
doesn't find aDESCRIPTION
file in the package directory, it is created. As of #803, parent directories will not be scanned for aDESCRIPTION
file. #816 explicitly documents and tests this behavior.Now the behavior of
load_all()
is difficult to understand and communicate: If a directory happens to containR
,src
ordata
, aDESCRIPTION
is created -- if not (and noDESCRIPTION
exists), an error is thrown:I suggest a new argument
create_if_missing
that governs this behavior. IfTRUE
, always create (perhaps viadevtools::setup()
). IfFALSE
, never create (but use the usualpkg <- as.package(pkg)
idiom). IfNULL
(the default), the user will be asked if in interactive mode (otherwise same asFALSE
).@hadley: Is this sufficient for the use case you described in your comment?
The text was updated successfully, but these errors were encountered: