diff options
author | Chocobozzz <me@florianbigard.com> | 2019-10-21 17:13:07 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-10-21 17:13:22 +0200 |
commit | 2aaa1a3fdc49be77aec5309dab5507865c38d392 (patch) | |
tree | bc83c5b1ff49faf03461c78a110e0a5613343c31 /server.ts | |
parent | 576ddf645ff2223126d28ef172bb6388602c35f4 (diff) | |
download | PeerTube-2aaa1a3fdc49be77aec5309dab5507865c38d392.tar.gz PeerTube-2aaa1a3fdc49be77aec5309dab5507865c38d392.tar.zst PeerTube-2aaa1a3fdc49be77aec5309dab5507865c38d392.zip |
Use typescript paths in cli scripts too
Diffstat (limited to 'server.ts')
-rw-r--r-- | server.ts | 11 |
1 files changed, 2 insertions, 9 deletions
@@ -1,13 +1,6 @@ | |||
1 | import { resolve } from 'path' | 1 | import { registerTSPaths } from './server/helpers/register-ts-paths' |
2 | 2 | ||
3 | const tsConfig = require('./tsconfig.json') | 3 | registerTSPaths() |
4 | const tsConfigPaths = require('tsconfig-paths') | ||
5 | |||
6 | // Thanks: https://github.com/dividab/tsconfig-paths/issues/75#issuecomment-458936883 | ||
7 | tsConfigPaths.register({ | ||
8 | baseUrl: resolve(tsConfig.compilerOptions.baseUrl || '', tsConfig.compilerOptions.outDir || ''), | ||
9 | paths: tsConfig.compilerOptions.paths | ||
10 | }) | ||
11 | 4 | ||
12 | // FIXME: https://github.com/nodejs/node/pull/16853 | 5 | // FIXME: https://github.com/nodejs/node/pull/16853 |
13 | require('tls').DEFAULT_ECDH_CURVE = 'auto' | 6 | require('tls').DEFAULT_ECDH_CURVE = 'auto' |