diff options
author | Alex Browne <stephenalexbrowne@gmail.com> | 2018-11-09 02:15:09 +0800 |
---|---|---|
committer | Fred Carlsen <fred@sjelfull.no> | 2018-12-06 19:04:24 +0800 |
commit | 012134001a3f0f60c938c453dc34d78e83e195c1 (patch) | |
tree | 337d99b3236e700f8163e01f146d29095d3e041c /packages/pipeline/src/ormconfig.ts | |
parent | 0f869b0545d18863414ba4d5cc0c2aeb4da700db (diff) | |
download | dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar.gz dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar.bz2 dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar.lz dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar.xz dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.tar.zst dexon-sol-tools-012134001a3f0f60c938c453dc34d78e83e195c1.zip |
Reorganize entities. Make scripts work from any directory.
Diffstat (limited to 'packages/pipeline/src/ormconfig.ts')
-rw-r--r-- | packages/pipeline/src/ormconfig.ts | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/packages/pipeline/src/ormconfig.ts b/packages/pipeline/src/ormconfig.ts index eaafeb7d5..39b496ace 100644 --- a/packages/pipeline/src/ormconfig.ts +++ b/packages/pipeline/src/ormconfig.ts @@ -1,11 +1,31 @@ import { ConnectionOptions } from 'typeorm'; +import { + Block, + ExchangeCancelEvent, + ExchangeCancelUpToEvent, + ExchangeFillEvent, + Relayer, + SraOrder, + Transaction, +} from './entities'; + +const entities = [ + Block, + ExchangeCancelEvent, + ExchangeCancelUpToEvent, + ExchangeFillEvent, + Relayer, + SraOrder, + Transaction, +]; + export const testConfig: ConnectionOptions = { type: 'sqlite', database: 'database.sqlite', synchronize: true, logging: false, - entities: ['./lib/src/entities/**/*.js'], + entities, migrations: ['./lib/src/migrations/**/*.js'], cli: { entitiesDir: 'lib/src/entities', @@ -18,7 +38,7 @@ export const deployConfig: ConnectionOptions = { url: process.env.ZEROEX_DATA_PIPELINE_DB_URL, synchronize: true, logging: false, - entities: ['./lib/src/entities/**/*.js'], + entities, migrations: ['./lib/src/migrations/**/*.js'], cli: { entitiesDir: 'lib/src/entities', |