|
17 | 17 | # You should have received a copy of the GNU General Public License |
18 | 18 | # along with Rcpp. If not, see <http://www.gnu.org/licenses/>. |
19 | 19 |
|
20 | | -## local copy til pkgKitten is updated on CRAN |
21 | | -.pkgKittenPlayWithPerPackageHelpPage <- function(name = "anRpackage", |
22 | | - path = ".", |
23 | | - maintainer = "Your Name", |
24 | | - |
25 | | - root <- file.path(path, name) |
26 | | - helptgt <- file.path(root, "man", sprintf( "%s-package.Rd", name)) |
27 | | - helpsrc <- system.file("replacements", "manual-page-stub.Rd", package="pkgKitten") |
28 | | - ## update the package description help page |
29 | | - if (file.exists(helpsrc)) { |
30 | | - lines <- readLines(helpsrc) |
31 | | - lines <- gsub("__placeholder__", name, lines, fixed = TRUE) |
32 | | - lines <- gsub( "Who to complain to <[email protected]>", |
33 | | - sprintf( "%s <%s>", maintainer, email), |
34 | | - lines, fixed = TRUE) |
35 | | - writeLines(lines, helptgt) |
36 | | - } |
37 | | - invisible(NULL) |
38 | | -} |
39 | | - |
40 | | - |
41 | 20 | Rcpp.package.skeleton <- function(name = "anRpackage", list = character(), |
42 | 21 | environment = .GlobalEnv, |
43 | 22 | path = ".", force = FALSE, |
@@ -141,8 +120,7 @@ Rcpp.package.skeleton <- function(name = "anRpackage", list = character(), |
141 | 120 |
|
142 | 121 | ## update the package description help page |
143 | 122 | if (havePkgKitten) { # if pkgKitten is available, use it |
144 | | - #pkgKitten::playWithPerPackageHelpPage(name, path, maintainer, email) |
145 | | - .pkgKittenPlayWithPerPackageHelpPage(name, path, maintainer, email) |
| 123 | + pkgKitten::playWithPerPackageHelpPage(name, path, maintainer, email) |
146 | 124 | } else { |
147 | 125 | package_help_page <- file.path(root, "man", sprintf( "%s-package.Rd", name)) |
148 | 126 | if (file.exists(package_help_page)) { |
|
0 commit comments