A set of periphery smart contracts for the Intuition protocol, built using Foundry.
- Forge: compile, test, fuzz, format, and deploy smart contracts
- [Bun]: Foundry defaults to git submodules, but this template also uses Node.js packages for managing dependencies
- Forge Std: collection of helpful contracts and utilities for testing
- Prettier: code formatter for non-Solidity files
- Solhint: linter for Solidity code
This is a list of the most frequently needed commands.
Build the contracts:
$ forge buildDelete the build artifacts and cache directories:
$ forge cleanDeploy to Anvil:
$ forge script script/Deploy.s.sol --broadcast --fork-url http://localhost:8545For this script to work, you need to have a MNEMONIC environment variable set to a valid
BIP39 mnemonic.
For instructions on how to deploy to a testnet or mainnet, check out the Solidity Scripting tutorial.
Format the contracts:
$ forge fmtGet a gas report:
$ forge test --gas-reportLint the contracts:
$ bun run lintRun the tests:
$ forge testGenerate test coverage and output result to the terminal:
$ bun run test:coverageGenerate test coverage with lcov report (you'll have to open the ./coverage/index.html file in your browser, to do so
simply copy paste the path):
$ bun run test:coverage:reportNote
This command requires you to have lcov installed on your machine. On
macOS, you can install it with Homebrew: brew install lcov.
This repo includes team-shared Claude slash commands in .claude/commands.
Use /help in Claude Code to see them, then run:
/audit-solidity [codebase-path] [spec-document-optional]/audit-context [codebase-path] [--focus <module>]/audit-entry-points [directory-path]/audit-static-analysis [codebase-path]/audit-spec-compliance <spec-document> [codebase-path]/audit-variants [vulnerability-description]
Generated reports are written to audits/automated-reports/.
This project is licensed under BUSL-1.1
| Contract Name | Address | ProxyAdmin |
|---|---|---|
| EmissionsAutomationAdapter | 0xb1ce9Ac324B5C3928736Ec33b5Fd741cb04a2F2d | / |
| TrustSwapAndBridgeRouter | 0xA1EC6f95A88Bfc7A8Fd35f1296b64ebaf91C93fb | / |
| Contract Name | Address | ProxyAdmin |
|---|---|---|
| Multicall3 | 0xcA11bde05977b3631167028862bE2a173976CA11 | / |
| EntryPoint | 0x4337084D9E255Ff0702461CF8895CE9E3b5Ff108 | / |
| SafeSingletonFactory | 0x914d7Fec6aaC8cd542e72Bca78B30650d45643d7 | / |
| Contract Name | Address | ProxyAdmin |
|---|---|---|
| TestTrust | 0xA54b4E6e356b963Ee00d1C947f478d9194a1a210 | / |
| Contract Name | Address | ProxyAdmin |
|---|---|---|
| Multicall3 | 0xcA11bde05977b3631167028862bE2a173976CA11 | / |
| EntryPoint | 0x4337084D9E255Ff0702461CF8895CE9E3b5Ff108 | / |