Skip to content

Latest commit

 

History

History
47 lines (25 loc) · 911 Bytes

File metadata and controls

47 lines (25 loc) · 911 Bytes

@google-github-actions/actions-utils


@google-github-actions/actions-utils / fs / writeSecureFile

Function: writeSecureFile()

writeSecureFile<T>(outputPath, data, options?): Promise<T>

Defined in: fs.ts:68

writeSecureFile writes a file to disk with 0600 permissions and locks the file during writing.

Type Parameters

T

T extends PathLike

Parameters

outputPath

T

Path in which to create the secure file.

data

Data to write to file.

string | Buffer<ArrayBufferLike>

options?

ObjectEncodingOptions & object

additional options to pass to writeFile. The default options are permissions of 0600, write-exclusive, and flush-on-success.

Returns

Promise<T>

Path to written file.