Type aliases
AllDependencies
AllDependencies: "dependencies" | "devDependencies" | "peerDependencies"
AllTransforms
AllTransforms: typeof transforms
BaseSettingsDefinition
BaseSettingsDefinition<T>: object
Type parameters
Type declaration
-
description: string
-
Optional isArray?: undefined | false | true
-
type: T
Body
Body: null | string | Buffer | object
CommandContext
CommandContext: object
Type declaration
-
-
-
quiet: boolean
-
stderr: Writable
-
stdin: Readable
-
stdout: Writable
DescriptorHash
DescriptorHash: string & object
ExecutePackageAccessibleBinaryOptions
ExecutePackageAccessibleBinaryOptions: object
Type declaration
-
-
Optional nodeArgs?: Array<string>
-
-
stderr: Writable
-
stdin: Readable | null
-
stdout: Writable
ExecutePackageScriptOptions
ExecutePackageScriptOptions: object
Type declaration
-
Optional cwd?: PortablePath | undefined
-
-
stderr: Writable
-
stdin: Readable | null
-
stdout: Writable
ExecuteWorkspaceAccessibleBinaryOptions
ExecuteWorkspaceAccessibleBinaryOptions: object
Type declaration
-
-
stderr: Writable
-
stdin: Readable | null
-
stdout: Writable
ExecuteWorkspaceLifecycleScriptOptions
ExecuteWorkspaceLifecycleScriptOptions: object
ExecuteWorkspaceScriptOptions
ExecuteWorkspaceScriptOptions: object
Type declaration
-
Optional cwd?: PortablePath | undefined
-
stderr: Writable
-
stdin: Readable | null
-
stdout: Writable
ExecvpOptions
ExecvpOptions: object
Type declaration
-
-
Optional encoding?: undefined | string
-
Optional env?: undefined | object
-
Optional strict?: undefined | false | true
FetchFromCacheOptions
FetchFromCacheOptions: object
FetchResult
FetchResult: object
Type declaration
-
Optional checksum?: undefined | string
-
Optional discardFromLookup?: undefined | false | true
-
Optional localPath?: PortablePath | null
-
-
-
Optional releaseFs?: undefined | function
FinalizeInstallStatus
FinalizeInstallStatus: object
FindProjectOptions
FindProjectOptions: object
Type declaration
-
-
Optional strict?: undefined | false | true
-
Optional usePath?: undefined | false | true
-
Optional useRc?: undefined | false | true
GetPackageAccessibleBinariesOptions
GetPackageAccessibleBinariesOptions: object
HardDependencies
HardDependencies: "dependencies" | "devDependencies"
HasPackageScriptOption
HasPackageScriptOption: object
Hooks
Hooks: object
Type declaration
-
Optional afterAllInstalled?: undefined | function
-
Optional globalHashGeneration?: undefined | function
-
Optional populateYarnPaths?: undefined | function
-
Optional reduceDependency?: undefined | function
-
Optional registerPackageExtensions?: undefined | function
-
Optional setupScriptEnvironment?: undefined | function
-
Optional validateProject?: undefined | function
-
Optional validateWorkspace?: undefined | function
-
Optional wrapScriptExecution?: undefined | function
IdentHash
IdentHash: string & object
InstallOptions
InstallOptions: object
Type declaration
-
-
Optional fetcher?: Fetcher
-
Optional immutable?: undefined | false | true
-
Optional lockfileOnly?: undefined | false | true
-
Optional persistProject?: undefined | false | true
-
-
Optional resolver?: Resolver
InstallStatus
InstallStatus: object
LightReportOptions
LightReportOptions: object
Type declaration
-
-
stdout: Writable
-
Optional suggestInstall?: undefined | false | true
LocatorHash
LocatorHash: string & object
MinimalFetchOptions
MinimalFetchOptions: object
MinimalLinkOptions
MinimalLinkOptions: object
MinimalResolveOptions
MinimalResolveOptions: object
Options
Options: object
Type declaration
-
-
Optional headers?: undefined | object
-
Optional jsonRequest?: undefined | false | true
-
Optional jsonResponse?: undefined | false | true
-
Optional method?: Method
ParseRangeOptions
ParseRangeOptions: object
Type declaration
-
Optional parseSelector?: undefined | false | true
-
Optional requireBindings?: undefined | false | true
-
Optional requireProtocol?: boolean | string
-
Optional requireSource?: undefined | false | true
ParseRangeReturnType
ParseRangeReturnType<Opts>: object & object & object & object
Type parameters
PipevpOptions
PipevpOptions: object
Type declaration
-
-
-
Optional env?: undefined | object
-
stderr: Writable
-
stdin: Readable | null
-
stdout: Writable
-
Optional strict?: undefined | false | true
Plugin
Plugin<PluginHooks>: object
Type parameters
Type declaration
-
-
Optional configuration?: undefined | object
-
-
-
-
PluginConfiguration
PluginConfiguration: object
Type declaration
-
modules: Map<string, any>
-
plugins: Set<string>
ProcessEnvironment
ProcessEnvironment: object
ProgressDefinition
ProgressDefinition: object
Type declaration
-
progress: number
-
Optional title?: undefined | string
RegistryBlock
RegistryBlock: object
Type declaration
-
Optional enumerators?: undefined | object
-
Optional hits?: undefined | object
-
Optional values?: undefined | object
RegistryFile
RegistryFile: object
Type declaration
-
Optional blocks?: undefined | object
-
Optional lastUpdate?: undefined | number
SettingTransforms
SettingTransforms: object
Type declaration
-
getNativePaths: boolean
-
hideSecrets: boolean
SettingsDefinitionNoDefault
Source
Source<T>: T extends keyof AllTransforms ? Parameters<AllTransforms[T]["json"]>[0] | null : string | null
Type parameters
Specs
Specs: Array<[string, string, boolean]>
StreamReportOptions
StreamReportOptions: object
Type declaration
-
-
Optional forgettableBufferSize?: undefined | number
-
Optional forgettableNames?: Set<MessageName | null>
-
Optional includeFooter?: undefined | false | true
-
Optional includeInfos?: undefined | false | true
-
Optional includeLogs?: undefined | false | true
-
Optional includeWarnings?: undefined | false | true
-
Optional json?: undefined | false | true
-
stdout: Writable
TreeNode
TreeNode: object
Type declaration
-
-
Optional label?: undefined | string
-
Optional value?: formatUtils.Tuple
TreeifyNode
TreeifyNode: object
Tuple
Tuple<T>: keyof [Source<T>, T]
Type parameters
Variables
Const BASE_FORGETTABLE_BUFFER_SIZE
BASE_FORGETTABLE_BUFFER_SIZE: 5 = 5
Const BASE_FORGETTABLE_NAMES
Const CACHE_VERSION
CACHE_VERSION: 6 = 6
Const DEFAULT_LOCK_FILENAME
DEFAULT_LOCK_FILENAME: string & object = `yarn.lock` as Filename
Const DEFAULT_RC_FILENAME
DEFAULT_RC_FILENAME: string & object = `.yarnrc.yml` as Filename
Const ENVIRONMENT_PREFIX
ENVIRONMENT_PREFIX: "yarn_" = `yarn_`
Const FETCHER_CONCURRENCY
FETCHER_CONCURRENCY: 32 = 32
Const FormatType
Format
Type: Type = formatUtils.Type
Const GROUP
GROUP: null | object = process.env.GITHUB_ACTIONS? {start: (what: string) => `::group::${what}\n`, end: (what: string) => `::endgroup::\n`}: process.env.TRAVIS? {start: (what: string) => `travis_fold:start:${what}\n`, end: (what: string) => `travis_fold:end:${what}\n`}: process.env.GITLAB_CI? {start: (what: string) => `section_start:${Math.floor(Date.now() / 1000)}:${what.toLowerCase().replace(/\W+/g, `_`)}\r\x1b[0K${what}\n`, end: (what: string) => `section_end:${Math.floor(Date.now() / 1000)}:${what.toLowerCase().replace(/\W+/g, `_`)}\r\x1b[0K`}: null
Const IGNORED_ENV_VARIABLES
IGNORED_ENV_VARIABLES: Set<string> = new Set([// "binFolder" is the magic location where the parent process stored the// current binaries; not an actual configuration settings`binFolder`,// "version" is set by Docker:// https://github.com/nodejs/docker-node/blob/5a6a5e91999358c5b04fddd6c22a9a4eb0bf3fbf/10/alpine/Dockerfile#L51`version`,// "flags" is set by Netlify; they use it to specify the flags to send to the// CLI when running the automatic `yarn install``flags`,// "gpg" and "profile" are used by the install.sh script:// https://classic.yarnpkg.com/install.sh`profile`,`gpg`,// "ignoreNode" is used to disable the Node version check`ignoreNode`,// "wrapOutput" was a variable used to indicate nested "yarn run" processes// back in Yarn 1.`wrapOutput`,])
Const IMPORTED_PATTERNS
IMPORTED_PATTERNS: Array<[RegExp, function]> = [// These ones come from Git urls[/^(git(?:\+(?:https|ssh))?:\/\/.*\.git)#(.*)$/, (version, $0, $1, $2) => `${$1}#commit=${$2}`],// These ones come from the GitHub HTTP endpoints[/^https:\/\/((?:[^/]+?)@)?codeload\.github\.com\/([^/]+\/[^/]+)\/tar\.gz\/([0-9a-f]+)$/, (version, $0, $1 = ``, $2, $3) => `https://${$1}github.com/${$2}.git#commit=${$3}`],[/^https:\/\/((?:[^/]+?)@)?github\.com\/([^/]+\/[^/]+?)(?:\.git)?#([0-9a-f]+)$/, (version, $0, $1 = ``, $2, $3) => `https://${$1}github.com/${$2}.git#commit=${$3}`],// These ones come from the npm registry[/^https?:\/\/[^/]+\/(?:@[^/]+\/)?([^/]+)\/-\/\1-[^/]+\.tgz(?:#|$)/, version => `npm:${version}`],// These ones come from the old Yarn offline mirror - we assume they came from npm[/^[^/]+\.tgz#[0-9a-f]+$/, version => `npm:${version}`],]
Const INSTALL_STATE_VERSION
INSTALL_STATE_VERSION: 1 = 1
Const LOCKFILE_VERSION
LOCKFILE_VERSION: 4 = 4
Const MAX_PREPARE_CONCURRENCY
MAX_PREPARE_CONCURRENCY: 2 = 2
Const MULTIPLE_KEYS_REGEXP
MULTIPLE_KEYS_REGEXP: RegExp = / *, */g
Const PROGRESS_FRAMES
PROGRESS_FRAMES: string[] = [`⠋`, `⠙`, `⠹`, `⠸`, `⠼`, `⠴`, `⠦`, `⠧`, `⠇`, `⠏`]
Const PROGRESS_INTERVAL
PROGRESS_INTERVAL: 80 = 80
Const PROGRESS_STYLES
PROGRESS_STYLES: object = makeRecord({patrick: {date: [17, 3],chars: [`🍀`, `🌱`],size: 40,},simba: {date: [19, 7],chars: [`🦁`, `🌴`],size: 40,},jack: {date: [31, 10],chars: [`🎃`, `🦇`],size: 40,},hogsfather: {date: [31, 12],chars: [`🎉`, `🎄`],size: 40,},default: {chars: [`=`, `-`],size: 80,},})
Const SECRET
SECRET: "********" = `********`
Const SPECS
SPECS
: Specs = [// Those three are different from includePrerelease[`^5.0.0`, `5.0.0-beta.13`, true],[`^1.0.0`, `1.0.0-rc1`, true],[`2.x`, `3.0.0-pre.0`, false],// From the semver test-suite...[[`2.x`, `2.0.0-pre.0`, true],[`2.x`, `2.1.0-pre.0`, true],[`1.1.x`, `1.1.0-a`, true],[`1.1.x`, `1.1.1-a`, true],[`*`, `1.0.0-rc1`, true],[`^1.0.0-0`, `1.0.1-rc1`, true],// https://github.com/yarnpkg/berry/pull/1748#discussion_r475268862// [`^1.0.0-rc2`, `1.0.1-rc1`, true],[`^1.0.0`, `1.0.1-rc1`, true],[`^1.0.0`, `1.1.0-rc1`, true],[`1 - 2`, `2.0.0-pre`, true],[`1 - 2`, `1.0.0-pre`, true],[`1.0 - 2`, `1.0.0-pre`, true],[`=0.7.x`, `0.7.0-asdf`, true],[`>=0.7.x`, `0.7.0-asdf`, true],[`<=0.7.x`, `0.7.0-asdf`, true],[`>=1.0.0 <=1.1.0`, `1.1.0-pre`, true],] as Specs,[`^1.0.0`, `2.0.0-rc1`, false],[`^1.2.3-rc2`, `2.0.0`, false],// These are important: false positives with fixed ranges[`1.0.0-alpha.37`, `1.0.0-alpha.39`, false],[`1.0.0-rc2`, `1.0.0-rc4`, false],[`1.0.0-rc4`, `1.0.0-rc2`, false],[`1.0.0-beta.1`, `1.0.0-beta.2`, false],]
Const TAG_REGEXP
TAG_REGEXP: RegExp = /^(?!v)[a-z0-9-.]+$/i
Const TRAILING_SLASH_REGEXP
TRAILING_SLASH_REGEXP: RegExp = /\/$/
Const VIRTUAL_ABBREVIATE
VIRTUAL_ABBREVIATE: 5 = 5
Const VIRTUAL_PROTOCOL
VIRTUAL_PROTOCOL: "virtual:" = `virtual:`
Const YARN_VERSION
YARN_VERSION: string | null
Const YarnVersion
YarnVersion: null | string = typeof YARN_VERSION !== `undefined`? YARN_VERSION: null
__non_webpack_require__
__non_webpack_require__: any
Const cache
cache: Map<string, Buffer | Promise<Buffer>> = new Map<string, Promise<Buffer> | Buffer>()
Const chalkInstance
chalkInstance: Chalk = new chalk.Instance(chalkOptions)
Const chalkOptions
chalkOptions: object = process.env.GITHUB_ACTIONS? {level: 2}: chalk.supportsColor? {level: chalk.supportsColor.level}: {level: 0}
Const colors
colors
: Map<Type, null | (string | number)[]> = new Map([[Type.NO_HINT, null],[Type.NULL, [`#a853b5`, 129]],[Type.SCOPE, [`#d75f00`, 166]],[Type.NAME, [`#d7875f`, 173]],[Type.RANGE, [`#00afaf`, 37]],[Type.REFERENCE, [`#87afff`, 111]],[Type.NUMBER, [`#ffd700`, 220]],[Type.PATH, [`#d75fd7`, 170]],[Type.URL, [`#d75fd7`, 170]],[Type.ADDED, [`#5faf00`, 70]],[Type.REMOVED, [`#d70000`, 160]],[Type.CODE, [`#87afff`, 111]],[Type.SIZE, [`#ffd700`, 220]],])
Const defaultStyle
defaultStyle: string = (supportsEmojis && Object.keys(PROGRESS_STYLES).find(name => {const style = PROGRESS_STYLES[name];if (style.date && (style.date[0] !== now.getDate() || style.date[1] !== now.getMonth() + 1))return false;return true;})) || `default`
Const globalHttpAgent
globalHttpAgent: Agent = new HttpAgent({keepAlive: true})
Const globalHttpsAgent
globalHttpsAgent: Agent = new HttpsAgent({keepAlive: true})
Const gunzip
gunzip: function = promisify(zlib.gunzip)
Type declaration
-
- (arg1: T1): Promise<TResult>
-
Parameters
Returns Promise<TResult>
Const gunzip
gunzip: function = promisify(zlib.gunzip)
Type declaration
-
- (arg1: T1): Promise<TResult>
-
Parameters
Returns Promise<TResult>
Const gzip
gzip: function = promisify(zlib.gzip)
Type declaration
-
- (arg1: T1): Promise<TResult>
-
Parameters
Returns Promise<TResult>
Const mapAndFilterSkip
mapAndFilterSkip: unique symbol = Symbol()
Const mapAndFindSkip
mapAndFindSkip: unique symbol = Symbol()
Const now
now: Date = new Date()
Const prepareLimit
prepareLimit: Limit = pLimit(MAX_PREPARE_CONCURRENCY)
Const rangesCache
rangesCache: Map<string, null | Range> = new Map<string, semver.Range | null>()
Let sigintRefCount
sigintRefCount: number = 0
Const signalToCodeMap
signalToCodeMap: Map<null | "SIGABRT" | "SIGALRM" | "SIGBUS" | "SIGCHLD" | "SIGCONT" | "SIGFPE" | "SIGHUP" | "SIGILL" | "SIGINT" | "SIGIO" | "SIGIOT" | "SIGKILL" | "SIGPIPE" | "SIGPOLL" | "SIGPROF" | "SIGPWR" | "SIGQUIT" | "SIGSEGV" | "SIGSTKFLT" | "SIGSTOP" | "SIGSYS" | "SIGTERM" | "SIGTRAP" | "SIGTSTP" | "SIGTTIN" | "SIGTTOU" | "SIGUNUSED" | "SIGURG" | "SIGUSR1" | "SIGUSR2" | "SIGVTALRM" | "SIGWINCH" | "SIGXCPU" | "SIGXFSZ" | "SIGBREAK" | "SIGLOST" | "SIGINFO", number> = new Map<NodeJS.Signals | null, number>([[`SIGINT`, 2], // ctrl-c[`SIGQUIT`, 3], // ctrl-\[`SIGKILL`, 9], // hard kill[`SIGTERM`, 15], // default signal for kill])
Const supportsColor
supportsColor: boolean = chalkOptions.level !== 0
Const supportsEmojis
supportsEmojis: boolean = [`iTerm.app`, `Apple_Terminal`].includes(process.env.TERM_PROGRAM!) || !!process.env.WT_SESSION
Const supportsHyperlinks
supportsHyperlinks: boolean = supportsColor && !process.env.GITHUB_ACTIONS
The checksum for the fetch result.