Rush StackShopBlogEvents
Skip to main content

Home > @microsoft/rush-lib > EnvironmentConfiguration

EnvironmentConfiguration class

This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Provides Rush-specific environment variable data. All Rush environment variables must start with "RUSH_". This class is designed to be used by RushConfiguration.

Signature:

export declare class EnvironmentConfiguration 

Remarks

Initialize will throw if any unknown parameters are present.

Properties

Property

Modifiers

Type

Description

absoluteSymlinks

static

readonly

boolean

(BETA) If "1", create symlinks with absolute paths instead of relative paths. See

allowUnsupportedNodeVersion

static

readonly

boolean

(BETA) If this environment variable is set to "1", the Node.js version check will print a warning instead of causing a hard error if the environment's Node.js version doesn't match the version specifier in rush.json's "nodeSupportedVersionRange" property.

See .

allowWarningsInSuccessfulBuild

static

readonly

boolean

(BETA) Setting this environment variable overrides the value of allowWarningsInSuccessfulBuild in the command-line.json configuration file. Specify 1 to allow warnings in a successful build, or 0 to disallow them. (See the comments in the command-line.json file for more information).

buildCacheCredential

static

readonly

string | undefined

(BETA) Provides a credential for reading from and writing to a remote build cache, if configured. See

buildCacheEnabled

static

readonly

boolean | undefined

(BETA) If set, enables or disables the cloud build cache feature. See

buildCacheOverrideJson

static

readonly

string | undefined

(BETA) If set, overrides the build cache configuration that normally lives at common/config/rush/build-cache.json. See

buildCacheOverrideJsonFilePath

static

readonly

string | undefined

(BETA) If set, overrides the build cache configuration that normally lives at common/config/rush/build-cache.json. See

buildCacheWriteAllowed

static

readonly

boolean | undefined

(BETA) If set, enables or disables writing to the cloud build cache. See

cobuildContextId

static

readonly

string | undefined

(BETA) Provides a determined cobuild context id if configured See

cobuildLeafProjectLogOnlyAllowed

static

readonly

boolean | undefined

(BETA) If set, enables or disables the cobuild leaf project log only feature. See

cobuildRunnerId

static

readonly

string | undefined

(BETA) Provides a determined cobuild runner id if configured See

gitBinaryPath

static

readonly

string | undefined

(BETA) Allows the git binary path to be explicitly provided. See

hasBeenValidated

static

readonly

boolean

(BETA) If true, the environment configuration has been validated and initialized.

pnpmStorePathOverride

static

readonly

string | undefined

(BETA) An override for the PNPM store path, if pnpmStore configuration is set to 'path' See

pnpmVerifyStoreIntegrity

static

readonly

boolean | undefined

(BETA) If specified, enables or disables integrity verification of the pnpm store during install. See

quietMode

static

readonly

boolean

(BETA) If true, Rush will suppress informational startup messages, equivalent to passing --quiet. See

rushGlobalFolderOverride

static

readonly

string | undefined

(BETA) Overrides the location of the ~/.rush global folder where Rush stores temporary files. See

rushTempFolderOverride

static

readonly

string | undefined

(BETA) An override for the common/temp folder path.

tarBinaryPath

static

readonly

string | undefined

(BETA) Allows the tar binary path to be explicitly provided. See

Methods

Method

Modifiers

Description

parseBooleanEnvironmentVariable(name, value)

static

(BETA)

reset()

static

(BETA) Resets EnvironmentConfiguration into an un-initialized state.

validate(options)

static

(BETA) Reads and validates environment variables. If any are invalid, this function will throw.