Add CI=true environment variable (#372)

fixes #333
see https://docs.github.com/en/actions/reference/environment-variables#default-environment-variables
This commit is contained in:
Leonardo Dino 2020-09-28 16:22:42 +01:00 committed by GitHub
parent 6fdf1b04ef
commit 44151f208e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -491,6 +491,7 @@ func withDefaultBranch(b string, event map[string]interface{}) map[string]interf
func (rc *RunContext) withGithubEnv(env map[string]string) map[string]string { func (rc *RunContext) withGithubEnv(env map[string]string) map[string]string {
github := rc.getGithubContext() github := rc.getGithubContext()
env["CI"] = "true"
env["HOME"] = "/github/home" env["HOME"] = "/github/home"
env["GITHUB_WORKFLOW"] = github.Workflow env["GITHUB_WORKFLOW"] = github.Workflow
env["GITHUB_RUN_ID"] = github.RunID env["GITHUB_RUN_ID"] = github.RunID