Skip to content

Commit

Permalink
chore: remove deployments, and hardcode compilation params
Browse files Browse the repository at this point in the history
  • Loading branch information
MathisGD committed Jan 8, 2025
1 parent a005126 commit f434237
Show file tree
Hide file tree
Showing 9 changed files with 4 additions and 107 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ jobs:
uses: foundry-rs/foundry-toolchain@v1

- name: Run Linter
run: yarn lint
run: forge fmt --check
25 changes: 1 addition & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,30 +107,7 @@ cp .env.example .env
Running tests requires forge from [Foundry](https://book.getfoundry.sh/getting-started/installation).

```bash
yarn test
```

### Deployment

- Add the desired network key and its corresponding RPC url to `foundry.toml`
- `yarn deploy {network} --broadcast --sender {sender}` followed with appropriate private key management parameters

> [!NOTE]
> If the provided network's RPC url uses a variable environment (such as `ALCHEMY_KEY`), it should be defined in your `.env`
For example:

```bash
yarn deploy goerli --broadcast --ledger --sender 0x7Ef4174aFdF4514F556439fa2822212278151Db6
```

> [!NOTE]
> Broadcast run logs are to be committed to this repository for future reference.
### Etherscan verification

```bash
yarn verify --watch --chain-id {chainid} --etherscan-api-key {key} {address} src/UrdFactory.sol:UrdFactory
forge t
```

## Audits
Expand Down
8 changes: 2 additions & 6 deletions foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ fs_permissions = [
{ access = "read", path = "./script/config/"},
{ access = "read", path = "./out/"}
]
optimizer_runs = 200
via-ir = true

[profile.default.fmt]
wrap_comments = true
Expand All @@ -17,12 +19,6 @@ goerli = "https://eth-goerli.g.alchemy.com/v2/${ALCHEMY_KEY}"
sepolia = "https://eth-sepolia.g.alchemy.com/v2/${ALCHEMY_KEY}"


[profile.build]
via-ir = true
test = "/dev/null"
script = "/dev/null"


[profile.script]
src = "/dev/null"
test = "/dev/null"
Expand Down
11 changes: 0 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,6 @@
"bugs": {
"url": "https://github.com/morpho-org/universal-rewards-distributor/issues"
},
"scripts": {
"prepare": "husky install && forge install",
"script": "FOUNDRY_PROFILE=script forge script",
"build": "FOUNDRY_PROFILE=build forge build",
"deploy": "yarn build && yarn script script/DeployUrdFactory.sol --sig \"run(string memory)\"",
"verify": "FOUNDRY_PROFILE=build forge verify-contract",
"test": "FOUNDRY_PROFILE=test forge test",
"lint": "forge fmt --check",
"lint:fix": "forge fmt",
"clean": "forge clean"
},
"devDependencies": {
"@commitlint/cli": "^18.2.0",
"@commitlint/config-conventional": "^18.1.0",
Expand Down
38 changes: 0 additions & 38 deletions script/ConfiguredScript.sol

This file was deleted.

18 changes: 0 additions & 18 deletions script/DeployUrdFactory.sol

This file was deleted.

3 changes: 0 additions & 3 deletions script/config/ethereum.json

This file was deleted.

3 changes: 0 additions & 3 deletions script/config/goerli.json

This file was deleted.

3 changes: 0 additions & 3 deletions script/config/sepolia.json

This file was deleted.

0 comments on commit f434237

Please sign in to comment.