diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-10-02 12:20:26 +0200 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-10-03 15:31:26 +0200 |
commit | 40298b02546e8225dd21bf6048fe7f224aefc32a (patch) | |
tree | 0a0b981dbeb2af47810adff6553a0df995a03734 /server/helpers/core-utils.ts | |
parent | f0adb2701c1cf404ff63095f71e542bfe6d025ae (diff) | |
download | PeerTube-40298b02546e8225dd21bf6048fe7f224aefc32a.tar.gz PeerTube-40298b02546e8225dd21bf6048fe7f224aefc32a.tar.zst PeerTube-40298b02546e8225dd21bf6048fe7f224aefc32a.zip |
Implement video transcoding on server side
Diffstat (limited to 'server/helpers/core-utils.ts')
-rw-r--r-- | server/helpers/core-utils.ts | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/server/helpers/core-utils.ts b/server/helpers/core-utils.ts index 2ec7e6515..3118dc500 100644 --- a/server/helpers/core-utils.ts +++ b/server/helpers/core-utils.ts | |||
@@ -11,7 +11,9 @@ import { | |||
11 | rename, | 11 | rename, |
12 | unlink, | 12 | unlink, |
13 | writeFile, | 13 | writeFile, |
14 | access | 14 | access, |
15 | stat, | ||
16 | Stats | ||
15 | } from 'fs' | 17 | } from 'fs' |
16 | import * as mkdirp from 'mkdirp' | 18 | import * as mkdirp from 'mkdirp' |
17 | import * as bcrypt from 'bcrypt' | 19 | import * as bcrypt from 'bcrypt' |
@@ -92,6 +94,7 @@ const bcryptGenSaltPromise = promisify1<number, string>(bcrypt.genSalt) | |||
92 | const bcryptHashPromise = promisify2<any, string|number, string>(bcrypt.hash) | 94 | const bcryptHashPromise = promisify2<any, string|number, string>(bcrypt.hash) |
93 | const createTorrentPromise = promisify2<string, any, any>(createTorrent) | 95 | const createTorrentPromise = promisify2<string, any, any>(createTorrent) |
94 | const rimrafPromise = promisify1WithVoid<string>(rimraf) | 96 | const rimrafPromise = promisify1WithVoid<string>(rimraf) |
97 | const statPromise = promisify1<string, Stats>(stat) | ||
95 | 98 | ||
96 | // --------------------------------------------------------------------------- | 99 | // --------------------------------------------------------------------------- |
97 | 100 | ||
@@ -115,5 +118,6 @@ export { | |||
115 | bcryptGenSaltPromise, | 118 | bcryptGenSaltPromise, |
116 | bcryptHashPromise, | 119 | bcryptHashPromise, |
117 | createTorrentPromise, | 120 | createTorrentPromise, |
118 | rimrafPromise | 121 | rimrafPromise, |
122 | statPromise | ||
119 | } | 123 | } |