// SPDX-License-Identifier: MIT
pragma solidity ^0.8.19;

import {Script, console} from "forge-std/Script.sol";
import {MainnetTether} from "../contracts/tether/MainnetTether.sol";

contract DeployMainnetTether is Script {
    function run() external {
        uint256 pk = vm.envUint("PRIVATE_KEY");
        address deployer = vm.addr(pk);
        // Use TETHER_ADMIN from .env, or fall back to deployer address
        address admin = vm.envOr("TETHER_ADMIN", deployer);

        vm.startBroadcast(pk);
        MainnetTether tether = new MainnetTether(admin);
        console.log("MainnetTether deployed at:", address(tether));
        console.log("Admin:", admin);
        vm.stopBroadcast();
    }
}

