-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: migration for truffle to hardhat
Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>
- Loading branch information
1 parent
c6e98b5
commit 21a7bd8
Showing
13 changed files
with
416 additions
and
514 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,4 +1,7 @@ | ||
node_modules | ||
.DS_Store | ||
build | ||
artifacts | ||
artifacts | ||
cache | ||
.env | ||
sst-config.json |
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,166 @@ | ||
{ | ||
"manifestVersion": "3.2", | ||
"proxies": [ | ||
{ | ||
"address": "0x59c5d68d6B45dd4bcaC643e8dc73c1f29FC0183d", | ||
"txHash": "0x153de4adc51caceeabfc6d0a6a4b19159470d189421eefce990a512e785d70ee", | ||
"kind": "transparent" | ||
} | ||
], | ||
"impls": { | ||
"dadc513cd81ce3e765b05219a9f956799b5405d497cd25e1342ce5b4b08463df": { | ||
"address": "0x5DF0b04279bbA8082253466b1373243C6c82bb1f", | ||
"txHash": "0x4afb91141018066c147d75ab814c8d676450b077fb403276ab8643c385634e39", | ||
"layout": { | ||
"solcVersion": "0.8.16", | ||
"storage": [ | ||
{ | ||
"label": "totalDIDs", | ||
"offset": 0, | ||
"slot": "0", | ||
"type": "t_uint256", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:9" | ||
}, | ||
{ | ||
"label": "owner", | ||
"offset": 0, | ||
"slot": "1", | ||
"type": "t_address", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:10" | ||
}, | ||
{ | ||
"label": "polyDIDs", | ||
"offset": 0, | ||
"slot": "2", | ||
"type": "t_mapping(t_address,t_struct(PolyDID)48_storage)", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:25" | ||
}, | ||
{ | ||
"label": "activeDIDs", | ||
"offset": 0, | ||
"slot": "3", | ||
"type": "t_mapping(t_uint256,t_address)", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:26" | ||
}, | ||
{ | ||
"label": "activeAddress", | ||
"offset": 0, | ||
"slot": "4", | ||
"type": "t_mapping(t_address,t_uint256)", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:27" | ||
}, | ||
{ | ||
"label": "resourceData", | ||
"offset": 0, | ||
"slot": "5", | ||
"type": "t_mapping(t_address,t_mapping(t_string_memory_ptr,t_string_storage))", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:28" | ||
}, | ||
{ | ||
"label": "keysById", | ||
"offset": 0, | ||
"slot": "6", | ||
"type": "t_mapping(t_address,t_array(t_string_storage)dyn_storage)", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:29" | ||
}, | ||
{ | ||
"label": "initialized", | ||
"offset": 0, | ||
"slot": "7", | ||
"type": "t_bool", | ||
"contract": "PolygonDidRegistry", | ||
"src": "contracts/PolygonDidRegistry.sol:35" | ||
} | ||
], | ||
"types": { | ||
"t_address": { | ||
"label": "address", | ||
"numberOfBytes": "20" | ||
}, | ||
"t_array(t_string_storage)dyn_storage": { | ||
"label": "string[]", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_bool": { | ||
"label": "bool", | ||
"numberOfBytes": "1" | ||
}, | ||
"t_mapping(t_address,t_array(t_string_storage)dyn_storage)": { | ||
"label": "mapping(address => string[])", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_mapping(t_address,t_mapping(t_string_memory_ptr,t_string_storage))": { | ||
"label": "mapping(address => mapping(string => string))", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_mapping(t_address,t_struct(PolyDID)48_storage)": { | ||
"label": "mapping(address => struct PolygonDidRegistry.PolyDID)", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_mapping(t_address,t_uint256)": { | ||
"label": "mapping(address => uint256)", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_mapping(t_string_memory_ptr,t_string_storage)": { | ||
"label": "mapping(string => string)", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_mapping(t_uint256,t_address)": { | ||
"label": "mapping(uint256 => address)", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_string_memory_ptr": { | ||
"label": "string", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_string_storage": { | ||
"label": "string", | ||
"numberOfBytes": "32" | ||
}, | ||
"t_struct(PolyDID)48_storage": { | ||
"label": "struct PolygonDidRegistry.PolyDID", | ||
"members": [ | ||
{ | ||
"label": "controller", | ||
"type": "t_address", | ||
"offset": 0, | ||
"slot": "0" | ||
}, | ||
{ | ||
"label": "created", | ||
"type": "t_uint256", | ||
"offset": 0, | ||
"slot": "1" | ||
}, | ||
{ | ||
"label": "updated", | ||
"type": "t_uint256", | ||
"offset": 0, | ||
"slot": "2" | ||
}, | ||
{ | ||
"label": "didDoc", | ||
"type": "t_string_storage", | ||
"offset": 0, | ||
"slot": "3" | ||
} | ||
], | ||
"numberOfBytes": "128" | ||
}, | ||
"t_uint256": { | ||
"label": "uint256", | ||
"numberOfBytes": "32" | ||
} | ||
}, | ||
"namespaces": {} | ||
} | ||
} | ||
} | ||
} |
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 |
---|---|---|
|
@@ -2,4 +2,5 @@ pnpm-lock.yaml | |
node_modules | ||
.DS_Store | ||
build | ||
artifacts | ||
artifacts | ||
sst-config.json |
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,39 @@ | ||
/** | ||
* @type import('hardhat/config').HardhatUserConfig | ||
*/ | ||
|
||
// import 'hardhat'; | ||
require('@nomicfoundation/hardhat-ethers') | ||
require('@openzeppelin/hardhat-upgrades') | ||
require('@nomicfoundation/hardhat-verify') | ||
|
||
require('dotenv/config') | ||
|
||
module.exports = { | ||
solidity: { | ||
version: '0.8.16', | ||
settings: { | ||
optimizer: { | ||
enabled: true, | ||
runs: 200, | ||
}, | ||
}, | ||
}, | ||
networks: { | ||
hardhat: {}, | ||
mumbai: { | ||
url: process.env.RPCURL_POLYGON_MUMBAI, | ||
accounts: [`0x${process.env.SIGNER}`], | ||
}, | ||
//Use for mainnet deployment | ||
// polygon: { | ||
// url: process.env.RPCURL_POLYON_MAINNET, | ||
// accounts: [`0x${process.env.SIGNER}`], | ||
// }, | ||
}, | ||
etherscan: { | ||
apiKey: { | ||
polygonMumbai: process.env.VERIFICATION_KEY, | ||
}, | ||
}, | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.