Transition to cli package for UI
- The
ui_*()
functions have been marked as
superseded.
External users of these functions are encouraged to use the
cli package instead.
The cli package did not have the required functionality when the
usethis::ui_*()
functions were first created, but it does now and it's the
superior option.
There is a cli vignette about how to make this transition:
vignette("usethis-ui", package = "cli")
.
usethis no longer uses theui_*()
functions internally, in favor of new
cli-based helpers that are not exported.
Deprecated function and argument removal
We are removing functions and arguments that were deprecated as of usethis
v2.0.0, which was released in December 2020.
These changes have been in place for a long time now:
- Switch from git2r to gert (+ credentials).
- Use of git config and the gh package to infer, e.g., the target repo spec.
- Pivot towards GitHub Actions and away from Travis and AppVeyor.
Functions that are removed and, where applicable, what to use instead:
git_credentials()
use_git_credentials()
browse_github_token()
(docreate_github_token()
)browse_github_pat()
(docreate_github_token()
)github_token()
(dogh_token_help()
orgh::gh_token()
)pr_pull_upstream()
(dopr_merge_main()
)pr_sync()
(dopr_merge_main(); pr_push()
)use_appveyor()
use_appveyor_badge()
use_travis()
use_travis_badge()
browse_travis()
use_pkgdown_travis()
use_tidy_ci()
deprecated in v2.1.0 (douse_tidy_github_actions()
)use_tidy_labels()
deprecated in v2.1.0 (douse_tidy_github_labels()
)
Function arguments that are removed:
create_from_github(auth_token =, credentials =)
use_github(auth_token =, credentials =)
use_github_labels(repo_spec =, host =, auth_token =)
use_github_links(auth_token =, host =)
use_github_release(host =, auth_token =)
Other changes
-
use_zip()
anduse_course()
are equipped to handle a ZIP where the parent
folder is implicit (@burnsal, #1961). -
use_test_helper()
is a new function to create a test helper file
(@olivroy, #1822). -
use_cpp11()
makes it easier to updateNAMESPACE
(@pachadotdev, #1921). -
pr_merge_main()
now offers the choice to not open the files with merge
conflicts (@olivroy, #1720). -
edit_rstudio_snippets()
now accepts yaml snippets (@olivroy, #1941). -
use_standalone()
inserts an improved header that includes the code needed to
update the standalone file (@krlmlr, #1903). -
use_release_issue()
anduse_upkeep()
behave better when the user has a
fork. The user is asked just once to choose betweenorigin
andupstream
as
the target repo (#2023). -
The README templates now recommend pak instead of
devtools for package installation (@olivroy, #1723). -
use_github()
now knows that you can reuse the name of an earlier repo that
has since been renamed (@ateucher, #1893). -
use_git()
no longer asks if you want to restart RStudio when using Positron. -
use_test()
anduse_r()
now work when you are in
tests/testthat/_snaps/{foo}.md
(@olivroy, #1988). -
The URLs baked into the badge generated by
use_coverage(type = "codecov")
are updated and no longer specify a branch(#2008). -
usethis::use_version()
now tolerates empty lines preceding the
first section title in the package NEWS file. (#1976)