-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support githubuser argument in kitten() call
- Loading branch information
1 parent
eea3c1f
commit 2706698
Showing
2 changed files
with
10 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
2025-02-08 Dirk Eddelbuettel <[email protected]> | ||
|
||
* inst/examples/kitten.r: Support githubuser argument kitten() call | ||
|
||
2025-02-05 Dirk Eddelbuettel <[email protected]> | ||
|
||
* inst/examples/rcc.r (rccwrapper): Print rcmdcheck result | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,8 @@ library(docopt) | |
doc <- "Usage: kitten.r [-t TYPE] [-b] [-p] [-h] [-x] PACKAGE | ||
-t --type TYPE type of kitten: plain, rcpp, arma, eigen. [default: plain] | ||
-b --bunny install roxygen2 documentation example and roxygenize (only for plain) | ||
-p --puppy invoke tinytest::puppy to set up testing (only for plain) | ||
-b --bunny install roxygen2 documentation example and roxygenize (only for plain) | ||
-p --puppy invoke tinytest::puppy to set up testing (only for plain) | ||
-h --help show this help text | ||
-x --usage show help and short example usage" | ||
|
||
|
@@ -26,10 +26,12 @@ See http://dirk.eddelbuettel.com/code/littler.html for more information.\n") | |
haswhoami <- requireNamespace("whoami", quietly=TRUE) | ||
author <- if (haswhoami) whoami::fullname("Your Name") else "Your Name" | ||
email <- if (haswhoami) whoami::email_address("[email protected]") else "[email protected]" | ||
githubuser <- if (haswhoami) whoami::gh_username() else NA_character_ | ||
|
||
## maybe support path, author, maintainer, email, license, ... | ||
## maybe support path, author, maintainer, email, license, ... command-line options | ||
ign <- switch(opt$type, | ||
plain = pkgKitten::kitten(opt$PACKAGE, author=author, email=email, | ||
plain = pkgKitten::kitten(opt$PACKAGE, | ||
author=author, email=email, githubuser=githubuser, | ||
puppy=opt$puppy, bunny=opt$bunny), | ||
rcpp = Rcpp::Rcpp.package.skeleton(opt$PACKAGE, author=author, email=email), | ||
arma = RcppArmadillo::RcppArmadillo.package.skeleton(opt$PACKAGE), | ||
|