Debian Codegraph @

man/news2md.Rd

raw
1 % Generated by roxygen2: do not edit by hand
2 % Please edit documentation in R/packages.R
3 \name{news2md}
4 \alias{news2md}
5 \title{Convert package news to the Markdown format}
6 \usage{
7 news2md(package, ..., output = "NEWS.md", category = TRUE)
8 }
9 \arguments{
10 \item{package, ...}{Arguments to be passed to \code{\link[=news]{news()}}.}
11
12 \item{output}{The output file path.}
13
14 \item{category}{Whether to keep the category names.}
15 }
16 \value{
17 If \code{output = NA}, returns the Markdown content as a character
18 vector, otherwise the content is written to the output file.
19 }
20 \description{
21 Read the package news with \code{\link[=news]{news()}}, convert the result to
22 Markdown, and write to an output file (e.g., \file{NEWS.md}). Each package
23 version appears in a first-level header, each category (e.g., \samp{NEW
24 FEATURES} or \samp{BUG FIXES}) is in a second-level header, and the news
25 items are written into bullet lists.
26 }
27 \examples{\dontshow{if (interactive()) \{}
28 # news for the current version of R
29 xfun::news2md("R", Version == getRversion(), output = NA)
30 \dontshow{\}}
31 }