buildSPK
Build a Spotfire SPK package file.

Description

Creates a Spotfire SPK package file with TIBCO Enterprise Runtime for R packages suitable for distribution to Spotfire clients.

Usage

buildSPK(listFile = "TERRPackages.dcf", spkFile = "TERRPackages.spk", 
    certificate = "", password = "", timestampUrl = "", 
    repos = "", buildDir = NULL, force = FALSE, version = NULL,
    versioned.filename = FALSE, timestampRFC3161 = NULL, sha256 = NULL)

Arguments

listFile a character string specifying the path to a Debian Control File (.dcf) listing the packages to build in a Packages field.
spkFile a character string specifying the path to the Spotfire SPK package file to be built. If the file exists, it is overwritten.
certificate a character string specifying the path to a certificate. The certificate is used to sign the SPK package file. If it is not specified, and the listFile does not contain a Certificate field, the SPK package file is not signed.
password a character string specifying the password that protects the certificate. The certificate and password are used to sign the SPK package file. If not specified, and the listFile does not contain a Password field, you are prompted for the password.
timestampUrl a character string specifying the URL to a timestamp service. Optional; if it is not specified, and the listFile does not contain a TimestampURL field, no timestamp is added.
repos a character vector specifying repository URLs. If it is not an empty string, all packages in the SPK package file are downloaded from the repository. Otherwise, the packages must have been previously installed.
buildDir a character vector specifying an existing directory. If specified, the buildDir is used to assemble the packages for the SPK package file. Otherwise, a temporary directory is created and consequently removed.
force a logical flag. If TRUE, errors about older versions are reduced to warnings. If FALSE (the default), these errors are thrown.
version a character string or numeric_version object that specifies the full version of the SPK package file to build. This version number must contain four components (for example, 1.0.0.0). If NULL (the default), the automatic version number increment rules are applied. See Details for more information.
versioned.filename a logical flag. If TRUE, spkFile is modified to contain the version number of the built package (either before the .spk extension if it is present, or at the end of the filename). If FALSE, spkFile is used verbatim.
timestampRFC3161 a logical flag. If TRUE, use the newer RFC 3161 timestamping protocol when contacting the timestamp service. If not specified, and the listFile does not contain a TimestampRFC3161 field, the older Microsoft Authenticode protocol is used.
sha256 a logical flag. If TRUE, use the SHA-256 hash algorithm when computing file digests. If not specified, and the listFile does not contain a UseSHA256 field, the SHA-1 hash algorithm is used. The use of the SHA-256 hash algorithm implies the use of the RFC 3161 timestamp protocol.

Details

The listFile is used to keep track of changes to the SPK package file and should be stored for safe keeping until the SPK package file needs to be updated with new packages. Then just edit the list file and run the function again.
Version number incrementing follows these rules (unless it is overriden by the version argument):
If the version number of the SPK package file is specified via the version argument, and if is the version specified is older than the version number incrementing rules would have created, this function throws an error. This error can be reduced to a warning via the force argument.
Value
returns invisible NULL.
See Also
buildServerSPK, read.dcf, readLines, install.packages, numeric_version
Examples
# Install and ensure packages work
install.packages(c("plyr", "zoo"))

# Generate a minimal list file writeLines("Packages: plyr,zoo", "SpotfireSPK.dcf")

#pass the generated listFile to buildSPK and build the specified package library(SpotfireSPK) buildSPK("SpotfireSPK.dcf", "SpotfireSPK.spk")

# Print updated list file cat(readLines("SpotfireSPK.dcf"), sep="\n")

Package SpotfireSPK version 6.0.0-69
Package Index