15 lines
697 B
TypeScript
15 lines
697 B
TypeScript
import { toNano } from '@ton/core';
|
|
import { MainBalance } from '../wrappers/MainBalance';
|
|
import { compile, NetworkProvider } from '@ton/blueprint';
|
|
import contractConfig from '../config/contract.config';
|
|
import { getMainBalanceContract } from './utils';
|
|
|
|
export async function run(provider: NetworkProvider) {
|
|
const ui = provider.ui();
|
|
const mainBalance = await getMainBalanceContract(provider);
|
|
|
|
ui.write(`Current contract balance: ${await mainBalance.getBalance()}`);
|
|
await mainBalance.sendDeploy(provider.sender(), toNano(contractConfig.script.depositAmount));
|
|
ui.write(`${contractConfig.script.depositAmount} TON has been sent to smc address: ${mainBalance.address}`);
|
|
}
|