-
Notifications
You must be signed in to change notification settings - Fork 4
/
methods.js
84 lines (81 loc) · 1.41 KB
/
methods.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
/**
* Methods to wrap.
*/
/*
// to regenerate this list (in case fs-extra adds more functions)
var methods = []
var fs = require('fs-extra');
for (var key in fs) {
if (typeof fs[key] === 'function'
&& key.substr(-6) !== 'Stream'
&& key.substr(0, 5) !== 'grace'
&& !~key.indexOf('watch')
&& key[0] !== '_'
&& key !== 'exists'
&& key !== 'Stats'
&& key.substr(-4) !== 'Sync') {
var txt = fs[key].toString()
var l1 = txt.substr(0, txt.indexOf('\n'))
if (~l1.indexOf('callback') || ~l1.indexOf('cb)'))
methods.push(key)
else console.log(key, fs[key].toString())
}
}
console.log('module.exports = ' + JSON.stringify(methods.sort(), null, ' ').replace(/"/g, '\''))
*/
module.exports = [
'access',
'appendFile',
'chmod',
'chown',
'close',
'copy',
'createFile',
'createLink',
'createSymlink',
'emptyDir',
'emptydir',
'ensureDir',
'ensureFile',
'ensureLink',
'ensureSymlink',
'fchmod',
'fchown',
'fdatasync',
'fstat',
'fsync',
'ftruncate',
'futimes',
'lchmod',
'lchown',
'link',
'lstat',
'lutimes',
'mkdir',
'mkdirp',
'mkdirs',
'move',
'open',
'outputFile',
'outputJSON',
'outputJson',
'read',
'readFile',
'readJSON',
'readJson',
'readdir',
'readlink',
'realpath',
'remove',
'rename',
'rmdir',
'stat',
'symlink',
'truncate',
'unlink',
'utimes',
'write',
'writeFile',
'writeJSON',
'writeJson'
]