Search
Preparing search index...
The search index is not available
Yarn API
Home
Configuration
Features
CLI
Advanced
GitHub
Options
All
Public
Public/Protected
All
Inherited
Externals
Only exported
Menu
.pnp
PosixFS
Globals
{"Generic Packages":{"@yarnpkg/core":"yarnpkg_core","@yarnpkg/fslib":"yarnpkg_fslib","@yarnpkg/libzip":"yarnpkg_libzip","@yarnpkg/nm":"yarnpkg_nm","@yarnpkg/parsers":"yarnpkg_parsers","@yarnpkg/pnp":"yarnpkg_pnp","@yarnpkg/pnpify":"yarnpkg_pnpify","@yarnpkg/sdks":"yarnpkg_sdks","@yarnpkg/shell":"yarnpkg_shell"},"Yarn Packages":{"@yarnpkg/builder":"yarnpkg_builder","@yarnpkg/cli":"yarnpkg_cli"},"Default Plugins":{"@yarnpkg/plugin-compat":"plugin_compat","@yarnpkg/plugin-dlx":"plugin_dlx","@yarnpkg/plugin-essentials":"plugin_essentials","@yarnpkg/plugin-file":"plugin_file","@yarnpkg/plugin-git":"plugin_git","@yarnpkg/plugin-github":"plugin_github","@yarnpkg/plugin-http":"plugin_http","@yarnpkg/plugin-init":"plugin_init","@yarnpkg/plugin-link":"plugin_link","@yarnpkg/plugin-nm":"plugin_nm","@yarnpkg/plugin-npm":"plugin_npm","@yarnpkg/plugin-npm-cli":"plugin_npm_cli","@yarnpkg/plugin-pack":"plugin_pack","@yarnpkg/plugin-patch":"plugin_patch","@yarnpkg/plugin-pnp":"plugin_pnp"},"Contrib Plugins":{"@yarnpkg/plugin-constraints":"plugin_constraints","@yarnpkg/plugin-exec":"plugin_exec","@yarnpkg/plugin-interactive-tools":"plugin_interactive_tools","@yarnpkg/plugin-stage":"plugin_stage","@yarnpkg/plugin-typescript":"plugin_typescript","@yarnpkg/plugin-version":"plugin_version","@yarnpkg/plugin-workspace-tools":"plugin_workspace_tools"}}
Class PosixFS
Hierarchy
ProxiedFS
PosixFS
Constructors
constructor
Methods
accessPromise
accessSync
appendFilePromise
appendFileSync
changeFileBufferPromise
changeFileBufferSync
changeFilePromise
changeFileSync
changeFileTextPromise
changeFileTextSync
checksumFilePromise
chmodPromise
chmodSync
chownPromise
chownSync
closePromise
closeSync
copyFilePromise
copyFileSync
copyPromise
copySync
createReadStream
createWriteStream
existsPromise
existsSync
fchmodPromise
fchmodSync
fchownPromise
fchownSync
fsMapToBase
fstatPromise
fstatSync
ftruncatePromise
ftruncateSync
genTraversePromise
getExtractHint
getRealPath
linkPromise
linkSync
lockPromise
lstatPromise
lstatSync
lutimesPromise
lutimesSync
mapFromBase
mapToBase
mkdirPromise
mkdirSync
mkdirpPromise
mkdirpSync
movePromise
moveSync
openPromise
openSync
opendirPromise
opendirSync
preserveTimePromise
preserveTimeSync
readFilePromise
readFileSync
readJsonPromise
readJsonSync
readPromise
readSync
readdirPromise
readdirSync
readlinkPromise
readlinkSync
realpathPromise
realpathSync
removePromise
removeSync
renamePromise
renameSync
resolve
rmdirPromise
rmdirSync
statPromise
statSync
symlinkPromise
symlinkSync
truncatePromise
truncateSync
unlinkPromise
unlinkSync
unwatchFile
utimesPromise
utimesSync
watch
watchFile
writeFilePromise
writeFileSync
writeJsonPromise
writeJsonSync
writePromise
writeSync
Constructors
constructor
new
PosixFS
(
baseFs
:
any
)
:
PosixFS
Parameters
baseFs:
any
Returns
PosixFS
Methods
access
Promise
access
Promise
(
p
:
any
, mode
:
any
)
:
Promise
<
any
>
Parameters
p:
any
mode:
any
Returns
Promise
<
any
>
access
Sync
access
Sync
(
p
:
any
, mode
:
any
)
:
any
Parameters
p:
any
mode:
any
Returns
any
append
File
Promise
append
File
Promise
(
p
:
any
, content
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
content:
any
opts:
any
Returns
Promise
<
any
>
append
File
Sync
append
File
Sync
(
p
:
any
, content
:
any
, opts
:
any
)
:
any
Parameters
p:
any
content:
any
opts:
any
Returns
any
change
File
Buffer
Promise
change
File
Buffer
Promise
(
p
:
any
, content
:
any
, __namedParameters
?:
object
)
:
Promise
<
void
>
Parameters
p:
any
content:
any
Default value
__namedParameters:
object
= {}
mode
:
any
Returns
Promise
<
void
>
change
File
Buffer
Sync
change
File
Buffer
Sync
(
p
:
any
, content
:
any
, __namedParameters
?:
object
)
:
void
Parameters
p:
any
content:
any
Default value
__namedParameters:
object
= {}
mode
:
any
Returns
void
change
File
Promise
change
File
Promise
(
p
:
any
, content
:
any
, opts
?:
object
)
:
Promise
<
void
>
Parameters
p:
any
content:
any
Default value
opts:
object
= {}
Returns
Promise
<
void
>
change
File
Sync
change
File
Sync
(
p
:
any
, content
:
any
, opts
?:
object
)
:
void
Parameters
p:
any
content:
any
Default value
opts:
object
= {}
Returns
void
change
File
Text
Promise
change
File
Text
Promise
(
p
:
any
, content
:
any
, __namedParameters
?:
object
)
:
Promise
<
void
>
Parameters
p:
any
content:
any
Default value
__namedParameters:
object
= {}
automatic
Newlines
:
any
mode
:
any
Returns
Promise
<
void
>
change
File
Text
Sync
change
File
Text
Sync
(
p
:
any
, content
:
any
, __namedParameters
?:
object
)
:
void
Parameters
p:
any
content:
any
Default value
__namedParameters:
object
= {}
automatic
Newlines
:
boolean
mode
:
any
Returns
void
checksum
File
Promise
checksum
File
Promise
(
path
:
any
, __namedParameters
?:
object
)
:
Promise
<
string
>
Parameters
path:
any
Default value
__namedParameters:
object
= {}
algorithm
:
string
Returns
Promise
<
string
>
chmod
Promise
chmod
Promise
(
p
:
any
, mask
:
any
)
:
Promise
<
any
>
Parameters
p:
any
mask:
any
Returns
Promise
<
any
>
chmod
Sync
chmod
Sync
(
p
:
any
, mask
:
any
)
:
any
Parameters
p:
any
mask:
any
Returns
any
chown
Promise
chown
Promise
(
p
:
any
, uid
:
any
, gid
:
any
)
:
Promise
<
any
>
Parameters
p:
any
uid:
any
gid:
any
Returns
Promise
<
any
>
chown
Sync
chown
Sync
(
p
:
any
, uid
:
any
, gid
:
any
)
:
any
Parameters
p:
any
uid:
any
gid:
any
Returns
any
close
Promise
close
Promise
(
fd
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
Returns
Promise
<
any
>
close
Sync
close
Sync
(
fd
:
any
)
:
void
Parameters
fd:
any
Returns
void
copy
File
Promise
copy
File
Promise
(
sourceP
:
any
, destP
:
any
, flags
?:
number
)
:
Promise
<
any
>
Parameters
sourceP:
any
destP:
any
Default value
flags:
number
= 0
Returns
Promise
<
any
>
copy
File
Sync
copy
File
Sync
(
sourceP
:
any
, destP
:
any
, flags
?:
number
)
:
any
Parameters
sourceP:
any
destP:
any
Default value
flags:
number
= 0
Returns
any
copy
Promise
copy
Promise
(
destination
:
any
, source
:
any
, __namedParameters
?:
object
)
:
Promise
<
void
>
Parameters
destination:
any
source:
any
Default value
__namedParameters:
object
= {}
base
Fs
:
this
link
Strategy
:
null
overwrite
:
boolean
stable
Sort
:
boolean
stable
Time
:
boolean
Returns
Promise
<
void
>
copy
Sync
copy
Sync
(
destination
:
any
, source
:
any
, __namedParameters
?:
object
)
:
void
Parameters
destination:
any
source:
any
Default value
__namedParameters:
object
= {}
base
Fs
:
this
overwrite
:
boolean
Returns
void
create
Read
Stream
create
Read
Stream
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
create
Write
Stream
create
Write
Stream
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
exists
Promise
exists
Promise
(
p
:
any
)
:
Promise
<
any
>
Parameters
p:
any
Returns
Promise
<
any
>
exists
Sync
exists
Sync
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
fchmod
Promise
fchmod
Promise
(
fd
:
any
, mask
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
mask:
any
Returns
Promise
<
any
>
fchmod
Sync
fchmod
Sync
(
fd
:
any
, mask
:
any
)
:
any
Parameters
fd:
any
mask:
any
Returns
any
fchown
Promise
fchown
Promise
(
fd
:
any
, uid
:
any
, gid
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
uid:
any
gid:
any
Returns
Promise
<
any
>
fchown
Sync
fchown
Sync
(
fd
:
any
, uid
:
any
, gid
:
any
)
:
any
Parameters
fd:
any
uid:
any
gid:
any
Returns
any
fs
Map
ToBase
fs
Map
ToBase
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
fstat
Promise
fstat
Promise
(
fd
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
opts:
any
Returns
Promise
<
any
>
fstat
Sync
fstat
Sync
(
fd
:
any
, opts
:
any
)
:
any
Parameters
fd:
any
opts:
any
Returns
any
ftruncate
Promise
ftruncate
Promise
(
fd
:
any
, len
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
len:
any
Returns
Promise
<
any
>
ftruncate
Sync
ftruncate
Sync
(
fd
:
any
, len
:
any
)
:
any
Parameters
fd:
any
len:
any
Returns
any
gen
Traverse
Promise
gen
Traverse
Promise
(
init
:
any
, __namedParameters
?:
object
)
:
AsyncGenerator
<
any
,
void
,
unknown
>
Parameters
init:
any
Default value
__namedParameters:
object
= {}
stable
Sort
:
boolean
Returns
AsyncGenerator
<
any
,
void
,
unknown
>
get
Extract
Hint
get
Extract
Hint
(
hints
:
any
)
:
any
Parameters
hints:
any
Returns
any
get
Real
Path
get
Real
Path
(
)
:
any
Returns
any
link
Promise
link
Promise
(
existingP
:
any
, newP
:
any
)
:
Promise
<
any
>
Parameters
existingP:
any
newP:
any
Returns
Promise
<
any
>
link
Sync
link
Sync
(
existingP
:
any
, newP
:
any
)
:
any
Parameters
existingP:
any
newP:
any
Returns
any
lock
Promise
lock
Promise
(
affectedPath
:
any
, callback
:
any
)
:
Promise
<
any
>
Parameters
affectedPath:
any
callback:
any
Returns
Promise
<
any
>
lstat
Promise
lstat
Promise
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
lstat
Sync
lstat
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
lutimes
Promise
lutimes
Promise
(
p
:
any
, atime
:
any
, mtime
:
any
)
:
Promise
<
any
>
Parameters
p:
any
atime:
any
mtime:
any
Returns
Promise
<
any
>
lutimes
Sync
lutimes
Sync
(
p
:
any
, atime
:
any
, mtime
:
any
)
:
any
Parameters
p:
any
atime:
any
mtime:
any
Returns
any
map
From
Base
map
From
Base
(
path
:
any
)
:
any
Parameters
path:
any
Returns
any
map
ToBase
map
ToBase
(
path
:
any
)
:
any
Parameters
path:
any
Returns
any
mkdir
Promise
mkdir
Promise
(
p
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
opts:
any
Returns
Promise
<
any
>
mkdir
Sync
mkdir
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
mkdirp
Promise
mkdirp
Promise
(
p
:
any
, __namedParameters
?:
object
)
:
Promise
<
any
>
Parameters
p:
any
Default value
__namedParameters:
object
= {}
chmod
:
any
utimes
:
any
Returns
Promise
<
any
>
mkdirp
Sync
mkdirp
Sync
(
p
:
any
, __namedParameters
?:
object
)
:
any
Parameters
p:
any
Default value
__namedParameters:
object
= {}
chmod
:
any
utimes
:
any
Returns
any
move
Promise
move
Promise
(
fromP
:
any
, toP
:
any
)
:
Promise
<
void
>
Parameters
fromP:
any
toP:
any
Returns
Promise
<
void
>
move
Sync
move
Sync
(
fromP
:
any
, toP
:
any
)
:
void
Parameters
fromP:
any
toP:
any
Returns
void
open
Promise
open
Promise
(
p
:
any
, flags
:
any
, mode
:
any
)
:
Promise
<
any
>
Parameters
p:
any
flags:
any
mode:
any
Returns
Promise
<
any
>
open
Sync
open
Sync
(
p
:
any
, flags
:
any
, mode
:
any
)
:
any
Parameters
p:
any
flags:
any
mode:
any
Returns
any
opendir
Promise
opendir
Promise
(
p
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
opts:
any
Returns
Promise
<
any
>
opendir
Sync
opendir
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
preserve
Time
Promise
preserve
Time
Promise
(
p
:
any
, cb
:
any
)
:
Promise
<
void
>
Parameters
p:
any
cb:
any
Returns
Promise
<
void
>
preserve
Time
Sync
preserve
Time
Sync
(
p
:
any
, cb
:
any
)
:
Promise
<
void
>
Parameters
p:
any
cb:
any
Returns
Promise
<
void
>
read
File
Promise
read
File
Promise
(
p
:
any
, encoding
:
any
)
:
Promise
<
any
>
Parameters
p:
any
encoding:
any
Returns
Promise
<
any
>
read
File
Sync
read
File
Sync
(
p
:
any
, encoding
:
any
)
:
any
Parameters
p:
any
encoding:
any
Returns
any
read
Json
Promise
read
Json
Promise
(
p
:
any
)
:
Promise
<
any
>
Parameters
p:
any
Returns
Promise
<
any
>
read
Json
Sync
read
Json
Sync
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
read
Promise
read
Promise
(
fd
:
any
, buffer
:
any
, offset
:
any
, length
:
any
, position
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
buffer:
any
offset:
any
length:
any
position:
any
Returns
Promise
<
any
>
read
Sync
read
Sync
(
fd
:
any
, buffer
:
any
, offset
:
any
, length
:
any
, position
:
any
)
:
any
Parameters
fd:
any
buffer:
any
offset:
any
length:
any
position:
any
Returns
any
readdir
Promise
readdir
Promise
(
p
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
opts:
any
Returns
Promise
<
any
>
readdir
Sync
readdir
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
readlink
Promise
readlink
Promise
(
p
:
any
)
:
Promise
<
any
>
Parameters
p:
any
Returns
Promise
<
any
>
readlink
Sync
readlink
Sync
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
realpath
Promise
realpath
Promise
(
p
:
any
)
:
Promise
<
any
>
Parameters
p:
any
Returns
Promise
<
any
>
realpath
Sync
realpath
Sync
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
remove
Promise
remove
Promise
(
p
:
any
, __namedParameters
?:
object
)
:
Promise
<
void
>
Parameters
p:
any
Default value
__namedParameters:
object
= {}
max
Retries
:
number
recursive
:
boolean
Returns
Promise
<
void
>
remove
Sync
remove
Sync
(
p
:
any
, __namedParameters
?:
object
)
:
void
Parameters
p:
any
Default value
__namedParameters:
object
= {}
recursive
:
boolean
Returns
void
rename
Promise
rename
Promise
(
oldP
:
any
, newP
:
any
)
:
Promise
<
any
>
Parameters
oldP:
any
newP:
any
Returns
Promise
<
any
>
rename
Sync
rename
Sync
(
oldP
:
any
, newP
:
any
)
:
any
Parameters
oldP:
any
newP:
any
Returns
any
resolve
resolve
(
path
:
any
)
:
any
Parameters
path:
any
Returns
any
rmdir
Promise
rmdir
Promise
(
p
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
opts:
any
Returns
Promise
<
any
>
rmdir
Sync
rmdir
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
stat
Promise
stat
Promise
(
p
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
opts:
any
Returns
Promise
<
any
>
stat
Sync
stat
Sync
(
p
:
any
, opts
:
any
)
:
any
Parameters
p:
any
opts:
any
Returns
any
symlink
Promise
symlink
Promise
(
target
:
any
, p
:
any
, type
:
any
)
:
Promise
<
any
>
Parameters
target:
any
p:
any
type:
any
Returns
Promise
<
any
>
symlink
Sync
symlink
Sync
(
target
:
any
, p
:
any
, type
:
any
)
:
any
Parameters
target:
any
p:
any
type:
any
Returns
any
truncate
Promise
truncate
Promise
(
p
:
any
, len
:
any
)
:
Promise
<
any
>
Parameters
p:
any
len:
any
Returns
Promise
<
any
>
truncate
Sync
truncate
Sync
(
p
:
any
, len
:
any
)
:
any
Parameters
p:
any
len:
any
Returns
any
unlink
Promise
unlink
Promise
(
p
:
any
)
:
Promise
<
any
>
Parameters
p:
any
Returns
Promise
<
any
>
unlink
Sync
unlink
Sync
(
p
:
any
)
:
any
Parameters
p:
any
Returns
any
unwatch
File
unwatch
File
(
p
:
any
, cb
:
any
)
:
any
Parameters
p:
any
cb:
any
Returns
any
utimes
Promise
utimes
Promise
(
p
:
any
, atime
:
any
, mtime
:
any
)
:
Promise
<
any
>
Parameters
p:
any
atime:
any
mtime:
any
Returns
Promise
<
any
>
utimes
Sync
utimes
Sync
(
p
:
any
, atime
:
any
, mtime
:
any
)
:
any
Parameters
p:
any
atime:
any
mtime:
any
Returns
any
watch
watch
(
p
:
any
, a
:
any
, b
:
any
)
:
any
Parameters
p:
any
a:
any
b:
any
Returns
any
watch
File
watch
File
(
p
:
any
, a
:
any
, b
:
any
)
:
any
Parameters
p:
any
a:
any
b:
any
Returns
any
write
File
Promise
write
File
Promise
(
p
:
any
, content
:
any
, opts
:
any
)
:
Promise
<
any
>
Parameters
p:
any
content:
any
opts:
any
Returns
Promise
<
any
>
write
File
Sync
write
File
Sync
(
p
:
any
, content
:
any
, opts
:
any
)
:
any
Parameters
p:
any
content:
any
opts:
any
Returns
any
write
Json
Promise
write
Json
Promise
(
p
:
any
, data
:
any
)
:
Promise
<
any
>
Parameters
p:
any
data:
any
Returns
Promise
<
any
>
write
Json
Sync
write
Json
Sync
(
p
:
any
, data
:
any
)
:
any
Parameters
p:
any
data:
any
Returns
any
write
Promise
write
Promise
(
fd
:
any
, buffer
:
any
, offset
:
any
, length
:
any
, position
:
any
)
:
Promise
<
any
>
Parameters
fd:
any
buffer:
any
offset:
any
length:
any
position:
any
Returns
Promise
<
any
>
write
Sync
write
Sync
(
fd
:
any
, buffer
:
any
, offset
:
any
, length
:
any
, position
:
any
)
:
any
Parameters
fd:
any
buffer:
any
offset:
any
length:
any
position:
any
Returns
any
".pnp"
PosixFS
constructor
access
Promise
access
Sync
append
File
Promise
append
File
Sync
change
File
Buffer
Promise
change
File
Buffer
Sync
change
File
Promise
change
File
Sync
change
File
Text
Promise
change
File
Text
Sync
checksum
File
Promise
chmod
Promise
chmod
Sync
chown
Promise
chown
Sync
close
Promise
close
Sync
copy
File
Promise
copy
File
Sync
copy
Promise
copy
Sync
create
Read
Stream
create
Write
Stream
exists
Promise
exists
Sync
fchmod
Promise
fchmod
Sync
fchown
Promise
fchown
Sync
fs
Map
ToBase
fstat
Promise
fstat
Sync
ftruncate
Promise
ftruncate
Sync
gen
Traverse
Promise
get
Extract
Hint
get
Real
Path
link
Promise
link
Sync
lock
Promise
lstat
Promise
lstat
Sync
lutimes
Promise
lutimes
Sync
map
From
Base
map
ToBase
mkdir
Promise
mkdir
Sync
mkdirp
Promise
mkdirp
Sync
move
Promise
move
Sync
open
Promise
open
Sync
opendir
Promise
opendir
Sync
preserve
Time
Promise
preserve
Time
Sync
read
File
Promise
read
File
Sync
read
Json
Promise
read
Json
Sync
read
Promise
read
Sync
readdir
Promise
readdir
Sync
readlink
Promise
readlink
Sync
realpath
Promise
realpath
Sync
remove
Promise
remove
Sync
rename
Promise
rename
Sync
resolve
rmdir
Promise
rmdir
Sync
stat
Promise
stat
Sync
symlink
Promise
symlink
Sync
truncate
Promise
truncate
Sync
unlink
Promise
unlink
Sync
unwatch
File
utimes
Promise
utimes
Sync
watch
watch
File
write
File
Promise
write
File
Sync
write
Json
Promise
write
Json
Sync
write
Promise
write
Sync
Generated using
TypeDoc