summaryrefslogtreecommitdiff
path: root/devel/R-xfun
AgeCommit message (Collapse)AuthorFilesLines
2022-05-30(devel/R-xfun) Updated 0.30 to 0.31mef2-6/+6
# CHANGES IN xfun VERSION 0.31 - `github_releases(use_jsonlite = FALSE)` supports R versions below 4.1.0 now. - `session_info()` silently drops empty package names now (thanks, @phargarten2, #65).
2022-04-23(devel/R-xfun) Updated 0.26 to 0.30mef2-6/+6
# CHANGES IN xfun VERSION 0.30 - Added a new function `is_blank()` (previously existed in **knitr**) to test if all elements of a character vector are blank (white spaces or empty strings). - Added a new argument `error = TRUE` to `existing_files()`. # CHANGES IN xfun VERSION 0.29 - `github_releases()` can fetch all releases (tags) of a Github repo now. - Added an argument `.error` to `download_file()` so that users can customize the error message when the download fails. - Added functions `rest_api_raw()` and `rest_api()` to get data from a REST API; also added the function `github_api()` to get data from the Github API based on `rest_api_raw()`. - Added a wrapper function `system3()` based on `system2()` to mark the character output of `system2()` as UTF-8 if appropriate. - Added a function `existing_files()` to return file paths that exist (a shorthand of `x[file.exists(x)]`). - Added a function `read_all()` to read multiple files and concatenate the content into a character vector. - `url_accessible()` uses `curlGetHeaders()` by default (instead of `download_file()`) to test if a URL is accessible when the **curl** package is not available. - When `options(xfun.rev_check.compare = FALSE)`, `rev_check()` will run `R CMD check` on reverse dependencies against a source package but not the CRAN version of this package. By default, this option is `TRUE`, meaning that `R CMD check` will run against both versions of the package. # CHANGES IN xfun VERSION 0.28 - Added a new function `url_accessible()` to test if a URL can be downloaded. - Added a new function `try_error()` to try an expression and see if it throws an error. # CHANGES IN xfun VERSION 0.27 - Exported and documented the function `xfun::base_pkgs()` (to return base R package names). - Changed the default value of the `status_only` argument of `compare_Rcheck()` from `FALSE` to `TRUE`. - Added new functions `crandalf_check()` and `crandalf_results()` for checking (especially large numbers of) reverse dependencies of packages via [**crandalf**](https://github.com/yihui/crandalf). - Added new functions `append_utf8()` and `append_unique()` based on `read_utf8()` and `write_utf8()` to append content to files or connections.
2021-10-26archivers: Replace RMD160 checksums with BLAKE2s checksumsnia1-2/+2
All checksums have been double-checked against existing RMD160 and SHA512 hashes Could not be committed due to merge conflict: devel/py-traitlets/distinfo The following distfiles were unfetchable (note: some may be only fetched conditionally): ./devel/pvs/distinfo pvs-3.2-solaris.tgz ./devel/eclipse/distinfo eclipse-sourceBuild-srcIncluded-3.0.1.zip
2021-10-07devel: Remove SHA1 hashes for distfilesnia1-2/+1
2021-09-18(math/R-xfun) Updated 0.25 to 0.26mef2-7/+8
# CHANGES IN xfun VERSION 0.26 - The `windows_only` argument of `native_encode()` has been removed. Now `native_encode()` only tries the conversion to native encoding on platforms where `l10n_info()[['UTF-8']]` does not return `TRUE`. - Added a `solaris` argument to `upload_win_builder()`.
2021-08-17(devel/R-xfun) Remove outdated comment linesmef1-4/+1
2021-08-17(devel/R-xfun) Updated 0.23 to 0.25mef2-8/+13
# CHANGES IN xfun VERSION 0.25 - Fixed a bug in `broken_packages()` (thanks, @PythonCoderUnicorn, rstudio/rmarkdown#1990). - Added a `files` argument to `optipng()` so that users can specify the list of PNG files instead of running `optipng` on a whole directory. # CHANGES IN xfun VERSION 0.24 - Exported the internal function `broken_packages()` to reinstall broken R packages. - Fixed the bug in `proj_root()` #54 (thanks, @clarkliming).
2021-05-31(devel/R-xfun) Update TEST_DEPENDS+, fix typomef1-2/+2
2021-05-31(devel/R-xfun) Update TEST_DEPENDS+, but still failingmef1-5/+4
2021-05-31(devel/R-xfun) Updated 0.2.0 to 0.23mef2-7/+7
# CHANGES IN xfun VERSION 0.23 ## NEW FEATURES - Added a `tinify()` function to compress PNG/JPEG images via [the Tinify API](https://tinypng.com/developers). - Added a `news2md()` function to convert package news to the Markdown format. This is mainly for converting the plain-text `NEWS` file and the `NEWS.Rd` file to `NEWS.md`. - Added a `format_bytes()` function to format numbers of bytes using a specified unit, e.g., `1024` can be formatted as `1 Kb`. - When using `pkg_load2()` in an **renv** project, it will use `renv::install()` to install missing packages by default to take advantage of **renv**'s caching feature (thanks, @chunyunma @cderv, #52). - `upload_win_builder()` no longer requires the system command `curl` to be available; if `curl` is not available, the R package **curl** will be used instead, which means this R package must be installed. In addition to uploading to the `ftp` server of win-builder, it's also possible to upload to <https://win-builder.r-project.org/upload.aspx>: call `upload_win_builder(..., server = 'https')`. This change was made so that it would be possible to continue to upload to win-builder in case it should stop supporting `ftp` (CRAN has discouraged package authors from using `ftp://`). ## BUG FIXES - Backticks are added to math environments by mistake when `\begin{}` and `\end{}` do not match (thanks, @oliviergimenez, #51). ## MINOR CHANGES - The argument `src` was renamed to `pkg` in `install_dir()`. - The argument `file` of `upload_win_builder()` defaults to `pkg_build()` now, i.e., by default, it will build a source package and upload it, so you do not need to build the package separately. # CHANGES IN xfun VERSION 0.22 ## NEW FEATURES - `relative_path()` is vectorized now. - Added a new function `retry()` to retry calling a function for a number of times in case of errors. - Added a new function `sort_file()`, which is a shorthand for `process_file(fun = sort)` to sort the lines in a text file. ## MAJOR CHANGES - The argument `FUN` was renamed to `fun` in `process_file()`. ## MINOR CHANGES - Inside `download_file()`, the `timeout` option in `options()` is set to 3600 seconds when it takes the default value of 60 seconds, which may not be enough for downloading large files (thanks, @matthewgson, yihui/tinytex#286). # CHANGES IN xfun VERSION 0.21 ## NEW FEATURES - Added a new function `pkg_available()` to test if a package with a minimal version is available (thanks, @cderv, #45). - Added a new function `set_envvar()` to set environment variables and return their old values, so they could be restored later. - Added a new function `exit_call()` to call a function when a parent function exits. - Exported the internal function `read_bin()`. - Added an argument `verbose` to `bg_process()`. - `Rscript_call()` gains an `options` argument to pass command-line options to `Rscript` (thanks, @cderv, #48).
2021-02-08(devel/R-xfun) Updated 0.19 to 0.20mef2-7/+7
# CHANGES IN xfun VERSION 0.20 ## NEW FEATURES - Added a function `msg_cat()` to generate a message with `cat()`. See the help page `?xfun::msg_cat` for more information. - Added a function `mark_dirs()` to mark directories with a trailing slash in a vector of paths to differentiate them from normal filenames (#44). ## BUG FIXES - `xfun::proc_kill()` failed to work on *nix. - `xfun::del_empty_dir()` failed to delete empty dirs. - `xfun::file_string()` preserves emptiness (thanks, @MichaelChirico, #38). - `xfun::raw_string()` preserves the class(es) of the input now (thanks, @MichaelChirico, #40). ## MINOR CHANGES - Exported the function `dir_create()`.
2021-01-01(devel/R-xfun) Updated 0.18 to 0.19mef2-7/+9
# CHANGES IN xfun VERSION 0.19 ## NEW FEATURES - Added functions `bg_process()` to run a command in a background process, and `proc_kill()` to kill a process. - Added a function `del_empty_dir()` to delete a directory if it is empty. - Added functions `is_abs_path()` and `is_rel_path()` to check if paths are absolute or relative. - Added a function `is_sub_path()` to test if a path is under a directory. - Added a function `is_web_path()` to test if a path is a web path that starts with `http://` or `https://` or `ftp://` or `ftps://`. - Documented and exported the previously internal functions `dir_exists()` and `file_exists()` (thanks, @cderv, #36). - Added a function `dir_create()` to create a directory recursively by default when it does not exist. - Added an argument `fail` to `Rscript_call()` to allow users to customize the error message when an error occurred in calling the function in a new R session. ## MINOR CHANGES - `file_ext()`, `sans_ext()`, and `with_ext()` no longer use `tools::file_ext()` or `tools::file_path_sans_ext()`, but provide a slightly different implementation. They treat `tar.(gz|bz2|xz)` and `nb.html` as file extensions, and also allow extensions to contain a trailing `~` or `#`.
2020-10-03(devel/R-xfun) Updated 0.17 to 0.18mef2-7/+7
# CHANGES IN xfun VERSION 0.18 ## NEW FEATURES - Added a function `grep_sub()` to perform replacement with `gsub()` on elements matched from `grep()`. - Added a function `github_releases()` to obtain the tags from the Github releases of a repo. - Added a function `bump_version()` to increase the last digit of version numbers by one. - Moved a function `process_file()` from the **blogdown** package to this package, and documented it. - Added a function `valid_syntax()` to check if an R code fragment is syntactically valid. This function was moved from the **highr** package. - Added a function `url_filename()` to extract filenames from URLs. This function is used by `download_file()` to determine the default output filename. - Added a function `do_once()` to perform a task once in an R session. - Added a function `proj_root()` to find the root directory of a project. Currently it only supports R package projects and RStudio projects by default. - Added a function `relative_path()` to calculate the relative path of a path relative to a directory. - Added a function `from_root()`, which is similar to `here::here()` but returns a relative path instead of an absolute path. - Added a function `magic_path()` that, given an incomplete input path, tries to find the actual path recursively under subdirectories of a root directory. For example, users may only provide a base filename, and `magic_path()` will look for this file under subdirectories and return the actual path if it is found. ## MINOR CHANGES - Now `download_file()` tries the download method `winnet` first (previously it was `libcurl`) on Windows (thanks, @cderv, #33).
2020-09-20(devel/R-xfun) Updated 0.8 to 0.17mef2-8/+14
# CHANGES IN xfun VERSION 0.17 ## NEW FEATURES - Supports `xfun::pkg_attach(packages, install = "pak")`, i.e., use `pak::pkg_install()` to install a package when it is not installed (thanks, @GitHunter0, #32). - Added a new function `xfun::split_source()` to split lines of R source code into minimal complete expressions. # CHANGES IN xfun VERSION 0.16 - Added a new function `base64_decode()` to decode data from the base64 encoding (thanks, @wush978, #31). # CHANGES IN xfun VERSION 0.15 ## NEW FEATURES - Added a new function `tree()`, which is based on `str()` in base R, but changes the output of `str()` into a tree diagram to make it easier to understand nested data structures. - Added a new function `base64_encode()` to encode data into the base64 encoding (thanks, @wush978, #27). - Added a new function `base64_uri()` to generate the Data URI (or Data URL) for a file. ## BUG FIXES - Fenced code blocks commented out in `<!-- -->` are not longer recognized as code blocks but prose (thanks, @jarauh, #25). # CHANGES IN xfun VERSION 0.14 ## NEW FEATURES - The `cache_rds()` function can invalidate the cache automatically when the code passed to its `expr` argument has changed. Two new arguments, `hash` and `clean` were added to this function to make it more useful and powerful. See the help page `?xfun::cache_rds()` for more information. # CHANGES IN xfun VERSION 0.13 ## NEW FEATURES - Added a new function `cache_rds()` to cache an R expression to a `*.rds` file. - Added a new function `Rscript_call()` to call a function (with arguments) in a new R session via the command `Rscript`. - The `recheck` argument of `rev_check()` can take a vector of package names, and only these packages will be checked. See `?xfun::rev_check` for more details. # CHANGES IN xfun VERSION 0.12 ## NEW FEATURES - Added a new function `split_lines()`. # CHANGES IN xfun VERSION 0.11 ## BUG FIXES - `read_utf8()` will read the file with `options(encoding = 'native.enc')` and ignore user's setting such as `options(encoding = 'UTF-8')` (#21). # CHANGES IN xfun VERSION 0.10 ## NEW FEATURES - Added the function `as_strict_list()` to convert an existing object to a strict list without wrapping it in another list if the object already is of type list (in contrast to how `strict_list()` behaves) (thanks, @salim-b, #20). # CHANGES IN xfun VERSION 0.9 ## NEW FEATURES - Added a function `rename_seq()` to rename files to add an incremental numeric prefix to the filenames, e.g., rename `a.txt`, `b.txt`, `c.txt` to `1-a.txt`, `2-b.txt`, `3-c.txt`.
2019-08-08Update all R packages to canonical form.brook1-6/+4
The canonical form [1] of an R package Makefile includes the following: - The first stanza includes R_PKGNAME, R_PKGVER, PKGREVISION (as needed), and CATEGORIES. - HOMEPAGE is not present but defined in math/R/Makefile.extension to refer to the CRAN web page describing the package. Other relevant web pages are often linked from there via the URL field. This updates all current R packages to this form, which will make regular updates _much_ easier, especially using pkgtools/R2pkg. [1] http://mail-index.netbsd.org/tech-pkg/2019/08/02/msg021711.html
2019-07-31R-xfun: initial commit.brook3-0/+24
Miscellaneous functions commonly used in other packages maintained by 'Yihui Xie'.