olympus-dao
所属分类:NFT
开发工具:Solidity
文件大小:360KB
下载次数:0
上传日期:2022-02-09 07:14:59
上 传 者:
sh-1993
说明: 奥林巴斯岛,,
(olympus-dao,,)
文件列表:
.env.example (200, 2022-02-09)
.eslintignore (38, 2022-02-09)
.eslintrc.js (352, 2022-02-09)
.npmignore (31, 2022-02-09)
.prettierignore (62, 2022-02-09)
.prettierrc (0, 2022-02-09)
.solhint.json (166, 2022-02-09)
.solhintignore (13, 2022-02-09)
assets (0, 2022-02-09)
assets\img (0, 2022-02-09)
assets\img\dao.png (35290, 2022-02-09)
contracts (0, 2022-02-09)
contracts\BondDepository.sol (22524, 2022-02-09)
contracts\OlympusAuthority.sol (3011, 2022-02-09)
contracts\OlympusERC20.sol (1268, 2022-02-09)
contracts\Staking.sol (9055, 2022-02-09)
contracts\StakingDistributor.sol (6721, 2022-02-09)
contracts\Treasury.sol (17305, 2022-02-09)
contracts\allocators (0, 2022-02-09)
contracts\allocators\LUSDAllocator.sol (13623, 2022-02-09)
contracts\allocators\interfaces (0, 2022-02-09)
contracts\allocators\interfaces\ISwapRouter.sol (2601, 2022-02-09)
contracts\allocators\interfaces\IWETH.sol (212, 2022-02-09)
contracts\allocators\interfaces\LiquityInterfaces.sol (7421, 2022-02-09)
contracts\cryptography (0, 2022-02-09)
contracts\cryptography\ECDSA.sol (8750, 2022-02-09)
contracts\cryptography\EIP712.sol (4568, 2022-02-09)
contracts\interfaces (0, 2022-02-09)
contracts\interfaces\IBondDepository.sol (3085, 2022-02-09)
contracts\interfaces\IBondingCalculator.sol (258, 2022-02-09)
contracts\interfaces\IDistributor.sol (717, 2022-02-09)
contracts\interfaces\IERC20.sol (2508, 2022-02-09)
contracts\interfaces\IERC20Metadata.sol (303, 2022-02-09)
contracts\interfaces\IERC20Permit.sol (2173, 2022-02-09)
contracts\interfaces\IGovernable.sol (291, 2022-02-09)
contracts\interfaces\IGuardable.sol (290, 2022-02-09)
contracts\interfaces\INoteKeeper.sol (935, 2022-02-09)
... ...
# Olympus DAO Contracts
## Deployed Contracts to Rinkeby testnet :-
```shell
Authority - https://rinkeby.etherscan.io/address/0xd2Fc5EeBD6a763Ac45Cb9583B74ef38A148F5bdc
Bond Depository - https://rinkeby.etherscan.io/address/0x681B1165A5cF8D56279D27Ae6507c849c8ffD834
Staking - https://rinkeby.etherscan.io/address/0x591d0F89feD8fdFcDcfEB54593D1F6eEa6327D81
Treasury - https://rinkeby.etherscan.io/address/0x009B05da752BFd9423227228a9066858A06D12f7
LUSD Allocator - https://rinkeby.etherscan.io/address/0x51357831F75C36282417d3d0Ef2C174ca8B33ad0
```
# Contract Workflow
![This is an image](https://github.com/assets/img/dao.png)
Includes mainly Bond, Treasury and Allocator Contracts.
Provides discounted Ohm in exchange of token reserves(e.g: DAI token) from User.
```shell
* Bond Contract: consists of mainly create and deposit functions.
1. create() function, for creating markets for tokens of a specified interval and yield price.
function create();
2. deposit() function, accepts tokens deposit from a user.
* user data is stored as notes (storing tokens value, time created and when payment is redeemable)
function deposit();
```
```shell
* Treasury Contract: Treasury manages reserves, minting new ohm (using excess reserves) and burning ohm.
1. deposit() function, allows approved address to deposit asset(tokens) for ohm
function deposit();
2. withdraw() function, allows approved address to burn ohm for reserves
function withdraw();
3. manage() function, allows approved address to withdraw assets
function withdraw();
```
```shell
* Allocator Contract: Allocating assets to pools to earn yields
1. deposit() function, withdraws assets from treasury and deposit asset to stability pool.
2. withdraw() function, Withdraws from stability pool and deposits assets into treasury.
```
```shell
npx hardhat accounts
npx hardhat compile
npx hardhat clean
npx hardhat test
npx hardhat node
npx hardhat help
REPORT_GAS=true npx hardhat test
npx hardhat coverage
npx hardhat run scripts/deploy.js
node scripts/deploy.js
npx eslint '**/*.js'
npx eslint '**/*.js' --fix
npx prettier '**/*.{json,sol,md}' --check
npx prettier '**/*.{json,sol,md}' --write
npx solhint 'contracts/**/*.sol'
npx solhint 'contracts/**/*.sol' --fix
```
近期下载者:
相关文件:
收藏者: