-
Notifications
You must be signed in to change notification settings - Fork 1
/
taskHandler.ts
33 lines (30 loc) · 980 Bytes
/
taskHandler.ts
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
import { SUPPORTED_NETWORKS } from './scripts/constants/supportedNetworks'
import {
DEPLOY_LIMITPOOL,
DEPLOY_FINTOKEN,
INCREASE_SAMPLES,
MINT_POSITION,
MINT_TOKENS,
VERIFY_CONTRACTS,
} from './tasks/constants/taskNames'
import { purpleLog } from './test/utils/colors'
export function handleHardhatTasks() {
handleLimitPoolTasks()
}
function handleLimitPoolTasks() {
// for (const network in SUPPORTED_NETWORKS) {
// if (Object.keys(LOCAL_NETWORKS).includes(network)) continue;
// hre.masterNetwork = MASTER_NETWORKS[network];
// break;
// }
if (process.argv.includes(DEPLOY_FINTOKEN)) {
import('./tasks/deploy/deploy-fintoken')
logTask(DEPLOY_FINTOKEN)
} else if (process.argv.includes(VERIFY_CONTRACTS)) {
import('./tasks/deploy/verify-contracts')
logTask(VERIFY_CONTRACTS)
}
}
function logTask(taskName: string) {
purpleLog(`\n🎛 Running ${taskName} task...\n`)
}