travis_encrypt: Encrypt for Travis

Description Usage Arguments Details References Examples

View source: R/travis.R

Description

Travis-CI allows for including small pieces of encrypted data with the configuration file such as passwords or access tokens.

Usage

1
2
3

Arguments

repo

travis repository in "user/repo" format (similar to install_github)

data

raw or character vector to encrypt

pubkey

a key returned by travis_pubkey, or a repo to be passed to travis_pubkey

Details

Travis generates a unique RSA keypair for each repository and publishes the public key via an API. We can use this to encrypt small pieces of secret data (such as passwords or tokens) in a way that only the Travis servers can decipher.

References

http://docs.travis-ci.com/user/encryption-keys/

Examples

1
2
3
4
# Encrypt environment variable
pubkey <- travis_pubkey("jeroenooms/jsonlite")
travis_encrypt("TOKEN=12345", pubkey)
travis_encrypt("TOKEN=12345", "jeroenooms/jsonlite")

jeroenooms/travis documentation built on May 19, 2019, 7:13 a.m.