-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: create updateAdapter script & update TransformationAdapter depl…
…oyment
- Loading branch information
1 parent
aaf3bbe
commit d758fd6
Showing
4 changed files
with
317 additions
and
22 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
270 changes: 270 additions & 0 deletions
270
deployments/goerli/solcInputs/4cdb95148abdf6f3fe75c6d0b6b1f691.json
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
const { getNamedAccounts, deployments } = require("hardhat"); | ||
const readlineSync = require("readline-sync"); | ||
|
||
async function main() { | ||
const adapterId = readlineSync.question("Adapter Id: "); | ||
const newAdapterAddress = readlineSync.question("New Adapter Address: "); | ||
const { deployer } = await getNamedAccounts(); | ||
const { execute } = deployments; | ||
console.log("Submitting tx..."); | ||
const receipt = await execute( | ||
"AdapterRegistry", | ||
{ from: deployer }, | ||
"setAdapterAddress", | ||
adapterId, | ||
newAdapterAddress | ||
); | ||
console.log("Executed in tx with hash", receipt.transactionHash); | ||
} | ||
|
||
main() | ||
.then(() => process.exit(0)) | ||
.catch((error) => { | ||
console.error(error); | ||
process.exit(1); | ||
}); |