rpkgkit 0.1.24 (2026-11-08)
NEW FEATURES
- Added
use_air_table()to lay out longc()andlist()calls as column-aligned tables withair0.8.0 or newer. A firstair formatrun leaves every element on its own line; the experimental# fmt: tabledirective is then inserted above every call holding more thanmin_lengthelements and the elements are re-flowed so that each row holdsncolof them, by collapsing the line breaks inside a row or, for a definition that air kept on a single line, by splitting it into rows. A secondair formatrun pads the cells and aligns the columns. Only calls whose elements are all unnamed are converted, because air expands named elements one per line whatever the directive says; only the outermost call of a statement is converted, because air ignores the directive on nested calls; a line ending in a comment is never joined with the next one, which would swallow the following element; and a call that already carries the directive is left untouched, so the function is idempotent.path = NULLfalls back to the active RStudio document,airmust be on thePATH(checked withcheck_air_installed()), and the normalized path is returned invisibly. - Added the standalone
standalone-cli_kable.Rscript, which providescli_kable()for printing a data frame, a matrix or any objectas.data.frame()accepts as the pipe table ofknitr::kable(), the layoutkableExtra::kable()shows, withcliinline classes instead of Markdown. The layout is the one ofkable(): cells are padded to the column width, columns arepaddingspaces wider and at least 3 characters wide, numeric columns are rounded todigitsdecimals and right aligned while everything else is left aligned, and the:---|---:alignment rule follows the headers.header_format(default".val"),rownames_format(default".val") andvalue_format(defaultNULL) accept a single class, a vector ofncol(x)classes, or a named vector or named list: named elements style only the columns or rows they name and an unnamed element is the fallback of everything that is not named, which is how a part of the table is highlighted, while the elements of avalue_formatlist can be named vectors of row names to style single cells. Widths are measured withcli::ansi_nchar()after the classes are applied, so classes that add visible characters ({.val},{.code}) keep the columns aligned, and each distinct class is rendered once instead of once per cell.align,digits,padding,sepandrulecontrol the rest of the table, an unknown name or an invalid class aborts withcli::cli_abort(), and the printed lines are returned invisibly.
DOCUMENTATION
- The
code_convertionvignette gained a “Lay out long vectors and lists as tables” section coveringuse_air_table()and its requirements. -
use_air_table()is listed in the README, in both translations underinst/translations/, and in the_pkgdown.ymlreference index. - The package is now spell-checked:
spellingwas added toSuggeststogether withLanguage: en-US,inst/WORDLISTholds the accepted words, andtests/spelling.Rrunsspelling::spell_check_test(). - The
standalone_toolsvignette gained a “Print data frames as kable-style tables” section coveringcli_kable()and the named formats that highlight a part of the table, and the package skill (skills/rpkgkit/) now lists every bundled standalone helper with the functions it provides.
rpkgkit 0.1.23 (2026-11-01)
NEW FEATURES
- Added
detect_fn_arg_path()andpackage_fn_arg_path()to report exported functions whose path-like argument defaults to a concrete location, which CRAN does not allow. The check is syntactic: the file is parsed, the top-levelname <- function(...)definitions that count as exported are kept, and every formal whose name matchesarg_pattern(default"path|file|filename") is reported when its default is not listed inallow(default"NULL"); an argument without a default is always fine. Each hit is printed asfile:line:colwith the function and argument name, the source lines and a caret marker underarg = default.detect_fn_arg_path()checks one file and falls back to the active document; passexportsorexport_patternswhen the exports of that file are known, otherwise every top-level function is checked.package_fn_arg_path()reads the exports fromNAMESPACEand scans the.Rfiles underdirs(default"R"). Both returnTRUEinvisibly when nothing needs fixing. - Added
use_tidy_addin()to register an exported function ininst/rstudio/addins.dcf, which makes it available from the RStudio Addins menu. The new entry is written above the existing ones, aBindingthat is already registered is never added twice, and the file is written as UTF-8. Before writing, the function checks that the path is a package and that the function is exported inNAMESPACE, reads the function body (from the installed package, or fromR/when the package has not been documented yet), and warns when the body calls norstudioapifunction or, withInteractive = TRUE, noshiny/miniUIfunction; a non-interactive session cannot confirm, so it only reports the warning and continues. It returns the path of the dcf file invisibly, orNULLwhen the operation is cancelled. -
rpkgkitnow registers its own addins ininst/rstudio/addins.dcf:package_lost_glue_brace()anddetect_lost_glue_brace(),package_print_and_cat()anddetect_print_and_cat(),package_fn_arg_path()anddetect_fn_arg_path(),package_unmatched_nocov_marker()andcheck_pkgdown_reference(). Thedetect_*()addins run on the active editor, the package-wide ones on the current package directory. All of them only report, so none rewrites a file.
MINOR IMPROVEMENTS
-
detect_lost_glue_brace()anddetect_print_and_cat()now print the offending source line with cli syntax highlighting. The file is highlighted once and then indexed line by line, because a single source line is usually not parseable (a continuation such asx = fn(a, b),ends with a comma) andcli::code_highlight()silently returns unparseable input unchanged; when the highlighting fails, or when it returns a different number of lines, the plain source is printed instead. -
add_colors_to_cli()(standalonecolorful_cli.R) gained.envir, defaulting toparent.frame()and forwarded to the wrapped cli function, so glue-style interpolation such as"Hello, {name}"is resolved in the caller’s environment instead of the wrapper’s frame. -
use_zzz()now resolvesfile_nameinside the function body (file_name = NULLmeans<pkg>-package.R) instead of in the default argument, following thepath = NULLconvention of the otheruse_*()helpers.
DOCUMENTATION
- The
code_convertionvignette gained a “Detect default paths in exported arguments” section coveringdetect_fn_arg_path()andpackage_fn_arg_path(), and thepkg_maintainvignette an “RStudio addins” section coveringuse_tidy_addin()and the bundled addins. - The
standalone_toolsvignette documents the.envirargument of thecolorful_cli.Rwrapper. - The README gained an “Addin” section, and
README.mdwas regenerated fromREADME.Rmd. Both translations underinst/translations/were brought back in sync with the English README: they now share its badge block (the stale development-version badge is gone), and carry the “recommended packages” and “AI skills” sections and the “Addin” section they were missing. - The package skill (
skills/rpkgkit/) covers the new functions and the addin workflow. - Vignette subtitles now report version 0.1.23.
rpkgkit 0.1.22 (2026-10-28)
NEW FEATURES
- Added
use_workflow_rust_compatible_check()to install a.github/workflows/R-CMD-check.yamlthat can build packages shipping Rust code. It copies the bundledR-CMD-Check.yamltemplate to the target package, creating.github/workflows/when needed. Unlike the workflow fromusethis::use_github_action("check-standard"), which only sets up R and leaves the runner’s default toolchain in place, the template installs Rust throughdtolnay/rust-toolchainand, on Windows, additionally thex86_64-pc-windows-gnutarget: the Windows runner defaults to an MSVC toolchain while R and Rtools are GNU based, so the static library produced bycargocannot be linked and the build noise makesR CMD checkreport a WARNING. The job matrix covers Windows, macOS, Ubuntu release and Ubuntu devel withfail-fast: false, and setsR_REMOTES_NO_ERRORS_FROM_WARNINGSso that download noise fromremotes/pakdoes not surface as a check failure. The function aborts when the path is not a package root, when the template is missing, or when the workflow file already exists andoverwrite = FALSE, and it returns the created path invisibly. The template follows the officialextendrCI.
BUG FIXES
-
make_func_arg_explicit()now accounts for the argument a pipe passes into its right-hand side call. The piped-in value already fills the function’s first formal, so the arguments written in the call are matched one formal later:x %>% stringr::str_remove("Merc")becomesx %>% stringr::str_remove(pattern = "Merc"), where it previously claimedstringand pushedMercontopattern. Placeholders are honoured too: a.anywhere in a magrittr right-hand side (%>%,%<>%,%T>%) cancels the leading injection, because the piped value is substituted at.instead of being inserted first, and a_in a native pipe (|>) makes the value fill the formal it is attached to, sox |> lm(y ~ z, data = _)becomesx |> lm(formula = y ~ z, data = _). Symbols that merely start with a dot, such as the.datapronoun and..1, are not mistaken for the placeholder. A comment between a pipe and its right-hand side no longer hides the call from the transformation.
rpkgkit 0.1.21 (2026-10-19)
NEW FEATURES
- Added
detect_unmatched_nocov_marker()andpackage_unmatched_nocov_marker()to check the# nocov start/# nocov endmarkers of a package. Detection is purely textual, so a marker hidden inside a string literal or a roxygen comment is reported too, which is intentional. Every marker is located by line and column, and a file may hold at most one start and one end, so the two counts must match: the second and later marker of each kind is reported, a start or an end without a counterpart is reported, and an end placed before the start is reported (an end later on the same line is accepted). An unclosed# nocov startis an error rather than a note, becausecovr::package_coverage()aborts on such a range with a “range start but only range ends” message.package_unmatched_nocov_marker()scansR/by default and takesdirsfor anything else. Every problem is printed with its line and column, the source line and a caret marker under the offending comment, so the fix is left to the user; the verdict is returned invisibly. - Added
get_positron_version()to report the version of the Positron IDE. It first reads thePOSITRON_VERSIONenvironment variable that Positron sets for its R sessions (POSITRON_LONG_VERSION, which includes the build number, whenlong = TRUE), then falls back to the.ps.positron_version()helper injected by the IDE, and finally to thepositron --versioncommand-line tool. When none of them is available it returnsNA_character_, so the function is safe to call outside Positron. - Added
check_sysdeps()to verify that the system development dependencies a package needs at build time are installed. It detects the package manager in use (dpkg,rpm,pacman,apkorbrew, pluswinget,chocoandscoopon Windows), or takes it frommanager, queries each dependency with that manager, and reports every hit and miss with cli, ending with a ready-to-paste install command for the missing ones. A dependency may list alternatives as"a|b": it counts as installed when any alternative is, and the first one is used in the install hint. On Linux the manager is read from/etc/os-releasebefore falling back to whichever manager is on thePATH,dpkgis queried throughdpkg-query, and the suggested command dropssudowhen R runs as root. Withdeps = NULLit checks the built-in list of graphics and font libraries (freetype,libjpeg,libpng,libtiff,libwebp,harfbuzz,fribidi,fontconfig) under the names used by that package manager; there is no built-in list for the Windows managers, sodepsmust be supplied for them. The result is returned invisibly as a named logical vector carrying the"manager"and, when something is missing,"install_cmd"attributes, andverbose = FALSEmakes the check silent. - Added
check_standalone()to verify that a custom standalone file follows the layout consumed byusethis::use_standalone(). It checks three points: the# ---header (the requiredrepo,file,last-updatedandlicenseslots, plus the optionalimportsslot, and the format of each value), that every documented function carries@noRd, and that a# nocov startmarker precedes all functions. Findings are printed in the style ofdevtools::check()and the counts are returned invisibly aslist(error = , warning = , note = ); an error in a check point skips the remaining ones, while warnings and notes never stop the run.
MINOR IMPROVEMENTS
-
use_vendor()now routes the files it is given by language instead of assuming R:.Rfiles still go toR/vendor-<pkg>.R,.cfiles tosrc/vendor-<pkg>.c,.cppfiles tosrc/vendor-<pkg>.cpp, and.rsfiles tosrc/rust/src/vendor-<pkg>.rs. A file given without a directory component is looked up in the conventional directory of its language (R/,src/orsrc/rust/src/), and all generated files share the same attribution header and per-file separators, with//as the comment prefix for the compiled sources. -
package_convert_int_literals()gained anexcludeargument listing the file names to skip, matched case-insensitively against the base name. It defaults toc("RcppExports.R", "extendr-wrappers.R"), so the wrappers written byRcpp::compileAttributes()andrextendr::document()are left alone, andNULL(orcharacter()) restores the previous behaviour of processing every file. -
GLOBAL_RBUILDIGNORE_PATTERNandPERMISSIVE_LICENSEare now internal constants instead of exported objects, so packages extending rpkgkit can no longer pick them up with::. Both are gone from the pkgdown reference index, andGLOBAL_RBUILDIGNORE_PATTERNno longer has a help page of its own. - The version-bumper action now keeps a Rust crate version in sync: when the package ships
src/rust/Cargo.toml, theversionkey of its[package]table is rewritten together with the R package version, under the sameNEWS.mdguard, while the rest of the manifest is left untouched. Only[package]is inspected, so dependencyversionkeys are never changed, and manifests without a literal version (e.g.version.workspace = true) are skipped. The commit step now stages only the files that exist.
DEPRECATED
-
news_md_check()is deprecated and now warns on every call.
DOCUMENTATION
- The
pkg_maintainvignette gained a “Check system dependencies” section coveringcheck_sysdeps()and a “Detect the Positron version” section coveringget_positron_version(). - The
standalone_toolsvignette gained a “Validate the standalone file layout” section coveringcheck_standalone(). - Vignette subtitles now report version 0.1.21.
- The README now notes that active-file detection in Positron requires Positron 2026.10.1 or later.
rpkgkit 0.1.20 (2026-10-15)
NEW FEATURES
- Added
optimize_rmd_yaml()to enrich the YAML header of oneREADME.Rmdor vignette from the package DESCRIPTION: title, author, date, language, an enrichedoutputblock and, for vignettes, theVignetteIndexEntry. A field that still holds its usethis default value (an “Untitled” title, a bareoutput: rmarkdown::html_vignette) is replaced, a field you changed is kept, and useroutputoptions are merged on top of the enriched defaults.package_optimize_rmd_yaml()applies the same logic toREADME.Rmdand every.Rmdundervignettes/. Both acceptextra,extra_readmeandextra_vignettefor adding custom fields such asparamsorbibliography. - Added
use_clangd()to write a.clangdconfiguration file that wires up system R,Rcpp,RcppEigen, andRcppArmadilloinclude paths. Ifpathis an R package root, an additionalIf:block disables clangd’s background indexing for theR/source directory, and.clangdis added to.Rbuildignore. Theincludeargument lets users pass any custom package names whoseinclude/directory should be added; packages that are not installed are skipped with a warning. - Added the standalone
standalone-cli_table.Rscript, which providescli_table()andcli_table_oneline()for printing cli-styled frequency tables of a vector, on two aligned lines or on a singleheader: countline. - Added the standalone
standalone-make_arg_validator.Rscript, which providesmake_arg_validator(), a factory that turns an unquoted block of checks and coercions written in terms of argument names into a reusable validator returning the validated arguments as a named list.
MINOR IMPROVEMENTS
- The standalone CLI helpers
add_caller_to_cli()(standalone-caller_cli.R),add_colors_to_cli()andcreate_colorful_cli_env()(standalone-colorful_cli.R), andadd_timestamp_to_cli()andcreate_ts_cli_env()(standalone-ts_cli.R) now validate their arguments:cli_funcmust be a function and thecli_functions/cli_funcvector ofcreate_*_cli_env()must be a character vector, otherwise the call aborts with a cli error naming the argument instead of failing later with a cryptic one. - Calls inside these standalone helpers now pass their arguments by name (e.g.
sys.call(which = ...),do.call(what = ..., args = ...)). - The version-bumper action now refuses to ship a release without a changelog entry: before writing anything it compares the version it is about to set with the highest version documented in
NEWS.mdand skips the bump (with a warning) when the new version is higher. WhenNEWS.mdis missing or holds no version heading, the check is bypassed with a warning.
DOCUMENTATION
- The
README.Rmdand vignette YAML headers were enriched withoptimize_rmd_yaml(), so the vignettes now carry a subtitle with the package version, an author, a date, alang, a richeroutputblock (table of contents, numbered sections, figure captions) and RStudioeditor_options. - The README badge block now shows the R-universe version badge; the development-version and last-commit badges were removed.
- In the
newsvignette, the section about the package startup message is titled “A startup message” instead of “A spinner startup message” and its chunk no longer echoes the message. - The
pkg_maintainvignette gained a “Configure the clangd language server” section, and thereadme_and_docvignette an “Enrich Rmd YAML headers” section coveringoptimize_rmd_yaml()andpackage_optimize_rmd_yaml(), including theextra,extra_readmeandextra_vignettearguments. - The
standalone_toolsvignette documents the newcli_tableandmake_arg_validatorscripts, and its examples now run as labelled, unevaluated knitr chunks with trimmedinquire_standalone()output.
rpkgkit 0.1.19 (2026-10-08)
NEW FEATURES
- Added
convert_pipe()andpackage_convert_pipe()to switch pipe operators between the tidyverse pipe%>%and the base pipe|>. Strings, comments, and raw strings are left unchanged, as are the placeholder pipe%<>%and the exposition pipe%$%. -
rename_func()gains anum_to_wordargument that expands digit abbreviations in function names into words, defaulting toc("for" = 4, "to" = 2). With the default mappinglist2env()becomeslist_to_env()andwait4result()becomeswait_for_result(), and the expanded words are formatted following thestyleargument, e.g.list2env()becomeslistToEnv()understyle = "camelCase". The argument accepts a named vector,NULL, orFALSE; any other input is an error. Only digit runs present in the mapping are expanded, so identifiers such asscale_x_log10()are left untouched.
MINOR IMPROVEMENTS
-
make_func_call_explicit(),package_func_call_explicit(), andadd_double_colons()no longer truncate function names that contain digits. Function calls such asr2dtable()andscale_x_log10()were matched only from their longest digit-free suffix (r2dtable()was treated asdtable()), which either produced invalid namespacing or triggered a spurious “Couldn’t find packages exporting” warning. - Added pattern detection for exported datasets, e.g.,
starwarsfromdplyrwill be detected. - Faster
make_func_arg_explicit()andpackage_func_arg_explicit(): large files are now planned several times faster, because the parse table is indexed once and child nodes are looked up in constant time instead of being rescanned for every node. Planning a whole package therefore no longer grows quadratically with its size.
rpkgkit 0.1.18
BUG FIXES
-
convert_int_literals()andpackage_convert_int_literals()no longer rewrite the exponent of a numeric literal such as1e-3/1E-3, which previously produced invalid code like1e-3L.
MINOR IMPROVEMENTS
-
check_air_installed()now offers to installairin interactive sessions when it is missing, skipping the prompt during tests. On macOS it now uses the official installer script instead of Homebrew oruv. - The package startup message now reports the load time (e.g.
loaded [12.34 ms]) instead of showing a progress spinner, and the same template is used byuse_zzz().
rpkgkit 0.1.17 (2026-9-22)
NEW FEATURES
- Added
badge_to_readme()to insert a Markdown badge into the badges block ofREADME.RmdorREADME.md. - Added exported
GLOBAL_RBUILDIGNORE_PATTERNandPERMISSIVE_LICENSEconstants for customizing package-maintenance workflows.
BUG FIXES
-
add_global_gitgnore()now correctly updates a package specified with an absolute path. -
use_vendor()now adds only people with anautorcrerole toAuthors@R. -
package_convert_int_literals()now skips automatically generatedRcppExports.Rfiles, which should not be edited manually.
MINOR IMPROVEMENTS
-
add_global_rbuildignore()now supports supplying custom patterns and replacing its default pattern set. -
use_vendor()records vendored-code authors as contributors and copyright holders, rather than package authors. - The version-bumper action now updates development-version badges before committing a release version. Its version commits now run CI before test branch synchronization.
rpkgkit 0.1.15
BUG FIXES
-
convert_int_literals(),package_convert_int_literals(), andconvert_func_syntax()now forward...torlang::check_dots_empty0(). Previously the call was made without..., so the documented “...must be empty” check was a no-op and extra arguments were silently ignored.
rpkgkit 0.1.14 (2026-09-14)
NEW FEATURES
- Added
use_bugreports()— sets theBugReportsfield of a package’sDESCRIPTIONfile, defaulting to the GitHub issues page detected from thegitremote. - Added
use_url()— sets theURLfield of a package’sDESCRIPTIONfile, defaulting to the GitHub repository detected from thegitremote, with an optional pkgdown website URL.
rpkgkit 0.1.13 (2026-08-13)
BUG FIXES
-
make_func_call_explicit()(andadd_double_colons()) no longer add::to function calls inside comments or roxygen2 documentation. Comments (including#'roxygen2 lines and trailing comments) are now left untouched.
rpkgkit 0.1.12 (2026-07-26)
NEW FEATURES
- Added
open_cffinit()— opens the CFF initializer in a browser to generateCITATION.cfffiles.
MINOR IMPROVEMENTS
- Removed redundant dependency
standalone-purrrinstandalone-args_to_func.R. - Beautified the changelog format in standalone files created by
add_changelog_in_standalone(). - Added community files (CONTRIBUTING.md, SUPPORT.md, issue template).
rpkgkit 0.1.10 (2026-07-15)
BUG FIXES
- Fixed bug when deparsing multiline code in
convert_nonascii_code()
rpkgkit 0.1.9 (2026-07-14)
MINOR IMPROVEMENTS
- Updated
use_vendor()to make it fully comply standalone header format
NEW FEATURES
- Added
use_workflow_test_branch(), which can create a test branch for maintaining R pkg. This branch will sync - Added
convert_noascii_code()to convert non-ascii code to ascii code, complying with CRAN requirements
BUG FIXES
-
add_changelog_in_standalone(): Fixed a bug when retrievingChangelogbadge
rpkgkit v0.1.8 (2026-07-12)
BUG FIXES
- Fixed dots checking error in
browse_standalone() - Fixed
.gitignorenot found error invendor-pkgdev.R, this bug is from source code ofpkgdev
rpkgkit 0.1.7 (2026-07-02)
CRAN release: 2026-07-21
BUG FIXES
- Fixed timestamp updating bug in
add_changelog_in_standalone()when modifyingvendor-*.R
NEW FEATURES
- Added
use_r_v4.1.0()
rpkgkit 0.1.5 (2026-06-30)
MINOR IMPROVEMENTS
- Added ‘Last-updated’,‘Version’,‘Imports’ in
use_vendor(). Relevant files are also updated.
rpkgkit 0.1.4 (2026-06-29)
MINOR IMPROVEMENTS
- Added
%||%function inuse_zzz()
rpkgkit 0.1.3 (2026-06-29)
BUG FIXES
- Fixed ignorance of
make_func_arg_explicit()when resolving complex R syntax
rpkgkit 0.1.2 (2026-06-29)
NEW FEATURES
- Added
convert_func_syntax()
MINOR IMPROVEMENTS
- Changed default file name created by
use_zzz()to-package.R - Bug fix in
use_workflow_version_update()
rpkgkit 0.1.1 (2026-06-27)
MINOR IMPROVEMENTS
- make
check_pkgdown_reference()easy to copy - Fixed lints
NEW FEATURES
- Added
package_*, some package-wise functions - Added
make_func_arg_explicit() - Imported
add_global_gitignorefrom pkgdev, under license MIT - Added
add_global_rbuildignore()to supplement.Rbuildignorewith common build-exclusion patterns - Added
use_vendor(),use_multilanguage_readme()
rpkgkit 0.1.0 (2026-06-25)
MINOR IMPROVEMENTS
- typescript-source action update for
use_workflow_version_update()
BUG FIXES
- Fix path bug in
render_rmd()
NEW FEATURES
- Added
use_zzz()for easier zzz.R management - Bump verion to v0.1
rpkgkit 0.0.7 (2026-06-17)
MINOR IMPROVEMENTS
- Added basic color support to
news_md_show() - Added dependency, description and nocov tag in
create_standalone() - Fixed pattern detection of
detect_lost_glue_brace()when resolving contexts with more than one lines. Added more detailed info in output
