octocat: "cat" a string if on GitHub

View source: R/util.R

octocatR Documentation

"cat" a string if on GitHub

Description

Prints a string if on GitHub, detected via env var GITHUB_ACTIONS == 'true'.

Usage

octocat(string)

Arguments

string

A character vector of length 1. This string will be terminated with last and printed with a new line.

Value

string invisibly

Examples

Sys.setenv(GITHUB_ACTIONS = "true")
octocat("::error ::Something is wrong")
Sys.unsetenv("GITHUB_ACTIONS")
octocat("::error ::Something is wrong")


assignUser/octolog documentation built on June 4, 2023, 3:28 p.m.