mirror of
https://github.com/lens-protocol/core.git
synced 2026-01-09 14:18:04 -05:00
fix: more fixed to deployment scripts
This commit is contained in:
@@ -58,6 +58,7 @@
|
||||
"chainId": 80001,
|
||||
"network": "mumbai",
|
||||
"LensHubProxy": "0x60Ae865ee4C725cd04353b5AAb364553f56ceF82",
|
||||
"ModuleGlobals": "0x1353aAdfE5FeD85382826757A95DE908bd21C4f9",
|
||||
"ProfileCreator": "0x6C1e1bC39b13f9E0Af9424D76De899203F47755F",
|
||||
"Modules": {
|
||||
"v1": {
|
||||
|
||||
@@ -66,7 +66,12 @@ contract LensV1ChangeAdmins is Script, ForkManagement {
|
||||
}
|
||||
|
||||
function _changeAdmins() internal {
|
||||
castTransaction(governance, address(legacyLensHub), 'setGovernance(address)', vm.toString(address(this)));
|
||||
castTransaction(
|
||||
governance,
|
||||
address(legacyLensHub),
|
||||
'setGovernance(address)',
|
||||
vm.toString(address(governanceContract))
|
||||
);
|
||||
|
||||
castTransaction(
|
||||
proxyAdmin,
|
||||
|
||||
11
script/fullV2Run.sh
Normal file
11
script/fullV2Run.sh
Normal file
@@ -0,0 +1,11 @@
|
||||
TARGET=$1
|
||||
|
||||
echo "Running Full Lens V2 Deployment on $TARGET environment"
|
||||
|
||||
bash script/run.sh LensV2UpgradeDeployment $TARGET
|
||||
|
||||
bash script/run.sh LensV1ChangeAdmins $TARGET n
|
||||
|
||||
bash script/run.sh LensV1ToV2Upgrade $TARGET
|
||||
|
||||
bash script/run.sh LensV2DeployPeriphery $TARGET
|
||||
@@ -39,7 +39,7 @@ if [[ "$CONFIRMATION" == "y" || "$CONFIRMATION" == "Y" ]]
|
||||
then
|
||||
echo "Broadcasting on-chain..."
|
||||
|
||||
FORGE_OUTPUT=$(forge script script/$SCRIPT_NAME.s.sol:$SCRIPT_NAME -s $CALLDATA --rpc-url $NETWORK --broadcast --legacy --skip test --ffi --slow -vvvv)
|
||||
FORGE_OUTPUT=$(forge script script/$SCRIPT_NAME.s.sol:$SCRIPT_NAME -s $CALLDATA --rpc-url $NETWORK --broadcast --legacy --skip test --ffi --slow -vv)
|
||||
echo "$FORGE_OUTPUT"
|
||||
else
|
||||
echo "Deployment cancelled. Execution terminated."
|
||||
|
||||
@@ -103,6 +103,8 @@ contract TestSetup is Test, ContractAddressesLoaderDeployer, ArrayHelpers {
|
||||
function loadBaseAddresses(string memory targetEnv) internal virtual {
|
||||
console.log('targetEnv:', targetEnv);
|
||||
|
||||
lensVersion = forkVersion;
|
||||
|
||||
hubProxyAddr = json.readAddress(string(abi.encodePacked('.', targetEnv, '.LensHubProxy')));
|
||||
vm.label(hubProxyAddr, 'LENS_HUB');
|
||||
console.log('hubProxyAddr:', hubProxyAddr);
|
||||
@@ -117,6 +119,7 @@ contract TestSetup is Test, ContractAddressesLoaderDeployer, ArrayHelpers {
|
||||
if (lensVersion == 2) {
|
||||
legacyCollectNFTAddr = hub.getLegacyCollectNFTImpl();
|
||||
} else {
|
||||
console.log('lensVersion is: %s. Trying to getCollectNFTImpl...', lensVersion);
|
||||
legacyCollectNFTAddr = IOldHub(address(hub)).getCollectNFTImpl();
|
||||
}
|
||||
|
||||
@@ -199,14 +202,11 @@ contract TestSetup is Test, ContractAddressesLoaderDeployer, ArrayHelpers {
|
||||
|
||||
loadOrDeploy_ModuleRegistryContract();
|
||||
|
||||
if (forkVersion == 1) {
|
||||
lensVersion = 1;
|
||||
if (lensVersion == 1) {
|
||||
vm.prank(governance);
|
||||
hub.whitelistProfileCreator(address(this), true);
|
||||
beforeUpgrade();
|
||||
upgradeToV2();
|
||||
} else {
|
||||
lensVersion = forkVersion;
|
||||
}
|
||||
|
||||
vm.startPrank(deployer);
|
||||
|
||||
Reference in New Issue
Block a user