UNPKG

2.51 kBMarkdownView Raw
1# Installation
2> `npm install --save @types/move-concurrently`
3
4# Summary
5This package contains type definitions for move-concurrently (https://www.npmjs.com/package/move-concurrently).
6
7# Details
8Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/move-concurrently.
9## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/move-concurrently/index.d.ts)
10````ts
11// Type definitions for move-concurrently 1.0
12// Project: https://www.npmjs.com/package/move-concurrently
13// Definitions by: Melvin Groenhoff <https://github.com/mgroenhoff>
14// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
15// TypeScript Version: 3.2
16
17/**
18 * Recursively moves from to to and resolves its promise when finished. If to already exists then the promise will be rejected with an EEXIST error.
19 */
20declare function move<T extends PromiseLike<void> = Promise<void>>(from: string, to: string, opts?: move.Options<T>): T;
21
22declare namespace move {
23 interface Options<T extends PromiseLike<void> = Promise<void>> {
24 /**
25 * (Default: 1) The maximum number of concurrent copies to do at once.
26 */
27 maxConcurrency?: number | undefined;
28 /**
29 * (Default: process.platform === 'win32') If true enables Windows symlink semantics.
30 * This requires an extra stat to determine if the destination of a symlink is a file or directory.
31 * If symlinking a directory fails then we'll try making a junction instead.
32 */
33 isWindows?: boolean | undefined;
34 /**
35 * (Default: global.Promise) The promise implementation to use, defaults to Node's.
36 */
37 Promise?: (new (...args: any[]) => T | undefined) | undefined;
38 /**
39 * (Default: require('fs')) The filesystem module to use. Can be used to use graceful-fs or to inject a mock.
40 */
41 fs?: any;
42 /**
43 * (Default: require('fs-write-stream-atomic')) The implementation of writeStreamAtomic to use. Used to inject a mock.
44 */
45 writeStreamAtomic?: any;
46 /**
47 * (Default: process.getuid) A function that returns the current UID. Used to inject a mock.
48 */
49 getuid?: any;
50 }
51}
52
53export = move;
54
55````
56
57### Additional Details
58 * Last updated: Wed, 07 Jul 2021 16:31:27 GMT
59 * Dependencies: none
60 * Global values: none
61
62# Credits
63These definitions were written by [Melvin Groenhoff](https://github.com/mgroenhoff).
64
\No newline at end of file