This repository has been archived by the owner on Jan 9, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deposit quote token WIP. Add brownie scripts + README
- Loading branch information
Showing
7 changed files
with
136 additions
and
71 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 |
---|---|---|
|
@@ -5,5 +5,4 @@ node_modules | |
.env | ||
.env.prod | ||
.vscode/*.log | ||
scripts/ | ||
brownie* | ||
__pycache__/ |
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,23 @@ | ||
project_structure: | ||
build: out | ||
contracts: src | ||
tests: src/tests | ||
|
||
# use Ganache's forked mainnet mode as the default network | ||
# NOTE: You don't *have* to do this, but it is often helpful for testing | ||
networks: | ||
default: mainnet-fork | ||
|
||
# automatically fetch contract sources from Etherscan | ||
autofetch_sources: True | ||
|
||
# path remapping to support imports from GitHub/NPM | ||
compiler: | ||
solc: | ||
version: 0.8.10 | ||
remappings: | ||
- "@ds-test=lib/ds-test/src/" | ||
- "@ds-math=lib/ds-math/src/" | ||
- "@openzeppelin/contracts=lib/openzeppelin-contracts/contracts" | ||
- "@std=lib/forge-std/src/" | ||
|
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,3 @@ | ||
from dotenv import load_dotenv | ||
|
||
load_dotenv() |
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,16 @@ | ||
from brownie import * | ||
import itertools | ||
|
||
def main(): | ||
deployer = accounts[0]; | ||
alice = accounts[1]; | ||
bob = accounts[2]; | ||
uniswap =Contract("0x2a1530C4C41db0B0b2bB646CB5Eb1A67b7158667"); | ||
uniswap.ethToTokenSwapInput(1, 9999999999, {"from": alice, "value": "100 ether"}); | ||
uniswap.ethToTokenSwapInput(1, 9999999999, {"from": bob, "value": "55 ether"}); | ||
dai = Contract('0x6b175474e89094c44da98b954eedeac495271d0f'); | ||
mkr = Contract('0x9f8F72aA9304c8B593d555F12eF6589cC3A579A2') | ||
daiPool = ERC20PerpPool.deploy(dai, mkr, {"from" : deployer}); | ||
dai.approve(daiPool, 111111111111, {"from" : alice}); | ||
dai.approve(daiPool, 111111111111, {"from" : bob}); | ||
return deployer, alice, bob, dai, mkr, daiPool; |
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