Selaa lähdekoodia

build: Add deploy scripts

SauravKanchan 4 vuotta sitten
vanhempi
commit
8baee47c71
2 muutettua tiedostoa jossa 17 lisäystä ja 1 poistoa
  1. 14 0
      README.md
  2. 3 1
      package.json

+ 14 - 0
README.md

@@ -87,6 +87,20 @@ Delete the smart contract artifacts, the coverage reports and the Hardhat cache:
 $ yarn clean
 ```
 
+### Deploy 
+
+Deploy the contracts to hardhat test network.
+
+```sh
+$ yarn deploy 
+```
+
+Deploy the contracts to a specific network.
+
+```sh
+$ yarn deploy:network ropsten 
+```
+
 ## Syntax Highlighting
 
 If you use VSCode, you can enjoy syntax highlighting for your Solidity code via the

+ 3 - 1
package.json

@@ -71,6 +71,8 @@
     "prettier": "prettier --config .prettierrc --write \"**/*.{js,json,md,sol,ts}\"",
     "prettier:list-different": "prettier --config .prettierrc --list-different \"**/*.{js,json,md,sol,ts}\"",
     "test": "hardhat test",
-    "typechain": "hardhat typechain"
+    "typechain": "hardhat typechain",
+    "deploy": "hardhat run scripts/deploy.ts",
+    "deploy:network": "hardhat run scripts/deploy.ts --network"
   }
 }