From 7fa89a12e6fd35ccabb76e52f42f2b5ce193f4ae Mon Sep 17 00:00:00 2001 From: Ayush Tiwari Date: Mon, 15 Jul 2024 19:37:41 +0530 Subject: [PATCH 1/4] feat: added network tags and enums --- packages/deploy/hardhat.config.ts | 87 +++++++++++++++++++++++++------ 1 file changed, 72 insertions(+), 15 deletions(-) diff --git a/packages/deploy/hardhat.config.ts b/packages/deploy/hardhat.config.ts index 2954009ba5..f39ce8f139 100644 --- a/packages/deploy/hardhat.config.ts +++ b/packages/deploy/hardhat.config.ts @@ -303,16 +303,41 @@ const namedAccounts = { /** * TAGS: * - mainnet -> production networks (you must pay for gas!!!) - * - L1 -> Layer 1 networks - * - L2 -> Layer 2 networks + * - L1, L1-prod, L1-test -> Layer 1 networks + * - L2, L2-prod, L2-test -> Layer 2 networks */ +enum NETWORKS { + SEPOLIA = 11155111, + MAINNET = 1, + AMOY = 80002, + POLYGON = 137, + BASESEPOLIA = 84532, + BASE = 8453, + BSCTESTNET = 97, + BSCMAINNET = 56, +} + +enum DEPLOY_NETWORKS { + SEPOLIA = 'sepolia', + MAINNET = 'mainnet', + BSCTESTNET = 'bscTestnet', + BSCMAINNET = 'bscMainnet', + AMOY = 'amoy', + POLYGON = 'polygon', + BASESEPOLIA = 'baseSepolia', + BASE = 'base', +} + const networks = { hardhat: { - tags: ['L1', 'L2'], + tags: ['L1', 'L1-prod', 'L1-test', 'L2', 'L2-prod', 'L2-test'], deploy: ['deploy_mocks/', 'deploy/'], companionNetworks: { l1: 'hardhat', l2: 'hardhat', + ethereum: 'hardhat', + base: 'hardhat', + bsc: 'hardhat', }, blockGasLimit: parseInt(process.env.HARDHAT_BLOCK_GAS_LIMIT || '0') || 30000000, @@ -324,16 +349,34 @@ const networks = { l2: 'mumbai', }, }, - sepolia: { - tags: ['L1'], + [DEPLOY_NETWORKS.SEPOLIA]: { + tags: ['L1', 'L1-test'], + companionNetworks: { + [NETWORKS.AMOY]: [DEPLOY_NETWORKS.AMOY], + [NETWORKS.BASESEPOLIA]: [DEPLOY_NETWORKS.BASESEPOLIA], + [NETWORKS.BSCTESTNET]: [DEPLOY_NETWORKS.BSCTESTNET], + }, + }, + [DEPLOY_NETWORKS.MAINNET]: { + tags: ['mainnet', 'L1', 'L1-prod'], + companionNetworks: { + [NETWORKS.POLYGON]: [DEPLOY_NETWORKS.POLYGON], + [NETWORKS.BASE]: [DEPLOY_NETWORKS.BASE], + [NETWORKS.BSCMAINNET]: [DEPLOY_NETWORKS.BSCMAINNET], + }, + }, + [DEPLOY_NETWORKS.BSCTESTNET]: { + tags: ['L1', 'L1-test'], companionNetworks: { - l2: 'amoy', + [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], + [NETWORKS.BASESEPOLIA]: [DEPLOY_NETWORKS.BASESEPOLIA], }, }, - mainnet: { - tags: ['mainnet', 'L1'], + [DEPLOY_NETWORKS.BSCMAINNET]: { + tags: ['L1', 'L1-prod'], companionNetworks: { - l2: 'polygon', + [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], + [NETWORKS.BASE]: [DEPLOY_NETWORKS.BASE], }, }, mumbai: { @@ -342,16 +385,30 @@ const networks = { l1: 'goerli', }, }, - amoy: { - tags: ['L2'], + [DEPLOY_NETWORKS.AMOY]: { + tags: ['L2', 'L2-test'], + companionNetworks: { + [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], + }, + }, + [DEPLOY_NETWORKS.POLYGON]: { + tags: ['L2', 'L2-prod'], + companionNetworks: { + [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], + }, + }, + [DEPLOY_NETWORKS.BASESEPOLIA]: { + tags: ['L2', 'L2-test'], companionNetworks: { - l1: 'sepolia', + [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], + [NETWORKS.BSCTESTNET]: [DEPLOY_NETWORKS.BSCTESTNET], }, }, - polygon: { - tags: ['mainnet', 'L2'], + [DEPLOY_NETWORKS.BASE]: { + tags: ['L2', 'L2-prod'], companionNetworks: { - l1: 'mainnet', + [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], + [NETWORKS.BSCMAINNET]: [DEPLOY_NETWORKS.BSCMAINNET], }, }, }; From f001e15e02c6e0398b585c91fe3b26a15e0ba70f Mon Sep 17 00:00:00 2001 From: wojciech-turek Date: Mon, 15 Jul 2024 20:38:09 +0200 Subject: [PATCH 2/4] Update types in hardhat config --- packages/deploy/hardhat.config.ts | 115 ++++++++++++++---------------- 1 file changed, 53 insertions(+), 62 deletions(-) diff --git a/packages/deploy/hardhat.config.ts b/packages/deploy/hardhat.config.ts index f39ce8f139..28cb4ce821 100644 --- a/packages/deploy/hardhat.config.ts +++ b/packages/deploy/hardhat.config.ts @@ -1,17 +1,17 @@ -import 'dotenv/config'; import '@nomicfoundation/hardhat-chai-matchers'; -import '@nomicfoundation/hardhat-network-helpers'; import '@nomicfoundation/hardhat-ethers'; +import '@nomicfoundation/hardhat-network-helpers'; +import 'dotenv/config'; import 'hardhat-deploy'; import 'hardhat-deploy-ethers'; +import './tasks/importedPackages'; +import './tasks/landMetadataRegistry'; +import './tasks/steal'; import { addForkingSupport, addNodeAndMnemonic, skipDeploymentsOnLiveNetworks, } from './utils/hardhatConfig'; -import './tasks/importedPackages'; -import './tasks/steal'; -import './tasks/landMetadataRegistry'; // Package name : solidity source code path const importedPackages = { @@ -300,115 +300,106 @@ const namedAccounts = { }, }; -/** - * TAGS: - * - mainnet -> production networks (you must pay for gas!!!) - * - L1, L1-prod, L1-test -> Layer 1 networks - * - L2, L2-prod, L2-test -> Layer 2 networks - */ -enum NETWORKS { - SEPOLIA = 11155111, - MAINNET = 1, - AMOY = 80002, - POLYGON = 137, - BASESEPOLIA = 84532, - BASE = 8453, - BSCTESTNET = 97, - BSCMAINNET = 56, -} - -enum DEPLOY_NETWORKS { - SEPOLIA = 'sepolia', - MAINNET = 'mainnet', - BSCTESTNET = 'bscTestnet', - BSCMAINNET = 'bscMainnet', +export enum DEPLOY_NETWORKS { + HARDHAT = 'hardhat', + ETH_SEPOLIA = 'sepolia', + ETH_GOERLI = 'goerli', + EHT_MAINNET = 'mainnet', + BSC_TESTNET = 'bscTestnet', + BSC_MAINNET = 'bscMainnet', AMOY = 'amoy', POLYGON = 'polygon', - BASESEPOLIA = 'baseSepolia', - BASE = 'base', + MUMBAI = 'mumbai', + BASE_SEPOLIA = 'baseSepolia', + BASE_MAINNET = 'base', } +/** + * TAGS: + * - mainnet -> production DEPLOY_NETWORKS (you must pay for gas!!!) + * - L1, L1-prod, L1-test -> Layer 1 DEPLOY_NETWORKS + * - L2, L2-prod, L2-test -> Layer 2 DEPLOY_NETWORKS + */ + const networks = { - hardhat: { + [DEPLOY_NETWORKS.HARDHAT]: { tags: ['L1', 'L1-prod', 'L1-test', 'L2', 'L2-prod', 'L2-test'], deploy: ['deploy_mocks/', 'deploy/'], companionNetworks: { - l1: 'hardhat', - l2: 'hardhat', - ethereum: 'hardhat', - base: 'hardhat', - bsc: 'hardhat', + [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.HARDHAT, + [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.HARDHAT, + [DEPLOY_NETWORKS.BSC_MAINNET]: DEPLOY_NETWORKS.HARDHAT, }, blockGasLimit: parseInt(process.env.HARDHAT_BLOCK_GAS_LIMIT || '0') || 30000000, }, - goerli: { + [DEPLOY_NETWORKS.ETH_GOERLI]: { tags: ['L1'], // gasPrice: 600000000000, // Uncomment in case of pending txs, and adjust gas companionNetworks: { - l2: 'mumbai', + [DEPLOY_NETWORKS.MUMBAI]: DEPLOY_NETWORKS.MUMBAI, }, }, - [DEPLOY_NETWORKS.SEPOLIA]: { + [DEPLOY_NETWORKS.ETH_SEPOLIA]: { tags: ['L1', 'L1-test'], companionNetworks: { - [NETWORKS.AMOY]: [DEPLOY_NETWORKS.AMOY], - [NETWORKS.BASESEPOLIA]: [DEPLOY_NETWORKS.BASESEPOLIA], - [NETWORKS.BSCTESTNET]: [DEPLOY_NETWORKS.BSCTESTNET], + [DEPLOY_NETWORKS.AMOY]: DEPLOY_NETWORKS.AMOY, + [DEPLOY_NETWORKS.BASE_SEPOLIA]: DEPLOY_NETWORKS.BASE_SEPOLIA, + [DEPLOY_NETWORKS.BSC_TESTNET]: DEPLOY_NETWORKS.BSC_TESTNET, }, }, - [DEPLOY_NETWORKS.MAINNET]: { + [DEPLOY_NETWORKS.EHT_MAINNET]: { tags: ['mainnet', 'L1', 'L1-prod'], companionNetworks: { - [NETWORKS.POLYGON]: [DEPLOY_NETWORKS.POLYGON], - [NETWORKS.BASE]: [DEPLOY_NETWORKS.BASE], - [NETWORKS.BSCMAINNET]: [DEPLOY_NETWORKS.BSCMAINNET], + [DEPLOY_NETWORKS.POLYGON]: DEPLOY_NETWORKS.POLYGON, + [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.BASE_MAINNET, + [DEPLOY_NETWORKS.BSC_MAINNET]: DEPLOY_NETWORKS.BSC_MAINNET, }, }, - [DEPLOY_NETWORKS.BSCTESTNET]: { + [DEPLOY_NETWORKS.BSC_TESTNET]: { tags: ['L1', 'L1-test'], companionNetworks: { - [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], - [NETWORKS.BASESEPOLIA]: [DEPLOY_NETWORKS.BASESEPOLIA], + [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, + [DEPLOY_NETWORKS.BASE_SEPOLIA]: DEPLOY_NETWORKS.BASE_SEPOLIA, }, }, - [DEPLOY_NETWORKS.BSCMAINNET]: { + [DEPLOY_NETWORKS.BSC_MAINNET]: { tags: ['L1', 'L1-prod'], companionNetworks: { - [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], - [NETWORKS.BASE]: [DEPLOY_NETWORKS.BASE], + [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, + [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.BASE_MAINNET, }, }, - mumbai: { - tags: ['L2'], + [DEPLOY_NETWORKS.MUMBAI]: { + tags: ['L2', 'L2-test'], companionNetworks: { - l1: 'goerli', + [DEPLOY_NETWORKS.ETH_GOERLI]: DEPLOY_NETWORKS.ETH_GOERLI, }, }, [DEPLOY_NETWORKS.AMOY]: { tags: ['L2', 'L2-test'], companionNetworks: { - [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], + [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, }, }, [DEPLOY_NETWORKS.POLYGON]: { tags: ['L2', 'L2-prod'], companionNetworks: { - [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], + [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, }, }, - [DEPLOY_NETWORKS.BASESEPOLIA]: { + [DEPLOY_NETWORKS.BASE_SEPOLIA]: { tags: ['L2', 'L2-test'], companionNetworks: { - [NETWORKS.SEPOLIA]: [DEPLOY_NETWORKS.SEPOLIA], - [NETWORKS.BSCTESTNET]: [DEPLOY_NETWORKS.BSCTESTNET], + [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, + [DEPLOY_NETWORKS.BSC_TESTNET]: DEPLOY_NETWORKS.BSC_TESTNET, }, }, - [DEPLOY_NETWORKS.BASE]: { + [DEPLOY_NETWORKS.BASE_MAINNET]: { tags: ['L2', 'L2-prod'], companionNetworks: { - [NETWORKS.MAINNET]: [DEPLOY_NETWORKS.MAINNET], - [NETWORKS.BSCMAINNET]: [DEPLOY_NETWORKS.BSCMAINNET], + [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, + [DEPLOY_NETWORKS.BSC_MAINNET]: DEPLOY_NETWORKS.BSC_MAINNET, }, }, }; From ae59b855925b43348f24c1829bf7b4b314c4cd36 Mon Sep 17 00:00:00 2001 From: wojciech-turek Date: Mon, 22 Jul 2024 09:48:18 +0200 Subject: [PATCH 3/4] Add network specific tags to each deploy scripts --- packages/deploy/README.md | 9 +++ .../000_core/001_deploy_polygon_sand.ts | 9 ++- .../deploy/100_claim/100_multi_claim.ts | 9 ++- .../100_claim/200_multi_claim_role_setup.ts | 9 ++- .../010_deploy_raffle_care_bears.ts | 9 ++- .../011_setup_raffle_care_bears_minter.ts | 4 ++ .../013_setup_raffle_care_bears_wave_0.ts | 6 +- .../014_setup_raffle_care_bears_signer.ts | 4 ++ .../015_change_owner_care_bears.ts | 9 ++- .../010_deploy_raffle_playboy_party_people.ts | 9 ++- ...etup_raffle_playboy_party_people_minter.ts | 4 ++ ...etup_raffle_playboy_party_people_wave_0.ts | 6 +- ...etup_raffle_playboy_party_people_signer.ts | 4 ++ .../015_change_owner_playboy_party_people.ts | 6 +- .../200_deploy_royalty_splitter.ts | 9 ++- .../201_deploy_royalty_manager.ts | 11 +++- .../010_deploy_raffle_rabbids.ts | 9 ++- .../011_setup_raffle_rabbids_minter.ts | 10 +++- .../012_setup_raffle_rabbids_wave_0.ts | 12 +++- .../013_setup_raffle_rabbids_signer.ts | 10 +++- .../014_change_owner_rabbids.ts | 9 ++- .../010_deploy_raffle_madballs.ts | 9 ++- .../011_setup_raffle_madballs_minter.ts | 10 +++- .../012_setup_raffle_madballs_wave_0.ts | 12 +++- .../013_setup_raffle_madballs_signer.ts | 10 +++- .../014_change_owner_madballs.ts | 9 ++- .../010_deploy_raffle_dancefight.ts | 9 ++- .../011_setup_raffle_dancefight_minter.ts | 10 +++- .../012_setup_raffle_dancefight_wave_0.ts | 10 +++- .../013_setup_raffle_dancefight_signer.ts | 10 +++- .../014_change_owner_dancefight.ts | 9 ++- .../010_deploy_raffle_hells_kitchen.ts | 9 ++- .../011_setup_raffle_hells_kitchen_minter.ts | 10 +++- .../012_setup_raffle_hells_kitchen_wave_0.ts | 10 +++- .../013_setup_raffle_hells_kitchen_signer.ts | 10 +++- .../014_change_owner_hells_kitchen.ts | 9 ++- ...10_deploy_raffle_fist_of_the_north_star.ts | 9 ++- ...up_raffle_fist_of_the_north_star_minter.ts | 4 ++ ...up_raffle_fist_of_the_north_star_wave_0.ts | 4 ++ ...up_raffle_fist_of_the_north_star_signer.ts | 4 ++ ...014_change_owner_fist_of_the_north_star.ts | 9 ++- .../change_owner_factory.ts | 9 ++- .../deploy_collection_factory.ts | 9 ++- ...y_collection_factory_beacon_main_avatar.ts | 4 ++ ...ctory_implementation_AvatarCollection_1.ts | 4 ++ .../010_deploy_raffle_paris_hilton.ts | 9 ++- .../011_setup_raffle_paris_hilton_minter.ts | 10 +++- .../012_setup_raffle_paris_hilton_wave_0.ts | 10 +++- .../013_setup_raffle_paris_hilton_signer.ts | 10 +++- .../014_change_owner_paris_hilton.ts | 9 ++- ...deploy_mock_collection_AvatarCollection.ts | 8 ++- .../deploy/300_catalyst/300_catalyst_mint.ts | 8 ++- ...300_deploy_operator_filter_subscription.ts | 5 +- .../300_catalyst/301_deploy_catalyst.ts | 10 +++- .../deploy/300_catalyst/302_catalyst_setup.ts | 9 ++- .../300_catalyst/303_upgrade_catalyst.ts | 8 ++- ...ploy_operator_filter_asset_subscription.ts | 5 +- .../401_deploy_asset_auth_validator.ts | 11 +++- .../deploy/400_asset/402_deploy_asset.ts | 11 +++- .../400_asset/403_deploy_asset_create.ts | 12 +++- .../400_asset/404_deploy_asset_reveal.ts | 11 +++- .../400_asset/405_asset_create_setup.ts | 12 +++- .../400_asset/406_asset_reveal_setup.ts | 10 +++- .../deploy/400_asset/407_asset_setup.ts | 11 +++- .../400_asset/408_upgrade_asset_create.ts | 8 ++- .../409_deploy_updated_auth_validator.ts | 10 +++- .../400_asset/410_lazy_minting_setup.ts | 9 ++- .../500_deploy_royalties_registry.ts | 14 ++++- .../501_royalties_registry_setup.ts | 12 +++- .../502_deploy_order_validator.ts | 16 +++++- .../503_order_validator_setup.ts | 12 +++- .../500_marketplace/504_deploy_exchange.ts | 14 ++++- .../500_marketplace/505_exchange_setup.ts | 12 +++- .../600_faucets/600_deploy_faucetsERC1155.ts | 10 +++- .../deploy/700_land/land/710_deploy_land.ts | 14 ++++- .../700_land/land/720_upgrade_land_v2.ts | 10 +++- .../700_land/land/730_upgrade_land_v3.ts | 10 +++- .../731_setup_land_v3_operator_filterer.ts | 11 +++- .../700_land/land/740_upgrade_land_v4.ts | 10 +++- .../land/741_setup_land_v4_royalties.ts | 5 +- .../700_land/land/742_setup_land_v4_owner.ts | 11 +++- .../land/743_setup_land_v4_registry.ts | 5 +- .../700_land/land/750_deploy_land_registry.ts | 5 +- .../polygonLand/710_deploy_polygon_land.ts | 12 +++- .../711_setup_polygon_land_admin.ts | 11 +++- .../720_upgrade_polygon_land_v2.ts | 12 +++- ...setup_polygon_land_v2_operator_filterer.ts | 11 +++- .../730_upgrade_polygon_land_v3.ts | 12 +++- .../731_setup_polygon_land_v3_royalties.ts | 5 +- .../732_setup_polygon_land_v3_owner.ts | 5 +- .../733_setup_polygon_land_v3_registry.ts | 5 +- .../750_deploy_polygon_land_registry.ts | 5 +- packages/deploy/hardhat.config.ts | 55 +++++++++++-------- 93 files changed, 751 insertions(+), 128 deletions(-) diff --git a/packages/deploy/README.md b/packages/deploy/README.md index 690a8cb5a3..0982e4c796 100644 --- a/packages/deploy/README.md +++ b/packages/deploy/README.md @@ -44,6 +44,15 @@ where: executed ( see:[hardhat-deploy](https://github.com/wighawag/hardhat-deploy) configuration) +- There is a specific set of tags related to network on which each script was + meant to run. + - L1 = 'L1', // Layer one networks like Ethereum mainnet, sepolia + - L1_PROD = 'L1-prod', // Layer one production networks like Ethereum mainnet + - L1_TEST = 'L1-test', // Layer one test networks like Goerli + - L2 = 'L2', // Layer two networks like Polygon, mumbai + - L2_PROD = 'L2-prod', // Layer two production networks like Polygon + - L2_TEST = 'L2-test', // Layer two test networks like Mumbai + ## Upgrades 1. Modify smart contracts, add tests, and update documentation in the respective diff --git a/packages/deploy/deploy/000_core/001_deploy_polygon_sand.ts b/packages/deploy/deploy/000_core/001_deploy_polygon_sand.ts index 1c8b05f0b6..b922974cc6 100644 --- a/packages/deploy/deploy/000_core/001_deploy_polygon_sand.ts +++ b/packages/deploy/deploy/000_core/001_deploy_polygon_sand.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -25,5 +26,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['PolygonSand', 'PolygonSand_deploy', 'L2']; +func.tags = [ + 'PolygonSand', + 'PolygonSand_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['CHILD_CHAIN_MANAGER', 'TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/100_claim/100_multi_claim.ts b/packages/deploy/deploy/100_claim/100_multi_claim.ts index 0588e8f704..bfd2a6da4b 100644 --- a/packages/deploy/deploy/100_claim/100_multi_claim.ts +++ b/packages/deploy/deploy/100_claim/100_multi_claim.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -26,5 +27,11 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['SignedMultiGiveaway', 'SignedMultiGiveaway_deploy', 'L2']; +func.tags = [ + 'SignedMultiGiveaway', + 'SignedMultiGiveaway_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/100_claim/200_multi_claim_role_setup.ts b/packages/deploy/deploy/100_claim/200_multi_claim_role_setup.ts index 8701e364ff..2f5cad4093 100644 --- a/packages/deploy/deploy/100_claim/200_multi_claim_role_setup.ts +++ b/packages/deploy/deploy/100_claim/200_multi_claim_role_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -29,5 +30,11 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['SignedMultiGiveaway', 'SignedMultiGiveaway_role_setup', 'L2']; +func.tags = [ + 'SignedMultiGiveaway', + 'SignedMultiGiveaway_role_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['SignedMultiGiveaway_deploy']; diff --git a/packages/deploy/deploy/17_raffle_care_bears/010_deploy_raffle_care_bears.ts b/packages/deploy/deploy/17_raffle_care_bears/010_deploy_raffle_care_bears.ts index c404a393fa..97ba84b24b 100644 --- a/packages/deploy/deploy/17_raffle_care_bears/010_deploy_raffle_care_bears.ts +++ b/packages/deploy/deploy/17_raffle_care_bears/010_deploy_raffle_care_bears.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -41,5 +42,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['RaffleCareBears', 'RaffleCareBears_deploy']; +func.tags = [ + 'RaffleCareBears', + 'RaffleCareBears_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/17_raffle_care_bears/011_setup_raffle_care_bears_minter.ts b/packages/deploy/deploy/17_raffle_care_bears/011_setup_raffle_care_bears_minter.ts index a2b3aab6e0..491cbb55cf 100644 --- a/packages/deploy/deploy/17_raffle_care_bears/011_setup_raffle_care_bears_minter.ts +++ b/packages/deploy/deploy/17_raffle_care_bears/011_setup_raffle_care_bears_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -32,6 +33,9 @@ func.tags = [ 'RaffleCareBears', 'RaffleCareBears_setup', 'RaffleCareBears_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; // func.dependencies = ['PolygonSand_deploy', 'RaffleCareBears_deploy']; func.dependencies = ['RaffleCareBears_deploy']; diff --git a/packages/deploy/deploy/17_raffle_care_bears/013_setup_raffle_care_bears_wave_0.ts b/packages/deploy/deploy/17_raffle_care_bears/013_setup_raffle_care_bears_wave_0.ts index 89c04be734..c26c6eb34a 100644 --- a/packages/deploy/deploy/17_raffle_care_bears/013_setup_raffle_care_bears_wave_0.ts +++ b/packages/deploy/deploy/17_raffle_care_bears/013_setup_raffle_care_bears_wave_0.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -35,5 +36,8 @@ func.tags = [ 'RaffleCareBears', 'RaffleCareBears_setup', 'RaffleCareBears_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['RaffleCareBears_deploy']; diff --git a/packages/deploy/deploy/17_raffle_care_bears/014_setup_raffle_care_bears_signer.ts b/packages/deploy/deploy/17_raffle_care_bears/014_setup_raffle_care_bears_signer.ts index 8076e37d60..6cee749099 100644 --- a/packages/deploy/deploy/17_raffle_care_bears/014_setup_raffle_care_bears_signer.ts +++ b/packages/deploy/deploy/17_raffle_care_bears/014_setup_raffle_care_bears_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -25,5 +26,8 @@ func.tags = [ 'RaffleCareBears', 'RaffleCareBears_setup', 'RaffleCareBears_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['RaffleCareBears_deploy']; diff --git a/packages/deploy/deploy/17_raffle_care_bears/015_change_owner_care_bears.ts b/packages/deploy/deploy/17_raffle_care_bears/015_change_owner_care_bears.ts index e204e5d2ac..1e3df1e4c1 100644 --- a/packages/deploy/deploy/17_raffle_care_bears/015_change_owner_care_bears.ts +++ b/packages/deploy/deploy/17_raffle_care_bears/015_change_owner_care_bears.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['RaffleCareBears', 'RaffleCareBears_change_admin']; +func.tags = [ + 'RaffleCareBears', + 'RaffleCareBears_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['RaffleCareBears_deploy']; diff --git a/packages/deploy/deploy/18_raffle_playboy_party_people/010_deploy_raffle_playboy_party_people.ts b/packages/deploy/deploy/18_raffle_playboy_party_people/010_deploy_raffle_playboy_party_people.ts index c33f8f436b..c3124d40b6 100644 --- a/packages/deploy/deploy/18_raffle_playboy_party_people/010_deploy_raffle_playboy_party_people.ts +++ b/packages/deploy/deploy/18_raffle_playboy_party_people/010_deploy_raffle_playboy_party_people.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -42,5 +43,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['RafflePlayboyPartyPeople', 'RafflePlayboyPartyPeople_deploy']; +func.tags = [ + 'RafflePlayboyPartyPeople', + 'RafflePlayboyPartyPeople_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/18_raffle_playboy_party_people/011_setup_raffle_playboy_party_people_minter.ts b/packages/deploy/deploy/18_raffle_playboy_party_people/011_setup_raffle_playboy_party_people_minter.ts index 5c33193f8b..f388ba7e6e 100644 --- a/packages/deploy/deploy/18_raffle_playboy_party_people/011_setup_raffle_playboy_party_people_minter.ts +++ b/packages/deploy/deploy/18_raffle_playboy_party_people/011_setup_raffle_playboy_party_people_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -33,6 +34,9 @@ func.tags = [ 'RafflePlayboyPartyPeople', 'RafflePlayboyPartyPeople_setup', 'RafflePlayboyPartyPeople_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; // func.dependencies = ['PolygonSand_deploy', 'RafflePlayboyPartyPeople_deploy']; func.dependencies = ['RafflePlayboyPartyPeople_deploy']; diff --git a/packages/deploy/deploy/18_raffle_playboy_party_people/013_setup_raffle_playboy_party_people_wave_0.ts b/packages/deploy/deploy/18_raffle_playboy_party_people/013_setup_raffle_playboy_party_people_wave_0.ts index c585538dbf..e241361297 100644 --- a/packages/deploy/deploy/18_raffle_playboy_party_people/013_setup_raffle_playboy_party_people_wave_0.ts +++ b/packages/deploy/deploy/18_raffle_playboy_party_people/013_setup_raffle_playboy_party_people_wave_0.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -38,5 +39,8 @@ func.tags = [ 'RafflePlayboyPartyPeople', 'RafflePlayboyPartyPeople_setup', 'RafflePlayboyPartyPeople_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['RafflePlayboyPartyPeople_deploy']; diff --git a/packages/deploy/deploy/18_raffle_playboy_party_people/014_setup_raffle_playboy_party_people_signer.ts b/packages/deploy/deploy/18_raffle_playboy_party_people/014_setup_raffle_playboy_party_people_signer.ts index c505836e95..e198f999c6 100644 --- a/packages/deploy/deploy/18_raffle_playboy_party_people/014_setup_raffle_playboy_party_people_signer.ts +++ b/packages/deploy/deploy/18_raffle_playboy_party_people/014_setup_raffle_playboy_party_people_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -25,5 +26,8 @@ func.tags = [ 'RafflePlayboyPartyPeople', 'RafflePlayboyPartyPeople_setup', 'RafflePlayboyPartyPeople_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['RafflePlayboyPartyPeople_deploy']; diff --git a/packages/deploy/deploy/18_raffle_playboy_party_people/015_change_owner_playboy_party_people.ts b/packages/deploy/deploy/18_raffle_playboy_party_people/015_change_owner_playboy_party_people.ts index e3a6d7d15f..15a88faf5d 100644 --- a/packages/deploy/deploy/18_raffle_playboy_party_people/015_change_owner_playboy_party_people.ts +++ b/packages/deploy/deploy/18_raffle_playboy_party_people/015_change_owner_playboy_party_people.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -24,5 +25,8 @@ export default func; func.tags = [ 'RafflePlayboyPartyPeople', 'RafflePlayboyPartyPeople_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['RafflePlayboyPartyPeople_deploy']; diff --git a/packages/deploy/deploy/200_royalties/200_deploy_royalty_splitter.ts b/packages/deploy/deploy/200_royalties/200_deploy_royalty_splitter.ts index 0cf3fb722a..0da8d762e9 100644 --- a/packages/deploy/deploy/200_royalties/200_deploy_royalty_splitter.ts +++ b/packages/deploy/deploy/200_royalties/200_deploy_royalty_splitter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -18,4 +19,10 @@ const func: DeployFunction = async function ( }); }; export default func; -func.tags = ['RoyaltySplitter', 'RoyaltySplitter_deploy', 'L2']; +func.tags = [ + 'RoyaltySplitter', + 'RoyaltySplitter_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/200_royalties/201_deploy_royalty_manager.ts b/packages/deploy/deploy/200_royalties/201_deploy_royalty_manager.ts index 4dbfd866ab..84199289c3 100644 --- a/packages/deploy/deploy/200_royalties/201_deploy_royalty_manager.ts +++ b/packages/deploy/deploy/200_royalties/201_deploy_royalty_manager.ts @@ -1,6 +1,7 @@ +import {ZeroAddress} from 'ethers'; import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; -import {ZeroAddress} from 'ethers'; +import {DEPLOY_TAGS} from '../../hardhat.config'; export const ROYALTY_SPLIT = 5000; @@ -45,5 +46,11 @@ const func: DeployFunction = async function ( }); }; export default func; -func.tags = ['RoyaltyManager', 'RoyaltyManager_deploy', 'L2']; +func.tags = [ + 'RoyaltyManager', + 'RoyaltyManager_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['RoyaltySplitter_deploy']; diff --git a/packages/deploy/deploy/20_raffle_rabbids/010_deploy_raffle_rabbids.ts b/packages/deploy/deploy/20_raffle_rabbids/010_deploy_raffle_rabbids.ts index 414b7d26c9..50ced4ac87 100644 --- a/packages/deploy/deploy/20_raffle_rabbids/010_deploy_raffle_rabbids.ts +++ b/packages/deploy/deploy/20_raffle_rabbids/010_deploy_raffle_rabbids.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -51,5 +52,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Rabbids', 'Rabbids_deploy']; +func.tags = [ + 'Rabbids', + 'Rabbids_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/20_raffle_rabbids/011_setup_raffle_rabbids_minter.ts b/packages/deploy/deploy/20_raffle_rabbids/011_setup_raffle_rabbids_minter.ts index a302e3ac6f..d9d8f9d591 100644 --- a/packages/deploy/deploy/20_raffle_rabbids/011_setup_raffle_rabbids_minter.ts +++ b/packages/deploy/deploy/20_raffle_rabbids/011_setup_raffle_rabbids_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,6 +30,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Rabbids', 'Rabbids_setup', 'Rabbids_setup_minter']; +func.tags = [ + 'Rabbids', + 'Rabbids_setup', + 'Rabbids_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; // func.dependencies = ['PolygonSand_deploy', 'Rabbids_deploy']; func.dependencies = ['Rabbids_deploy']; diff --git a/packages/deploy/deploy/20_raffle_rabbids/012_setup_raffle_rabbids_wave_0.ts b/packages/deploy/deploy/20_raffle_rabbids/012_setup_raffle_rabbids_wave_0.ts index 14a2203a89..f5458be29d 100644 --- a/packages/deploy/deploy/20_raffle_rabbids/012_setup_raffle_rabbids_wave_0.ts +++ b/packages/deploy/deploy/20_raffle_rabbids/012_setup_raffle_rabbids_wave_0.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Rabbids', 'Rabbids_setup', 'Rabbids_setup_wave']; +func.tags = [ + 'Rabbids', + 'Rabbids_setup', + 'Rabbids_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Rabbids_deploy']; diff --git a/packages/deploy/deploy/20_raffle_rabbids/013_setup_raffle_rabbids_signer.ts b/packages/deploy/deploy/20_raffle_rabbids/013_setup_raffle_rabbids_signer.ts index 81dcbe01a8..3e52bbfdff 100644 --- a/packages/deploy/deploy/20_raffle_rabbids/013_setup_raffle_rabbids_signer.ts +++ b/packages/deploy/deploy/20_raffle_rabbids/013_setup_raffle_rabbids_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Rabbids', 'Rabbids_setup', 'Rabbids_setup_signer']; +func.tags = [ + 'Rabbids', + 'Rabbids_setup', + 'Rabbids_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Rabbids_deploy']; diff --git a/packages/deploy/deploy/20_raffle_rabbids/014_change_owner_rabbids.ts b/packages/deploy/deploy/20_raffle_rabbids/014_change_owner_rabbids.ts index 22a162c467..c72fedbe38 100644 --- a/packages/deploy/deploy/20_raffle_rabbids/014_change_owner_rabbids.ts +++ b/packages/deploy/deploy/20_raffle_rabbids/014_change_owner_rabbids.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Rabbids', 'Rabbids_change_admin']; +func.tags = [ + 'Rabbids', + 'Rabbids_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Rabbids_deploy']; diff --git a/packages/deploy/deploy/21_raffle_madballs/010_deploy_raffle_madballs.ts b/packages/deploy/deploy/21_raffle_madballs/010_deploy_raffle_madballs.ts index 3d7702470e..60a7328a68 100644 --- a/packages/deploy/deploy/21_raffle_madballs/010_deploy_raffle_madballs.ts +++ b/packages/deploy/deploy/21_raffle_madballs/010_deploy_raffle_madballs.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -51,5 +52,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['MadBalls', 'MadBalls_deploy']; +func.tags = [ + 'MadBalls', + 'MadBalls_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/21_raffle_madballs/011_setup_raffle_madballs_minter.ts b/packages/deploy/deploy/21_raffle_madballs/011_setup_raffle_madballs_minter.ts index eeeb1d2818..6f6f059f66 100644 --- a/packages/deploy/deploy/21_raffle_madballs/011_setup_raffle_madballs_minter.ts +++ b/packages/deploy/deploy/21_raffle_madballs/011_setup_raffle_madballs_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,6 +30,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['MadBalls', 'MadBalls_setup', 'MadBalls_setup_minter']; +func.tags = [ + 'MadBalls', + 'MadBalls_setup', + 'MadBalls_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; // func.dependencies = ['PolygonSand_deploy', 'MadBalls_deploy']; func.dependencies = ['MadBalls_deploy']; diff --git a/packages/deploy/deploy/21_raffle_madballs/012_setup_raffle_madballs_wave_0.ts b/packages/deploy/deploy/21_raffle_madballs/012_setup_raffle_madballs_wave_0.ts index b90f62e614..28f99c956e 100644 --- a/packages/deploy/deploy/21_raffle_madballs/012_setup_raffle_madballs_wave_0.ts +++ b/packages/deploy/deploy/21_raffle_madballs/012_setup_raffle_madballs_wave_0.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['MadBalls', 'MadBalls_setup', 'MadBalls_setup_wave']; +func.tags = [ + 'MadBalls', + 'MadBalls_setup', + 'MadBalls_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['MadBalls_deploy']; diff --git a/packages/deploy/deploy/21_raffle_madballs/013_setup_raffle_madballs_signer.ts b/packages/deploy/deploy/21_raffle_madballs/013_setup_raffle_madballs_signer.ts index 3b4f7beac4..e2f073af84 100644 --- a/packages/deploy/deploy/21_raffle_madballs/013_setup_raffle_madballs_signer.ts +++ b/packages/deploy/deploy/21_raffle_madballs/013_setup_raffle_madballs_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['MadBalls', 'MadBalls_setup', 'MadBalls_setup_signer']; +func.tags = [ + 'MadBalls', + 'MadBalls_setup', + 'MadBalls_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['MadBalls_deploy']; diff --git a/packages/deploy/deploy/21_raffle_madballs/014_change_owner_madballs.ts b/packages/deploy/deploy/21_raffle_madballs/014_change_owner_madballs.ts index 70a1394a86..0e7288b94f 100644 --- a/packages/deploy/deploy/21_raffle_madballs/014_change_owner_madballs.ts +++ b/packages/deploy/deploy/21_raffle_madballs/014_change_owner_madballs.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['MadBalls', 'MadBalls_change_admin']; +func.tags = [ + 'MadBalls', + 'MadBalls_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['MadBalls_deploy']; diff --git a/packages/deploy/deploy/22_raffle_dancefight/010_deploy_raffle_dancefight.ts b/packages/deploy/deploy/22_raffle_dancefight/010_deploy_raffle_dancefight.ts index c83e4ab19d..c3408d1ac8 100644 --- a/packages/deploy/deploy/22_raffle_dancefight/010_deploy_raffle_dancefight.ts +++ b/packages/deploy/deploy/22_raffle_dancefight/010_deploy_raffle_dancefight.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from './../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -51,5 +52,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['DanceFight', 'DanceFight_deploy']; +func.tags = [ + 'DanceFight', + 'DanceFight_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/22_raffle_dancefight/011_setup_raffle_dancefight_minter.ts b/packages/deploy/deploy/22_raffle_dancefight/011_setup_raffle_dancefight_minter.ts index 54d0c2f21e..c41d91bfe3 100644 --- a/packages/deploy/deploy/22_raffle_dancefight/011_setup_raffle_dancefight_minter.ts +++ b/packages/deploy/deploy/22_raffle_dancefight/011_setup_raffle_dancefight_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,6 +30,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['DanceFight', 'DanceFight_setup', 'DanceFight_setup_minter']; +func.tags = [ + 'DanceFight', + 'DanceFight_setup', + 'DanceFight_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; // func.dependencies = ['PolygonSand_deploy', 'DanceFight_deploy']; func.dependencies = ['DanceFight_deploy']; diff --git a/packages/deploy/deploy/22_raffle_dancefight/012_setup_raffle_dancefight_wave_0.ts b/packages/deploy/deploy/22_raffle_dancefight/012_setup_raffle_dancefight_wave_0.ts index 83219af5fb..d8d2d92240 100644 --- a/packages/deploy/deploy/22_raffle_dancefight/012_setup_raffle_dancefight_wave_0.ts +++ b/packages/deploy/deploy/22_raffle_dancefight/012_setup_raffle_dancefight_wave_0.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['DanceFight', 'DanceFight_setup', 'DanceFight_setup_wave']; +func.tags = [ + 'DanceFight', + 'DanceFight_setup', + 'DanceFight_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['DanceFight_deploy']; diff --git a/packages/deploy/deploy/22_raffle_dancefight/013_setup_raffle_dancefight_signer.ts b/packages/deploy/deploy/22_raffle_dancefight/013_setup_raffle_dancefight_signer.ts index ccb308e9b2..203e5ebe81 100644 --- a/packages/deploy/deploy/22_raffle_dancefight/013_setup_raffle_dancefight_signer.ts +++ b/packages/deploy/deploy/22_raffle_dancefight/013_setup_raffle_dancefight_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['DanceFight', 'DanceFight_setup', 'DanceFight_setup_signer']; +func.tags = [ + 'DanceFight', + 'DanceFight_setup', + 'DanceFight_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['DanceFight_deploy']; diff --git a/packages/deploy/deploy/22_raffle_dancefight/014_change_owner_dancefight.ts b/packages/deploy/deploy/22_raffle_dancefight/014_change_owner_dancefight.ts index 524c4237c0..8107e8c5ac 100644 --- a/packages/deploy/deploy/22_raffle_dancefight/014_change_owner_dancefight.ts +++ b/packages/deploy/deploy/22_raffle_dancefight/014_change_owner_dancefight.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['DanceFight', 'DanceFight_change_admin']; +func.tags = [ + 'DanceFight', + 'DanceFight_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['DanceFight_deploy']; diff --git a/packages/deploy/deploy/23_raffle_hells_kitchen/010_deploy_raffle_hells_kitchen.ts b/packages/deploy/deploy/23_raffle_hells_kitchen/010_deploy_raffle_hells_kitchen.ts index 696ea23816..39fb62f77b 100644 --- a/packages/deploy/deploy/23_raffle_hells_kitchen/010_deploy_raffle_hells_kitchen.ts +++ b/packages/deploy/deploy/23_raffle_hells_kitchen/010_deploy_raffle_hells_kitchen.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -52,5 +53,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['HellsKitchen', 'HellsKitchen_deploy']; +func.tags = [ + 'HellsKitchen', + 'HellsKitchen_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/23_raffle_hells_kitchen/011_setup_raffle_hells_kitchen_minter.ts b/packages/deploy/deploy/23_raffle_hells_kitchen/011_setup_raffle_hells_kitchen_minter.ts index 3add93fe08..34362826d9 100644 --- a/packages/deploy/deploy/23_raffle_hells_kitchen/011_setup_raffle_hells_kitchen_minter.ts +++ b/packages/deploy/deploy/23_raffle_hells_kitchen/011_setup_raffle_hells_kitchen_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,6 +30,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['HellsKitchen', 'HellsKitchen_setup', 'HellsKitchen_setup_minter']; +func.tags = [ + 'HellsKitchen', + 'HellsKitchen_setup', + 'HellsKitchen_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; // func.dependencies = ['PolygonSand_deploy', 'HellsKitchen_deploy']; func.dependencies = ['HellsKitchen_deploy']; diff --git a/packages/deploy/deploy/23_raffle_hells_kitchen/012_setup_raffle_hells_kitchen_wave_0.ts b/packages/deploy/deploy/23_raffle_hells_kitchen/012_setup_raffle_hells_kitchen_wave_0.ts index 28ce733557..27c3daad1b 100644 --- a/packages/deploy/deploy/23_raffle_hells_kitchen/012_setup_raffle_hells_kitchen_wave_0.ts +++ b/packages/deploy/deploy/23_raffle_hells_kitchen/012_setup_raffle_hells_kitchen_wave_0.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['HellsKitchen', 'HellsKitchen_setup', 'HellsKitchen_setup_wave']; +func.tags = [ + 'HellsKitchen', + 'HellsKitchen_setup', + 'HellsKitchen_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['HellsKitchen_deploy']; diff --git a/packages/deploy/deploy/23_raffle_hells_kitchen/013_setup_raffle_hells_kitchen_signer.ts b/packages/deploy/deploy/23_raffle_hells_kitchen/013_setup_raffle_hells_kitchen_signer.ts index 7a61e3e904..d08b797188 100644 --- a/packages/deploy/deploy/23_raffle_hells_kitchen/013_setup_raffle_hells_kitchen_signer.ts +++ b/packages/deploy/deploy/23_raffle_hells_kitchen/013_setup_raffle_hells_kitchen_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['HellsKitchen', 'HellsKitchen_setup', 'HellsKitchen_setup_signer']; +func.tags = [ + 'HellsKitchen', + 'HellsKitchen_setup', + 'HellsKitchen_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['HellsKitchen_deploy']; diff --git a/packages/deploy/deploy/23_raffle_hells_kitchen/014_change_owner_hells_kitchen.ts b/packages/deploy/deploy/23_raffle_hells_kitchen/014_change_owner_hells_kitchen.ts index 6d3a280247..b3395c6322 100644 --- a/packages/deploy/deploy/23_raffle_hells_kitchen/014_change_owner_hells_kitchen.ts +++ b/packages/deploy/deploy/23_raffle_hells_kitchen/014_change_owner_hells_kitchen.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['HellsKitchen', 'HellsKitchen_change_admin']; +func.tags = [ + 'HellsKitchen', + 'HellsKitchen_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['HellsKitchen_deploy']; diff --git a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/010_deploy_raffle_fist_of_the_north_star.ts b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/010_deploy_raffle_fist_of_the_north_star.ts index 9486ab3ad4..1aa9ae2dff 100644 --- a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/010_deploy_raffle_fist_of_the_north_star.ts +++ b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/010_deploy_raffle_fist_of_the_north_star.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -53,5 +54,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['FistOfTheNorthStar', 'FistOfTheNorthStar_deploy']; +func.tags = [ + 'FistOfTheNorthStar', + 'FistOfTheNorthStar_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/011_setup_raffle_fist_of_the_north_star_minter.ts b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/011_setup_raffle_fist_of_the_north_star_minter.ts index d2cb371efa..c8a1a7d7b9 100644 --- a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/011_setup_raffle_fist_of_the_north_star_minter.ts +++ b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/011_setup_raffle_fist_of_the_north_star_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -33,6 +34,9 @@ func.tags = [ 'FistOfTheNorthStar', 'FistOfTheNorthStar_setup', 'FistOfTheNorthStar_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; // func.dependencies = ['PolygonSand_deploy', 'FistOfTheNorthStar_deploy']; func.dependencies = ['FistOfTheNorthStar_deploy']; diff --git a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/012_setup_raffle_fist_of_the_north_star_wave_0.ts b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/012_setup_raffle_fist_of_the_north_star_wave_0.ts index cc533e7a8a..b39110df75 100644 --- a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/012_setup_raffle_fist_of_the_north_star_wave_0.ts +++ b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/012_setup_raffle_fist_of_the_north_star_wave_0.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,5 +30,8 @@ func.tags = [ 'FistOfTheNorthStar', 'FistOfTheNorthStar_setup', 'FistOfTheNorthStar_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['FistOfTheNorthStar_deploy']; diff --git a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/013_setup_raffle_fist_of_the_north_star_signer.ts b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/013_setup_raffle_fist_of_the_north_star_signer.ts index d730195e16..404c870c47 100644 --- a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/013_setup_raffle_fist_of_the_north_star_signer.ts +++ b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/013_setup_raffle_fist_of_the_north_star_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -25,5 +26,8 @@ func.tags = [ 'FistOfTheNorthStar', 'FistOfTheNorthStar_setup', 'FistOfTheNorthStar_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['FistOfTheNorthStar_deploy']; diff --git a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/014_change_owner_fist_of_the_north_star.ts b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/014_change_owner_fist_of_the_north_star.ts index 29c0e59081..05e4c5c2f0 100644 --- a/packages/deploy/deploy/24_raffle_fist_of_the_north_star/014_change_owner_fist_of_the_north_star.ts +++ b/packages/deploy/deploy/24_raffle_fist_of_the_north_star/014_change_owner_fist_of_the_north_star.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['FistOfTheNorthStar', 'FistOfTheNorthStar_change_admin']; +func.tags = [ + 'FistOfTheNorthStar', + 'FistOfTheNorthStar_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['FistOfTheNorthStar_deploy']; diff --git a/packages/deploy/deploy/25_avatar_collection_factory/change_owner_factory.ts b/packages/deploy/deploy/25_avatar_collection_factory/change_owner_factory.ts index aa7bd73740..11b40dfbb8 100644 --- a/packages/deploy/deploy/25_avatar_collection_factory/change_owner_factory.ts +++ b/packages/deploy/deploy/25_avatar_collection_factory/change_owner_factory.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -24,5 +25,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['CollectionFactory', 'CollectionFactory_change_admin']; +func.tags = [ + 'CollectionFactory', + 'CollectionFactory_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['CollectionFactory_deploy']; diff --git a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory.ts b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory.ts index b20a60ed96..18ae5d512e 100644 --- a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory.ts +++ b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -17,4 +18,10 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['CollectionFactory', 'CollectionFactory_deploy']; +func.tags = [ + 'CollectionFactory', + 'CollectionFactory_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_beacon_main_avatar.ts b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_beacon_main_avatar.ts index dd0a150d00..ae53250897 100644 --- a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_beacon_main_avatar.ts +++ b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_beacon_main_avatar.ts @@ -1,6 +1,7 @@ import {EventLog} from 'ethers'; import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const implementationContractName = 'AvatarCollection'; const beaconAlias = 'main-avatar'; @@ -106,6 +107,9 @@ export default func; func.tags = [ 'CollectionFactory', 'CollectionFactory_deploy_beacon_main_avatar', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = [ 'CollectionFactory_deploy', diff --git a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_implementation_AvatarCollection_1.ts b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_implementation_AvatarCollection_1.ts index 1885a12af2..e8f17deee0 100644 --- a/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_implementation_AvatarCollection_1.ts +++ b/packages/deploy/deploy/25_avatar_collection_factory/deploy_collection_factory_implementation_AvatarCollection_1.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const implementationContractName = 'AvatarCollection'; @@ -20,5 +21,8 @@ export default func; func.tags = [ 'CollectionFactory', `CollectionFactory_implementation_AvatarCollection_1_deploy`, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['CollectionFactory_deploy']; diff --git a/packages/deploy/deploy/26_raffle_paris_hilton/010_deploy_raffle_paris_hilton.ts b/packages/deploy/deploy/26_raffle_paris_hilton/010_deploy_raffle_paris_hilton.ts index d492026ebf..99a9a46a58 100644 --- a/packages/deploy/deploy/26_raffle_paris_hilton/010_deploy_raffle_paris_hilton.ts +++ b/packages/deploy/deploy/26_raffle_paris_hilton/010_deploy_raffle_paris_hilton.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -52,5 +53,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['ParisHilton', 'ParisHilton_deploy']; +func.tags = [ + 'ParisHilton', + 'ParisHilton_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/26_raffle_paris_hilton/011_setup_raffle_paris_hilton_minter.ts b/packages/deploy/deploy/26_raffle_paris_hilton/011_setup_raffle_paris_hilton_minter.ts index b2a91039fd..a41ae09cb8 100644 --- a/packages/deploy/deploy/26_raffle_paris_hilton/011_setup_raffle_paris_hilton_minter.ts +++ b/packages/deploy/deploy/26_raffle_paris_hilton/011_setup_raffle_paris_hilton_minter.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -29,6 +30,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['ParisHilton', 'ParisHilton_setup', 'ParisHilton_setup_minter']; +func.tags = [ + 'ParisHilton', + 'ParisHilton_setup', + 'ParisHilton_setup_minter', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; // func.dependencies = ['PolygonSand_deploy', 'ParisHilton_deploy']; func.dependencies = ['ParisHilton_deploy']; diff --git a/packages/deploy/deploy/26_raffle_paris_hilton/012_setup_raffle_paris_hilton_wave_0.ts b/packages/deploy/deploy/26_raffle_paris_hilton/012_setup_raffle_paris_hilton_wave_0.ts index 4e23090371..06ae9bfeaf 100644 --- a/packages/deploy/deploy/26_raffle_paris_hilton/012_setup_raffle_paris_hilton_wave_0.ts +++ b/packages/deploy/deploy/26_raffle_paris_hilton/012_setup_raffle_paris_hilton_wave_0.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['ParisHilton', 'ParisHilton_setup', 'ParisHilton_setup_wave']; +func.tags = [ + 'ParisHilton', + 'ParisHilton_setup', + 'ParisHilton_setup_wave', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['ParisHilton_deploy']; diff --git a/packages/deploy/deploy/26_raffle_paris_hilton/013_setup_raffle_paris_hilton_signer.ts b/packages/deploy/deploy/26_raffle_paris_hilton/013_setup_raffle_paris_hilton_signer.ts index c80ba60f7e..6b457c8183 100644 --- a/packages/deploy/deploy/26_raffle_paris_hilton/013_setup_raffle_paris_hilton_signer.ts +++ b/packages/deploy/deploy/26_raffle_paris_hilton/013_setup_raffle_paris_hilton_signer.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['ParisHilton', 'ParisHilton_setup', 'ParisHilton_setup_signer']; +func.tags = [ + 'ParisHilton', + 'ParisHilton_setup', + 'ParisHilton_setup_signer', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['ParisHilton_deploy']; diff --git a/packages/deploy/deploy/26_raffle_paris_hilton/014_change_owner_paris_hilton.ts b/packages/deploy/deploy/26_raffle_paris_hilton/014_change_owner_paris_hilton.ts index 47a9637ea4..9710eabca2 100644 --- a/packages/deploy/deploy/26_raffle_paris_hilton/014_change_owner_paris_hilton.ts +++ b/packages/deploy/deploy/26_raffle_paris_hilton/014_change_owner_paris_hilton.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -21,5 +22,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['ParisHilton', 'ParisHilton_change_admin']; +func.tags = [ + 'ParisHilton', + 'ParisHilton_change_admin', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['ParisHilton_deploy']; diff --git a/packages/deploy/deploy/27_avatar_implementations/deploy_mock_collection_AvatarCollection.ts b/packages/deploy/deploy/27_avatar_implementations/deploy_mock_collection_AvatarCollection.ts index 8dc0ce6b30..685f7ca9f5 100644 --- a/packages/deploy/deploy/27_avatar_implementations/deploy_mock_collection_AvatarCollection.ts +++ b/packages/deploy/deploy/27_avatar_implementations/deploy_mock_collection_AvatarCollection.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; /* This script remains as an example as how to deploy a collection using hardhat. Since we implemented the back-office @@ -170,7 +171,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['AvatarCollectionTest', 'AvatarCollectionTest_deploy']; +func.tags = [ + 'AvatarCollectionTest', + 'AvatarCollectionTest_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'PolygonSand_deploy', 'CollectionFactory_deploy_beacon_main_avatar', diff --git a/packages/deploy/deploy/300_catalyst/300_catalyst_mint.ts b/packages/deploy/deploy/300_catalyst/300_catalyst_mint.ts index 53509e2d79..8c8d80c366 100644 --- a/packages/deploy/deploy/300_catalyst/300_catalyst_mint.ts +++ b/packages/deploy/deploy/300_catalyst/300_catalyst_mint.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -46,5 +47,10 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Catalyst_mint', 'L2']; +func.tags = [ + 'Catalyst_mint', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Catalyst_deploy']; diff --git a/packages/deploy/deploy/300_catalyst/300_deploy_operator_filter_subscription.ts b/packages/deploy/deploy/300_catalyst/300_deploy_operator_filter_subscription.ts index 6bde8c591c..96c432c8f7 100644 --- a/packages/deploy/deploy/300_catalyst/300_deploy_operator_filter_subscription.ts +++ b/packages/deploy/deploy/300_catalyst/300_deploy_operator_filter_subscription.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -33,5 +34,7 @@ export default func; func.tags = [ 'OperatorFilterCatalystSubscription', 'OperatorFilterCatalystSubscription_deploy', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; diff --git a/packages/deploy/deploy/300_catalyst/301_deploy_catalyst.ts b/packages/deploy/deploy/300_catalyst/301_deploy_catalyst.ts index 03a9fd7bc6..0769a5b1c6 100644 --- a/packages/deploy/deploy/300_catalyst/301_deploy_catalyst.ts +++ b/packages/deploy/deploy/300_catalyst/301_deploy_catalyst.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; export const CATALYST_BASE_URI = 'ipfs://'; @@ -53,7 +54,14 @@ const func: DeployFunction = async function ( }); }; export default func; -func.tags = ['Catalyst', 'Catalyst_deploy', 'L2', 'CatalystV1']; +func.tags = [ + 'Catalyst', + 'Catalyst_deploy', + 'CatalystV1', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'OperatorFilterCatalystSubscription_deploy', 'RoyaltyManager_deploy', diff --git a/packages/deploy/deploy/300_catalyst/302_catalyst_setup.ts b/packages/deploy/deploy/300_catalyst/302_catalyst_setup.ts index 141abf70fa..d4b8fb5232 100644 --- a/packages/deploy/deploy/300_catalyst/302_catalyst_setup.ts +++ b/packages/deploy/deploy/300_catalyst/302_catalyst_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; export const royaltyAmount = 500; @@ -35,5 +36,11 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['Catalyst', 'Catalyst_setup', 'L2']; +func.tags = [ + 'Catalyst', + 'Catalyst_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Catalyst_deploy', 'RoyaltyManager_deploy']; diff --git a/packages/deploy/deploy/300_catalyst/303_upgrade_catalyst.ts b/packages/deploy/deploy/300_catalyst/303_upgrade_catalyst.ts index a87fc4d76f..69019f850b 100644 --- a/packages/deploy/deploy/300_catalyst/303_upgrade_catalyst.ts +++ b/packages/deploy/deploy/300_catalyst/303_upgrade_catalyst.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -24,5 +25,10 @@ const func: DeployFunction = async function ( ); }; export default func; -func.tags = ['Catalyst_upgrade', 'L2']; +func.tags = [ + 'Catalyst_upgrade', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Catalyst_deploy', 'Catalyst_setup']; diff --git a/packages/deploy/deploy/400_asset/400_deploy_operator_filter_asset_subscription.ts b/packages/deploy/deploy/400_asset/400_deploy_operator_filter_asset_subscription.ts index 477ca3533d..20f99de712 100644 --- a/packages/deploy/deploy/400_asset/400_deploy_operator_filter_asset_subscription.ts +++ b/packages/deploy/deploy/400_asset/400_deploy_operator_filter_asset_subscription.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -32,5 +33,7 @@ export default func; func.tags = [ 'OperatorFilterAssetSubscription', 'OperatorFilterAssetSubscription_deploy', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; diff --git a/packages/deploy/deploy/400_asset/401_deploy_asset_auth_validator.ts b/packages/deploy/deploy/400_asset/401_deploy_asset_auth_validator.ts index 4a8aac346b..76390459c7 100644 --- a/packages/deploy/deploy/400_asset/401_deploy_asset_auth_validator.ts +++ b/packages/deploy/deploy/400_asset/401_deploy_asset_auth_validator.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -15,4 +16,10 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['AuthSuperValidator', 'AuthSuperValidator_deploy', 'L2']; +func.tags = [ + 'AuthSuperValidator', + 'AuthSuperValidator_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/400_asset/402_deploy_asset.ts b/packages/deploy/deploy/400_asset/402_deploy_asset.ts index 0e4cc5392c..4855fe1d78 100644 --- a/packages/deploy/deploy/400_asset/402_deploy_asset.ts +++ b/packages/deploy/deploy/400_asset/402_deploy_asset.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -35,7 +36,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Asset', 'Asset_deploy', 'L2']; +func.tags = [ + 'Asset', + 'Asset_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'OperatorFilterAssetSubscription_deploy', 'TRUSTED_FORWARDER_V2', diff --git a/packages/deploy/deploy/400_asset/403_deploy_asset_create.ts b/packages/deploy/deploy/400_asset/403_deploy_asset_create.ts index 70ad1b022b..1f03222ba9 100644 --- a/packages/deploy/deploy/400_asset/403_deploy_asset_create.ts +++ b/packages/deploy/deploy/400_asset/403_deploy_asset_create.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -41,7 +42,14 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Asset', 'AssetCreate', 'AssetCreate_deploy', 'L2']; +func.tags = [ + 'Asset', + 'AssetCreate', + 'AssetCreate_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'Asset_deploy', 'Catalyst_deploy', diff --git a/packages/deploy/deploy/400_asset/404_deploy_asset_reveal.ts b/packages/deploy/deploy/400_asset/404_deploy_asset_reveal.ts index 1eab5bcc10..40ab2a3a89 100644 --- a/packages/deploy/deploy/400_asset/404_deploy_asset_reveal.ts +++ b/packages/deploy/deploy/400_asset/404_deploy_asset_reveal.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -39,7 +40,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['AssetReveal', 'AssetReveal_deploy', 'L2']; +func.tags = [ + 'AssetReveal', + 'AssetReveal_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'Asset_deploy', 'AuthSuperValidator_deploy', diff --git a/packages/deploy/deploy/400_asset/405_asset_create_setup.ts b/packages/deploy/deploy/400_asset/405_asset_create_setup.ts index 0b46760a4b..10fe628d46 100644 --- a/packages/deploy/deploy/400_asset/405_asset_create_setup.ts +++ b/packages/deploy/deploy/400_asset/405_asset_create_setup.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -75,5 +76,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { export default func; -func.tags = ['Asset', 'AssetCreate', 'AssetCreate_setup']; +func.tags = [ + 'Asset', + 'AssetCreate', + 'AssetCreate_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Asset_deploy', 'Catalyst_deploy', 'AssetCreate_deploy']; diff --git a/packages/deploy/deploy/400_asset/406_asset_reveal_setup.ts b/packages/deploy/deploy/400_asset/406_asset_reveal_setup.ts index af61ddcfee..e99fad5c45 100644 --- a/packages/deploy/deploy/400_asset/406_asset_reveal_setup.ts +++ b/packages/deploy/deploy/400_asset/406_asset_reveal_setup.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -77,5 +78,10 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { export default func; -func.tags = ['AssetReveal_setup']; +func.tags = [ + 'AssetReveal_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Asset_deploy', 'AssetCreate_deploy']; diff --git a/packages/deploy/deploy/400_asset/407_asset_setup.ts b/packages/deploy/deploy/400_asset/407_asset_setup.ts index b0efff5187..bac958be7b 100644 --- a/packages/deploy/deploy/400_asset/407_asset_setup.ts +++ b/packages/deploy/deploy/400_asset/407_asset_setup.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; export const DEFAULT_BPS = 500; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { @@ -67,5 +68,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { export default func; -func.tags = ['Asset', 'Asset_setup']; +func.tags = [ + 'Asset', + 'Asset_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Asset_deploy']; diff --git a/packages/deploy/deploy/400_asset/408_upgrade_asset_create.ts b/packages/deploy/deploy/400_asset/408_upgrade_asset_create.ts index b1d5f4be70..ee245ada56 100644 --- a/packages/deploy/deploy/400_asset/408_upgrade_asset_create.ts +++ b/packages/deploy/deploy/400_asset/408_upgrade_asset_create.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -24,5 +25,10 @@ const func: DeployFunction = async function ( ); }; export default func; -func.tags = ['AssetCreate_upgrade', 'L2']; +func.tags = [ + 'AssetCreate_upgrade', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Exchange_deploy']; diff --git a/packages/deploy/deploy/400_asset/409_deploy_updated_auth_validator.ts b/packages/deploy/deploy/400_asset/409_deploy_updated_auth_validator.ts index 5e07b15c59..ab30802253 100644 --- a/packages/deploy/deploy/400_asset/409_deploy_updated_auth_validator.ts +++ b/packages/deploy/deploy/400_asset/409_deploy_updated_auth_validator.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -15,4 +16,9 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['AuthSuperValidator_v2', 'L2']; +func.tags = [ + 'AuthSuperValidator_v2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/400_asset/410_lazy_minting_setup.ts b/packages/deploy/deploy/400_asset/410_lazy_minting_setup.ts index 213e6b2542..d4f7c8e31a 100644 --- a/packages/deploy/deploy/400_asset/410_lazy_minting_setup.ts +++ b/packages/deploy/deploy/400_asset/410_lazy_minting_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -141,5 +142,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { export default func; -func.tags = ['AssetCreate_upgrade', 'AssetCreate_lazy_setup']; +func.tags = [ + 'AssetCreate_upgrade', + 'AssetCreate_lazy_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['AuthSuperValidator_v2']; diff --git a/packages/deploy/deploy/500_marketplace/500_deploy_royalties_registry.ts b/packages/deploy/deploy/500_marketplace/500_deploy_royalties_registry.ts index 86450b83ef..d628529c85 100644 --- a/packages/deploy/deploy/500_marketplace/500_deploy_royalties_registry.ts +++ b/packages/deploy/deploy/500_marketplace/500_deploy_royalties_registry.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -24,4 +25,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['RoyaltiesRegistry', 'RoyaltiesRegistry_deploy']; +func.tags = [ + 'RoyaltiesRegistry', + 'RoyaltiesRegistry_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/500_marketplace/501_royalties_registry_setup.ts b/packages/deploy/deploy/500_marketplace/501_royalties_registry_setup.ts index 7af74a3d3f..462cb95c8a 100644 --- a/packages/deploy/deploy/500_marketplace/501_royalties_registry_setup.ts +++ b/packages/deploy/deploy/500_marketplace/501_royalties_registry_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -21,5 +22,14 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['RoyaltiesRegistry', 'RoyaltiesRegistry_setup']; +func.tags = [ + 'RoyaltiesRegistry', + 'RoyaltiesRegistry_setup', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['RoyaltiesRegistry_deploy']; diff --git a/packages/deploy/deploy/500_marketplace/502_deploy_order_validator.ts b/packages/deploy/deploy/500_marketplace/502_deploy_order_validator.ts index ff8b986cb6..e6236efe24 100644 --- a/packages/deploy/deploy/500_marketplace/502_deploy_order_validator.ts +++ b/packages/deploy/deploy/500_marketplace/502_deploy_order_validator.ts @@ -1,6 +1,7 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; -import {DeployFunction} from 'hardhat-deploy/types'; import {keccak256, toUtf8Bytes} from 'ethers'; +import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -28,4 +29,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['OrderValidator', 'OrderValidator_deploy']; +func.tags = [ + 'OrderValidator', + 'OrderValidator_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; diff --git a/packages/deploy/deploy/500_marketplace/503_order_validator_setup.ts b/packages/deploy/deploy/500_marketplace/503_order_validator_setup.ts index 4cacf36ee3..f556110820 100644 --- a/packages/deploy/deploy/500_marketplace/503_order_validator_setup.ts +++ b/packages/deploy/deploy/500_marketplace/503_order_validator_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -96,7 +97,16 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['OrderValidator', 'OrderValidator_setup']; +func.tags = [ + 'OrderValidator', + 'OrderValidator_setup', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'OrderValidator_deploy', 'PolygonSand_deploy', diff --git a/packages/deploy/deploy/500_marketplace/504_deploy_exchange.ts b/packages/deploy/deploy/500_marketplace/504_deploy_exchange.ts index 1599ea3f04..99c661e949 100644 --- a/packages/deploy/deploy/500_marketplace/504_deploy_exchange.ts +++ b/packages/deploy/deploy/500_marketplace/504_deploy_exchange.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -41,7 +42,16 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; export default func; -func.tags = ['Exchange', 'Exchange_deploy']; +func.tags = [ + 'Exchange', + 'Exchange_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'RoyaltiesRegistry_deploy', 'OrderValidator_deploy', diff --git a/packages/deploy/deploy/500_marketplace/505_exchange_setup.ts b/packages/deploy/deploy/500_marketplace/505_exchange_setup.ts index 87dfc02215..83bc8be94c 100644 --- a/packages/deploy/deploy/500_marketplace/505_exchange_setup.ts +++ b/packages/deploy/deploy/500_marketplace/505_exchange_setup.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -50,5 +51,14 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['Exchange', 'Exchange_setup']; +func.tags = [ + 'Exchange', + 'Exchange_setup', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['Exchange_deploy', 'PolygonSand_deploy']; diff --git a/packages/deploy/deploy/600_faucets/600_deploy_faucetsERC1155.ts b/packages/deploy/deploy/600_faucets/600_deploy_faucetsERC1155.ts index df1bfa7d74..e755090e84 100644 --- a/packages/deploy/deploy/600_faucets/600_deploy_faucetsERC1155.ts +++ b/packages/deploy/deploy/600_faucets/600_deploy_faucetsERC1155.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -15,6 +16,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }); }; -func.tags = ['FaucetsERC1155', 'FaucetsERC1155_deploy']; +func.tags = [ + 'FaucetsERC1155', + 'FaucetsERC1155_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_TEST, +]; export default func; diff --git a/packages/deploy/deploy/700_land/land/710_deploy_land.ts b/packages/deploy/deploy/700_land/land/710_deploy_land.ts index dbd1ea7fc0..01fa828dc8 100644 --- a/packages/deploy/deploy/700_land/land/710_deploy_land.ts +++ b/packages/deploy/deploy/700_land/land/710_deploy_land.ts @@ -1,6 +1,7 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; -import {DeployFunction} from 'hardhat-deploy/types'; import {ZeroAddress} from 'ethers'; +import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -24,4 +25,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { ); }; export default func; -func.tags = ['Land', 'LandV1', 'Land_deploy', 'L1']; +func.tags = [ + 'Land', + 'LandV1', + 'Land_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; diff --git a/packages/deploy/deploy/700_land/land/720_upgrade_land_v2.ts b/packages/deploy/deploy/700_land/land/720_upgrade_land_v2.ts index ec60b26b11..e2ce6d469a 100644 --- a/packages/deploy/deploy/700_land/land/720_upgrade_land_v2.ts +++ b/packages/deploy/deploy/700_land/land/720_upgrade_land_v2.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -20,5 +21,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Land', 'LandV2', 'LandV2_deploy', 'L1']; +func.tags = [ + 'Land', + 'LandV2', + 'LandV2_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; func.dependencies = ['Land_deploy']; diff --git a/packages/deploy/deploy/700_land/land/730_upgrade_land_v3.ts b/packages/deploy/deploy/700_land/land/730_upgrade_land_v3.ts index c2f58a0630..ae85a041c3 100644 --- a/packages/deploy/deploy/700_land/land/730_upgrade_land_v3.ts +++ b/packages/deploy/deploy/700_land/land/730_upgrade_land_v3.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -20,5 +21,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Land', 'LandV3', 'LandV3_deploy', 'L1']; +func.tags = [ + 'Land', + 'LandV3', + 'LandV3_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; func.dependencies = ['LandV2_deploy']; diff --git a/packages/deploy/deploy/700_land/land/731_setup_land_v3_operator_filterer.ts b/packages/deploy/deploy/700_land/land/731_setup_land_v3_operator_filterer.ts index 406952e1ea..b6d8c19607 100644 --- a/packages/deploy/deploy/700_land/land/731_setup_land_v3_operator_filterer.ts +++ b/packages/deploy/deploy/700_land/land/731_setup_land_v3_operator_filterer.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -34,5 +35,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { } }; export default func; -func.tags = ['Land', 'LandV3_setup', 'L1']; +func.tags = [ + 'Land', + 'LandV3_setup', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; func.dependencies = ['LandV3_deploy', 'OperatorFilterLandSubscription']; diff --git a/packages/deploy/deploy/700_land/land/740_upgrade_land_v4.ts b/packages/deploy/deploy/700_land/land/740_upgrade_land_v4.ts index 92b423188f..eee376903b 100644 --- a/packages/deploy/deploy/700_land/land/740_upgrade_land_v4.ts +++ b/packages/deploy/deploy/700_land/land/740_upgrade_land_v4.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -20,5 +21,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { }; export default func; -func.tags = ['Land', 'LandV4', 'LandV4_deploy', 'L1']; +func.tags = [ + 'Land', + 'LandV4', + 'LandV4_deploy', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; func.dependencies = ['LandV3_deploy']; diff --git a/packages/deploy/deploy/700_land/land/741_setup_land_v4_royalties.ts b/packages/deploy/deploy/700_land/land/741_setup_land_v4_royalties.ts index 9222057eb5..55db36fabd 100644 --- a/packages/deploy/deploy/700_land/land/741_setup_land_v4_royalties.ts +++ b/packages/deploy/deploy/700_land/land/741_setup_land_v4_royalties.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -27,6 +28,8 @@ func.tags = [ 'LandV4_setup', 'LandRoyaltyManager', 'LandRoyaltyManager_setup', - 'L1', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, ]; func.dependencies = ['LandV4_deploy', 'RoyaltyManager_deploy']; diff --git a/packages/deploy/deploy/700_land/land/742_setup_land_v4_owner.ts b/packages/deploy/deploy/700_land/land/742_setup_land_v4_owner.ts index a3e1c714b0..b239f9b972 100644 --- a/packages/deploy/deploy/700_land/land/742_setup_land_v4_owner.ts +++ b/packages/deploy/deploy/700_land/land/742_setup_land_v4_owner.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -21,5 +22,13 @@ const func: DeployFunction = async function ( }; export default func; -func.tags = ['Land', 'LandV4_setup', 'LandOwner', 'LandOwner_setup', 'L1']; +func.tags = [ + 'Land', + 'LandV4_setup', + 'LandOwner', + 'LandOwner_setup', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, +]; func.dependencies = ['LandV4_deploy']; diff --git a/packages/deploy/deploy/700_land/land/743_setup_land_v4_registry.ts b/packages/deploy/deploy/700_land/land/743_setup_land_v4_registry.ts index 3dd2fbec60..246cdb0609 100644 --- a/packages/deploy/deploy/700_land/land/743_setup_land_v4_registry.ts +++ b/packages/deploy/deploy/700_land/land/743_setup_land_v4_registry.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -27,6 +28,8 @@ func.tags = [ 'LandV4_setup', 'LandMetadataRegistry', 'LandMetadataRegistry_setup', - 'L1', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, ]; func.dependencies = ['LandMetadataRegistry_deploy', 'LandV4_deploy']; diff --git a/packages/deploy/deploy/700_land/land/750_deploy_land_registry.ts b/packages/deploy/deploy/700_land/land/750_deploy_land_registry.ts index 2c9b2b3f46..67e6692367 100644 --- a/packages/deploy/deploy/700_land/land/750_deploy_land_registry.ts +++ b/packages/deploy/deploy/700_land/land/750_deploy_land_registry.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -29,6 +30,8 @@ func.tags = [ 'Land', 'LandMetadataRegistry', 'LandMetadataRegistry_deploy', - 'L1', + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, ]; export default func; diff --git a/packages/deploy/deploy/700_land/polygonLand/710_deploy_polygon_land.ts b/packages/deploy/deploy/700_land/polygonLand/710_deploy_polygon_land.ts index a1cfed0e96..40de679afe 100644 --- a/packages/deploy/deploy/700_land/polygonLand/710_deploy_polygon_land.ts +++ b/packages/deploy/deploy/700_land/polygonLand/710_deploy_polygon_land.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -25,5 +26,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { ); }; export default func; -func.tags = ['PolygonLand', 'PolygonLandV1', 'PolygonLand_deploy', 'L2']; +func.tags = [ + 'PolygonLand', + 'PolygonLandV1', + 'PolygonLand_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['TRUSTED_FORWARDER_V2']; diff --git a/packages/deploy/deploy/700_land/polygonLand/711_setup_polygon_land_admin.ts b/packages/deploy/deploy/700_land/polygonLand/711_setup_polygon_land_admin.ts index 5f9ec5500c..965e63379c 100644 --- a/packages/deploy/deploy/700_land/polygonLand/711_setup_polygon_land_admin.ts +++ b/packages/deploy/deploy/700_land/polygonLand/711_setup_polygon_land_admin.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -18,5 +19,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { } }; export default func; -func.tags = ['PolygonLand', 'PolygonLand_setup', 'L2']; +func.tags = [ + 'PolygonLand', + 'PolygonLand_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['PolygonLand_deploy']; diff --git a/packages/deploy/deploy/700_land/polygonLand/720_upgrade_polygon_land_v2.ts b/packages/deploy/deploy/700_land/polygonLand/720_upgrade_polygon_land_v2.ts index 99f5d00c87..7ceed588f2 100644 --- a/packages/deploy/deploy/700_land/polygonLand/720_upgrade_polygon_land_v2.ts +++ b/packages/deploy/deploy/700_land/polygonLand/720_upgrade_polygon_land_v2.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -20,5 +21,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { ); }; export default func; -func.tags = ['PolygonLand', 'PolygonLandV2', 'PolygonLandV2_deploy', 'L2']; +func.tags = [ + 'PolygonLand', + 'PolygonLandV2', + 'PolygonLandV2_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['PolygonLand_deploy']; diff --git a/packages/deploy/deploy/700_land/polygonLand/721_setup_polygon_land_v2_operator_filterer.ts b/packages/deploy/deploy/700_land/polygonLand/721_setup_polygon_land_v2_operator_filterer.ts index 872442b48e..372436230d 100644 --- a/packages/deploy/deploy/700_land/polygonLand/721_setup_polygon_land_v2_operator_filterer.ts +++ b/packages/deploy/deploy/700_land/polygonLand/721_setup_polygon_land_v2_operator_filterer.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -34,7 +35,13 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { } }; export default func; -func.tags = ['PolygonLand', 'PolygonLandV2_setup', 'L2']; +func.tags = [ + 'PolygonLand', + 'PolygonLandV2_setup', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = [ 'PolygonLandV2_deploy', 'OperatorFilterLandSubscription', diff --git a/packages/deploy/deploy/700_land/polygonLand/730_upgrade_polygon_land_v3.ts b/packages/deploy/deploy/700_land/polygonLand/730_upgrade_polygon_land_v3.ts index f06199335a..23ef9203a7 100644 --- a/packages/deploy/deploy/700_land/polygonLand/730_upgrade_polygon_land_v3.ts +++ b/packages/deploy/deploy/700_land/polygonLand/730_upgrade_polygon_land_v3.ts @@ -1,5 +1,6 @@ -import {HardhatRuntimeEnvironment} from 'hardhat/types'; import {DeployFunction} from 'hardhat-deploy/types'; +import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -20,5 +21,12 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { ); }; export default func; -func.tags = ['PolygonLand', 'PolygonLandV3', 'PolygonLandV3_deploy', 'L2']; +func.tags = [ + 'PolygonLand', + 'PolygonLandV3', + 'PolygonLandV3_deploy', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, +]; func.dependencies = ['PolygonLandV2_deploy']; diff --git a/packages/deploy/deploy/700_land/polygonLand/731_setup_polygon_land_v3_royalties.ts b/packages/deploy/deploy/700_land/polygonLand/731_setup_polygon_land_v3_royalties.ts index 536b5247a2..b025247977 100644 --- a/packages/deploy/deploy/700_land/polygonLand/731_setup_polygon_land_v3_royalties.ts +++ b/packages/deploy/deploy/700_land/polygonLand/731_setup_polygon_land_v3_royalties.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -27,7 +28,9 @@ func.tags = [ 'PolygonLandV3_setup', 'PolygonRoyaltyManager', 'PolygonRoyaltyManager_setup', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = [ 'PolygonLandV3_deploy', diff --git a/packages/deploy/deploy/700_land/polygonLand/732_setup_polygon_land_v3_owner.ts b/packages/deploy/deploy/700_land/polygonLand/732_setup_polygon_land_v3_owner.ts index 798e5b6fca..4d4c73e2c8 100644 --- a/packages/deploy/deploy/700_land/polygonLand/732_setup_polygon_land_v3_owner.ts +++ b/packages/deploy/deploy/700_land/polygonLand/732_setup_polygon_land_v3_owner.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -26,6 +27,8 @@ func.tags = [ 'PolygonLandV3_setup', 'PolygonLandOwner', 'PolygonLandOwner_setup', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = ['PolygonLandV3_deploy', 'PolygonLand_setup']; diff --git a/packages/deploy/deploy/700_land/polygonLand/733_setup_polygon_land_v3_registry.ts b/packages/deploy/deploy/700_land/polygonLand/733_setup_polygon_land_v3_registry.ts index 94d354a56c..e71b4b20e5 100644 --- a/packages/deploy/deploy/700_land/polygonLand/733_setup_polygon_land_v3_registry.ts +++ b/packages/deploy/deploy/700_land/polygonLand/733_setup_polygon_land_v3_registry.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function ( hre: HardhatRuntimeEnvironment @@ -27,7 +28,9 @@ func.tags = [ 'PolygonLandV3_setup', 'PolygonLandMetadataRegistry', 'PolygonLandMetadataRegistry_setup', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; func.dependencies = [ 'PolygonLandMetadataRegistry_deploy', diff --git a/packages/deploy/deploy/700_land/polygonLand/750_deploy_polygon_land_registry.ts b/packages/deploy/deploy/700_land/polygonLand/750_deploy_polygon_land_registry.ts index 654101c75f..1170ae99f4 100644 --- a/packages/deploy/deploy/700_land/polygonLand/750_deploy_polygon_land_registry.ts +++ b/packages/deploy/deploy/700_land/polygonLand/750_deploy_polygon_land_registry.ts @@ -1,5 +1,6 @@ import {DeployFunction} from 'hardhat-deploy/types'; import {HardhatRuntimeEnvironment} from 'hardhat/types'; +import {DEPLOY_TAGS} from '../../../hardhat.config'; const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) { const {deployments, getNamedAccounts} = hre; @@ -29,6 +30,8 @@ func.tags = [ 'PolygonLand', 'PolygonLandMetadataRegistry', 'PolygonLandMetadataRegistry_deploy', - 'L2', + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, ]; export default func; diff --git a/packages/deploy/hardhat.config.ts b/packages/deploy/hardhat.config.ts index 28cb4ce821..8a53fadf8f 100644 --- a/packages/deploy/hardhat.config.ts +++ b/packages/deploy/hardhat.config.ts @@ -304,7 +304,7 @@ export enum DEPLOY_NETWORKS { HARDHAT = 'hardhat', ETH_SEPOLIA = 'sepolia', ETH_GOERLI = 'goerli', - EHT_MAINNET = 'mainnet', + ETH_MAINNET = 'mainnet', BSC_TESTNET = 'bscTestnet', BSC_MAINNET = 'bscMainnet', AMOY = 'amoy', @@ -314,19 +314,28 @@ export enum DEPLOY_NETWORKS { BASE_MAINNET = 'base', } -/** - * TAGS: - * - mainnet -> production DEPLOY_NETWORKS (you must pay for gas!!!) - * - L1, L1-prod, L1-test -> Layer 1 DEPLOY_NETWORKS - * - L2, L2-prod, L2-test -> Layer 2 DEPLOY_NETWORKS - */ +export enum DEPLOY_TAGS { + L1 = 'L1', // Layer one networks like Ethereum mainnet, sepolia + L1_PROD = 'L1-prod', // Layer one production networks like Ethereum mainnet + L1_TEST = 'L1-test', // Layer one test networks like Goerli + L2 = 'L2', // Layer two networks like Polygon, mumbai + L2_PROD = 'L2-prod', // Layer two production networks like Polygon + L2_TEST = 'L2-test', // Layer two test networks like Mumbai +} const networks = { [DEPLOY_NETWORKS.HARDHAT]: { - tags: ['L1', 'L1-prod', 'L1-test', 'L2', 'L2-prod', 'L2-test'], + tags: [ + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L2_TEST, + ], deploy: ['deploy_mocks/', 'deploy/'], companionNetworks: { - [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.HARDHAT, + [DEPLOY_NETWORKS.ETH_MAINNET]: DEPLOY_NETWORKS.HARDHAT, [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.HARDHAT, [DEPLOY_NETWORKS.BSC_MAINNET]: DEPLOY_NETWORKS.HARDHAT, }, @@ -334,22 +343,22 @@ const networks = { parseInt(process.env.HARDHAT_BLOCK_GAS_LIMIT || '0') || 30000000, }, [DEPLOY_NETWORKS.ETH_GOERLI]: { - tags: ['L1'], + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_TEST], // gasPrice: 600000000000, // Uncomment in case of pending txs, and adjust gas companionNetworks: { [DEPLOY_NETWORKS.MUMBAI]: DEPLOY_NETWORKS.MUMBAI, }, }, [DEPLOY_NETWORKS.ETH_SEPOLIA]: { - tags: ['L1', 'L1-test'], + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_PROD], companionNetworks: { [DEPLOY_NETWORKS.AMOY]: DEPLOY_NETWORKS.AMOY, [DEPLOY_NETWORKS.BASE_SEPOLIA]: DEPLOY_NETWORKS.BASE_SEPOLIA, [DEPLOY_NETWORKS.BSC_TESTNET]: DEPLOY_NETWORKS.BSC_TESTNET, }, }, - [DEPLOY_NETWORKS.EHT_MAINNET]: { - tags: ['mainnet', 'L1', 'L1-prod'], + [DEPLOY_NETWORKS.ETH_MAINNET]: { + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_PROD], companionNetworks: { [DEPLOY_NETWORKS.POLYGON]: DEPLOY_NETWORKS.POLYGON, [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.BASE_MAINNET, @@ -357,48 +366,48 @@ const networks = { }, }, [DEPLOY_NETWORKS.BSC_TESTNET]: { - tags: ['L1', 'L1-test'], + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_TEST], companionNetworks: { [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, [DEPLOY_NETWORKS.BASE_SEPOLIA]: DEPLOY_NETWORKS.BASE_SEPOLIA, }, }, [DEPLOY_NETWORKS.BSC_MAINNET]: { - tags: ['L1', 'L1-prod'], + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_PROD], companionNetworks: { - [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, + [DEPLOY_NETWORKS.ETH_MAINNET]: DEPLOY_NETWORKS.ETH_MAINNET, [DEPLOY_NETWORKS.BASE_MAINNET]: DEPLOY_NETWORKS.BASE_MAINNET, }, }, [DEPLOY_NETWORKS.MUMBAI]: { - tags: ['L2', 'L2-test'], + tags: [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_TEST], companionNetworks: { [DEPLOY_NETWORKS.ETH_GOERLI]: DEPLOY_NETWORKS.ETH_GOERLI, }, }, [DEPLOY_NETWORKS.AMOY]: { - tags: ['L2', 'L2-test'], + tags: [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_TEST], companionNetworks: { [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, }, }, [DEPLOY_NETWORKS.POLYGON]: { - tags: ['L2', 'L2-prod'], + tags: [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_PROD], companionNetworks: { - [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, + [DEPLOY_NETWORKS.ETH_MAINNET]: DEPLOY_NETWORKS.ETH_MAINNET, }, }, [DEPLOY_NETWORKS.BASE_SEPOLIA]: { - tags: ['L2', 'L2-test'], + tags: [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_TEST], companionNetworks: { [DEPLOY_NETWORKS.ETH_SEPOLIA]: DEPLOY_NETWORKS.ETH_SEPOLIA, [DEPLOY_NETWORKS.BSC_TESTNET]: DEPLOY_NETWORKS.BSC_TESTNET, }, }, [DEPLOY_NETWORKS.BASE_MAINNET]: { - tags: ['L2', 'L2-prod'], + tags: [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_PROD], companionNetworks: { - [DEPLOY_NETWORKS.EHT_MAINNET]: DEPLOY_NETWORKS.EHT_MAINNET, + [DEPLOY_NETWORKS.ETH_MAINNET]: DEPLOY_NETWORKS.ETH_MAINNET, [DEPLOY_NETWORKS.BSC_MAINNET]: DEPLOY_NETWORKS.BSC_MAINNET, }, }, From bf99ef1426473e9fa1c5fb85ab30754b1c11f003 Mon Sep 17 00:00:00 2001 From: wojciech-turek Date: Fri, 26 Jul 2024 11:00:18 +0200 Subject: [PATCH 4/4] Add more documentation on the network tags --- packages/deploy/README.md | 162 ++++++++++++++++++++++++++++++++++++-- 1 file changed, 154 insertions(+), 8 deletions(-) diff --git a/packages/deploy/README.md b/packages/deploy/README.md index 0982e4c796..2d505281de 100644 --- a/packages/deploy/README.md +++ b/packages/deploy/README.md @@ -44,14 +44,160 @@ where: executed ( see:[hardhat-deploy](https://github.com/wighawag/hardhat-deploy) configuration) -- There is a specific set of tags related to network on which each script was - meant to run. - - L1 = 'L1', // Layer one networks like Ethereum mainnet, sepolia - - L1_PROD = 'L1-prod', // Layer one production networks like Ethereum mainnet - - L1_TEST = 'L1-test', // Layer one test networks like Goerli - - L2 = 'L2', // Layer two networks like Polygon, mumbai - - L2_PROD = 'L2-prod', // Layer two production networks like Polygon - - L2_TEST = 'L2-test', // Layer two test networks like Mumbai +## Deployment Tags Documentation + +This sections aims to clarify the use of deployment tags within our deploy +package. The configured enum `DEPLOY_TAGS` helps us manage deployment files +effectively, allowing us to easier identify which scripts are meant to run on +specific networks. + +### DEPLOY_TAGS Enum + +```typescript +export enum DEPLOY_TAGS { + L1 = 'L1', // Layer one networks like Ethereum mainnet, Sepolia + L1_PROD = 'L1-prod', // Layer one production networks like Ethereum mainnet + L1_TEST = 'L1-test', // Layer one test networks like Goerli + L2 = 'L2', // Layer two networks like Polygon, Mumbai + L2_PROD = 'L2-prod', // Layer two production networks like Polygon + L2_TEST = 'L2-test', // Layer two test networks like Mumbai +} +``` + +These tags help distinguish which scripts are written for L1 or L2 networks and +which should only run on test networks because they are mocks or supplementary +scripts. + +### Networks Configuration + +Here is an example configuration of networks within our Hardhat project that +uses these tags: + +```typescript +const networks = { + [DEPLOY_NETWORKS.ETH_GOERLI]: { + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_TEST], + companionNetworks: { + [DEPLOY_NETWORKS.MUMBAI]: DEPLOY_NETWORKS.MUMBAI, + }, + }, + [DEPLOY_NETWORKS.ETH_SEPOLIA]: { + tags: [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_PROD], + companionNetworks: { + [DEPLOY_NETWORKS.AMOY]: DEPLOY_NETWORKS.AMOY, + [DEPLOY_NETWORKS.BASE_SEPOLIA]: DEPLOY_NETWORKS.BASE_SEPOLIA, + [DEPLOY_NETWORKS.BSC_TESTNET]: DEPLOY_NETWORKS.BSC_TESTNET, + }, + }, + // other network configurations... +}; +``` + +## Usage Guidelines + +### When to Add Tags + +1. **L1 Networks (Layer 1)** + + - **L1**: General tag for scripts intended to run on any Layer 1 network. + - **L1_PROD**: Use for scripts meant only for Layer 1 production networks + (e.g., Ethereum mainnet). + - **L1_TEST**: Tag scripts intended for Layer 1 test networks (e.g., Goerli, + Sepolia). + +2. **L2 Networks (Layer 2)** + + - **L2**: General tag for scripts intended to run on any Layer 2 network. + - **L2_PROD**: Use for scripts meant only for Layer 2 production networks + (e.g., Polygon). + - **L2_TEST**: Tag scripts intended for Layer 2 test networks (e.g., Mumbai). + +### Example Scenarios + +1. **Deploying a Mock Contract on Amoy** + + - If you have a mock contract that should only be deployed on test networks + for testing purposes, tag the script with `L2` and `L2_TEST`. + - Use the `DEPLOY_NETWORKS` enum to specify to which network the script was + ran on. + - Example: + + ```typescript + // deploy_mocks/deployMockContract.ts + const func: DeployFunction = async function ( + hre: HardhatRuntimeEnvironment + ) { + const {deployments, getNamedAccounts} = hre; + const {deploy} = deployments; + + await deploy('MockContract', { + from: deployer, + log: true, + }); + }; + + func.tags = [DEPLOY_TAGS.L2, DEPLOY_TAGS.L2_TEST]; + ``` + +2. **Deploying a Mainnet-Only Script** + + - If you have a script that should only run on the Ethereum mainnet, tag it + with `L1` and `L1_PROD` along with the `ETH_MAINNET` network tag. + - Example: + + ```typescript + // deploy/deployMainnetOnlyContract.ts + const func: DeployFunction = async function ( + hre: HardhatRuntimeEnvironment + ) { + const {deployments, getNamedAccounts} = hre; + const {deploy} = deployments; + + await deploy('MainnetOnlyContract', { + from: deployer, + log: true, + }); + }; + + func.tags = [DEPLOY_TAGS.L1, DEPLOY_TAGS.L1_PROD]; + ``` + +3. **Deploying to Both L1 and L2 Networks** + + - If you have a script that should deploy to both Layer 1 and Layer 2 + networks, use the general tags `L1` and `L2`. + - Example: + + ```typescript + // deploy/deployUniversalContract.ts + const func: DeployFunction = async function ( + hre: HardhatRuntimeEnvironment + ) { + const {deployments, getNamedAccounts} = hre; + const {deploy} = deployments; + + await deploy('UniversalContract', { + from: deployer, + log: true, + }); + }; + + func.tags = [ + DEPLOY_TAGS.L1, + DEPLOY_TAGS.L2, + DEPLOY_TAGS.L1_PROD, + DEPLOY_TAGS.L2_PROD, + DEPLOY_TAGS.L1_TEST, + DEPLOY_TAGS.L2_TEST, + ]; + ``` + +## Conclusion + +By following these guidelines and using the appropriate tags, you can ensure +that our deployment scripts are managed correctly and deployed in the intended +environments. This not only helps maintain the clarity of deployment processes +but also prevents accidental deployments to unintended networks. ## Upgrades