From c4d0c44ed1051ea9a35001506cff64c9e297b291 Mon Sep 17 00:00:00 2001 From: poma Date: Tue, 15 Dec 2020 21:53:16 +0300 Subject: [PATCH] tidy --- .env.example | 2 -- README.md | 30 ------------------------------ package.json | 10 ---------- truffle.js | 23 ----------------------- yarn.lock | 5 ----- 5 files changed, 70 deletions(-) delete mode 100644 .env.example diff --git a/.env.example b/.env.example deleted file mode 100644 index 3ab2d8c..0000000 --- a/.env.example +++ /dev/null @@ -1,2 +0,0 @@ -PRIVATE_KEY= -INFURA_TOKEN=97c8bf358b9942a9853fab1ba93dc5b3 diff --git a/README.md b/README.md index f3a45a7..eaa181b 100644 --- a/README.md +++ b/README.md @@ -9,35 +9,5 @@ ```bash $ yarn -$ cp .env.example .env $ yarn test ``` - -## Deploying - -Deploy to Kovan: - -```bash -$ yarn deploy:kovan -``` - -## Mainnet deploy instructions - -1. in torn-token repo `cp .env.example .env` -2. Specify deployment `PRIVATE_KEY` in the `.env`. It will be the owner during deployment. -3. Specify gas price in `truffle.js` -4. `yarn deploy:mainnet` - -5. go to [mining](https://github.com/tornadocash/tornado-anonymity-mining) repo -6. `cp .env.example .env` -7. Specify private key and TORN address -8. yarn `yarn deploy:mainnet` - -9. go to [governance](https://github.com/tornadocash/governance) repo -10. ... -11. ... -12. ... - -13. in this repo modify the `config.js` file. Put all addresses that you got during deployment -14. set `ONLY_INITIALIZE` to `true` and `TORN_TO_INITIALIZE` to the token address -15. `yarn deploy:mainnet` diff --git a/package.json b/package.json index 13ca180..4c187af 100644 --- a/package.json +++ b/package.json @@ -18,15 +18,6 @@ "prettier:check": "prettier --check . --config .prettierrc", "prettier:fix": "prettier --write . --config .prettierrc", "lint": "yarn eslint && yarn prettier:check", - "deploy:mainnet": "truffle migrate --network mainnet", - "deploy:kovan": "truffle migrate --network kovan", - "deploy:dev": "truffle migrate --skip-dry-run --network test", - "init:mainnet": "truffle migrate -f 2 --to 2 --network mainnet", - "init:kovan": "truffle migrate -f 2 --to 2 --network kovan", - "init:test": "truffle migrate -f 2 --to 2 --network test", - "voucher:mainnet": "truffle migrate -f 3 --network mainnet", - "voucher:kovan": "truffle migrate -f 3 --network kovan", - "voucher:dev": "truffle migrate -f 3 --skip-dry-run --network test", "verify": "truffle run verify --network $NETWORK" }, "devDependencies": { @@ -48,7 +39,6 @@ }, "dependencies": { "@openzeppelin/contracts": "^3.1.0", - "dotenv": "^8.2.0", "eth-sig-util": "^2.5.3", "ethereumjs-util": "^7.0.3", "web3": "^1.2.11" diff --git a/truffle.js b/truffle.js index 1973ab5..f1f4cbf 100644 --- a/truffle.js +++ b/truffle.js @@ -1,8 +1,3 @@ -require('dotenv').config() -const HDWalletProvider = require('truffle-hdwallet-provider') -const utils = require('web3-utils') -const { PRIVATE_KEY, INFURA_TOKEN } = process.env - module.exports = { // Uncommenting the defaults below // provides for an easier quick-start with Ganache. @@ -21,24 +16,6 @@ module.exports = { // port: 8544, // network_id: '*', // }, - mainnet: { - provider: () => new HDWalletProvider(PRIVATE_KEY, `https://mainnet.infura.io/v3/${INFURA_TOKEN}`), - network_id: 1, - gas: 6000000, - gasPrice: utils.toWei('100', 'gwei'), - // confirmations: 0, - // timeoutBlocks: 200, - skipDryRun: true, - }, - kovan: { - provider: () => new HDWalletProvider(PRIVATE_KEY, `https://kovan.infura.io/v3/${INFURA_TOKEN}`), - network_id: 42, - gas: 6000000, - gasPrice: utils.toWei('1', 'gwei'), - // confirmations: 0, - // timeoutBlocks: 200, - skipDryRun: true, - }, coverage: { host: 'localhost', network_id: '*', diff --git a/yarn.lock b/yarn.lock index 9855187..0f60ac3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1452,11 +1452,6 @@ dom-walk@^0.1.0: resolved "https://registry.yarnpkg.com/dom-walk/-/dom-walk-0.1.2.tgz#0c548bef048f4d1f2a97249002236060daa3fd84" integrity sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w== -dotenv@^8.2.0: - version "8.2.0" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.2.0.tgz#97e619259ada750eea3e4ea3e26bceea5424b16a" - integrity sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw== - drbg.js@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/drbg.js/-/drbg.js-1.0.1.tgz#3e36b6c42b37043823cdbc332d58f31e2445480b"