install.packages( "usethis", type="binary", dependencies=TRUE)
library(usethis)
install.packages( "roxygen2", type="binary", dependencies=TRUE)
library(roxygen2)
install.packages( "R.utils", type="binary", dependencies=TRUE)
library(R.utils)
install.packages( "digest", type="binary")
library(digest)
# Change digest functions cause to bug in network system with Windows --------------
mydigest <- function (object, algo = c("md5", "sha1", "crc32", "sha256",
"sha512", "xxhash32", "xxhash64", "murmur32"), serialize = TRUE,
file = FALSE, length = Inf, skip = "auto", ascii = FALSE,
raw = FALSE, seed = 0, errormode = c("stop", "warn", "silent")) {
file.access <- R.utils::fileAccess
digest <- function(object, algo=c("md5", "sha1", "crc32", "sha256", "sha512",
"xxhash32", "xxhash64", "murmur32", "spookyhash"),
serialize=TRUE,
file=FALSE,
length=Inf,
skip="auto",
ascii=FALSE,
raw=FALSE,
seed=0,
errormode=c("stop","warn","silent"),
serializeVersion=.getSerializeVersion()) {
algo <- match.arg(algo)
errormode <- match.arg(errormode)
if (is.infinite(length)) {
length <- -1 # internally we use -1 for infinite len
}
if (is.character(file) && missing(object)) {
object <- file # nocov
file <- TRUE # nocov
}
}}
R.utils::reassignInPackage("digest", "digest", mydigest)
# Creation of FILES -------------------------------------------------------
# Adapt description file for package
usethis::edit_file("DESCRIPTION")
# Create an empty r file for the function
usethis::use_r("example")
# Define dependencies that are essential to run this package
usethis::use_package("dplyr")
# Create .Rd-files and update NAMESPACE
roxygen2::roxygenise()
# Überprüfe kompilierte Dokumentation der Funktion in RStudio
?add
# Lade das source package in den Workspace (Befehl überspringt die Installation)
devtools::load_all()
# git remote add upstream https://location/of/generic.git
# git pull upstream
# git config remote.upstream.pushurl "NEVER GONNA GIVE YOU UP"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.