콘텐츠로 이동

copyFile

이 콘텐츠는 아직 번역되지 않았습니다.

Module @netwiv/api/plugins/fs · Kind Function

import { copyFile } from '@netwiv/api/plugins/fs';

Copies the contents and permissions of one file to another specified path, by default creating a new file if needed, else overwriting.

function copyFile(fromPath: string | URL, toPath: string | URL, options?: CopyFileOptions | undefined): Promise<void>
import { copyFile, BaseDirectory } from '@netwiv/api/plugins/fs';
await copyFile('app.conf', 'app.conf.bk', { fromPathBaseDir: BaseDirectory.AppConfig, toPathBaseDir: BaseDirectory.AppConfig });

Upstream since 2.0.0


Descriptions come from the pinned @tauri-apps/plugin-fs@2.5.2 declarations (MIT OR Apache-2.0); imports are shown with @netwiv/api paths.