https://github.com/descent-collective/oracle-module
The price oracle module for Descent protocol
https://github.com/descent-collective/oracle-module
Last synced: 2 months ago
JSON representation
The price oracle module for Descent protocol
- Host: GitHub
- URL: https://github.com/descent-collective/oracle-module
- Owner: Descent-Collective
- Created: 2023-09-14T14:56:36.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-16T22:17:50.000Z (over 1 year ago)
- Last Synced: 2025-01-24T01:46:42.556Z (4 months ago)
- Language: Solidity
- Homepage:
- Size: 193 KB
- Stars: 2
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Oracle Module
- Get [Foundry](https://book.getfoundry.sh/)
## To test
```shell
$ forge test -vvv --gas-report
```## To deploy locally to anvil
Run
```shell
$ anvil
```Note: Be sure to set `PRIVATE_KEY` variable in .env to be one of the anvil local private keys with eth balance
Then
```shell
$ source .env
$ forge script script/median.s.sol:MedianScript --fork-url http://localhost:8545 --broadcast -vvvv
```## To deploy to a public network
```shell
$ source .env
$ forge script script/median.s.sol:MedianScript --rpc-url $GOERLI_RPC_URL --broadcast --verify -vvvv
```Note: Can remove `--broadcast and `--verify` to simulate the deployment script locally without actually broadcasting it to the network
## Foundry Usage
### Build
```shell
$ forge build
```### Test
```shell
$ forge test -vvv --gas-report
```### Format
```shell
$ forge fmt
```### Gas Snapshots
```shell
$ forge snapshot
```### Anvil
```shell
$ anvil
```### Cast
```shell
$ cast
```### Help
```shell
$ forge --help
$ anvil --help
$ cast --help
```