Skip to content

Latest commit

 

History

History
94 lines (47 loc) · 1.85 KB

File metadata and controls

94 lines (47 loc) · 1.85 KB
hide_title true
custom_edit_url
pagination_prev
pagination_next

Home > @rushstack/node-core-library > AlreadyExistsBehavior

AlreadyExistsBehavior enum

Specifies the behavior of APIs such as FileSystem.copyFile() or FileSystem.createSymbolicLinkFile() when the output file path already exists.

Signature:

export declare enum AlreadyExistsBehavior 

Enumeration Members

Member

Value

Description

Error

"error"

If the output file path already exists, the operation will fail, and an error will be reported.

Ignore

"ignore"

If the output file path already exists, skip this item, and continue the operation.

Overwrite

"overwrite"

If the output file path already exists, try to overwrite the existing object.

Remarks

For FileSystem.copyFile() and related APIs, the "output file path" is IFileSystemCopyFileOptions.destinationPath<></>.

For FileSystem.createSymbolicLinkFile() and related APIs, the "output file path" is IFileSystemCreateLinkOptions.newLinkPath<></>.