Skip to content

StabilityNexus/Windmill-EVM-Contracts

Repository files navigation

Stability Nexus

 

Static Badge

Telegram Badge    X (formerly Twitter) Badge    Discord Badge    Medium Badge    LinkedIn Badge    Youtube Badge


TODO: Project Name

TODO is a ... TODO: Project Description.


🚀 Features

TODO: List your main features here:

  • Feature 1: Description
  • Feature 2: Description
  • Feature 3: Description
  • Feature 4: Description

Project Maturity

TODO: In the checklist below, mark the items that have been completed and delete items that are not applicable to the current project:

  • The protocol:
    • has been described and formally specified in a paper.
    • has had its main properties mathematically proven.
    • has been formally verified.
  • The smart contracts:
    • were thoroughly reviewed by at least two knights of The Stable Order.
    • were deployed to:
      • Ethereum Classic
      • Ethereum
      • Polygon
      • BSC
      • Base

Architecture

TODO: Replace with your actual contract architecture. Example below.

src/
├── TODO_Contract.sol       # Core logic contract
├── interfaces/
│   └── ITODO_Contract.sol  # Interface definitions
└── libraries/
    └── TODO_Library.sol    # Shared utility library

script/
├── Deploy.s.sol            # Deployment script
└── Interactions.s.sol      # Post-deploy interaction scripts

test/
├── unit/
│   └── TODO_ContractTest.t.sol
└── integration/
    └── TODO_IntegrationTest.t.sol

Contract Diagram (TODO: add a diagram or ASCII art showing contract relationships) You can create Web3 architecture diagrams using:

Example structure to include:

  • Frontend (DApp UI built with React/Next.js)
  • Wallet integration (MetaMask, WalletConnect, Coinbase Wallet)
  • Web3 provider / RPC (Infura, Alchemy, QuickNode)
  • Smart contracts (Solidity contracts deployed on blockchain)
  • Blockchain network (Ethereum, Polygon, Arbitrum, etc.)
  • Decentralized storage (IPFS, Filecoin, Arweave)
  • Indexing services (The Graph or similar)
  • Optional backend services (Node.js APIs, relayers, indexing)
  • Data flow between the frontend, wallet, smart contracts, and blockchain

Tech Stack

Layer Technology
Smart Contracts Solidity ^0.8.x
Framework Foundry (forge, cast, anvil)
Libraries OpenZeppelin (via lib/)

Repository Structure

.
├── .github/
│   └── workflows/           # CI, security, gas, fuzz, release pipelines
├── lib/                     # Foundry dependencies (git submodules)
├── public/                  # Logos and static assets
├── script/                  # Forge deployment & interaction scripts
├── src/                     # Solidity source contracts
├── test/                    # Forge test suite
├── .coderabbit.yaml         # CodeRabbit AI review config
├── .env.example             # Environment variable template
├── .gitmodules              # Submodule declarations
├── foundry.toml             # Foundry project config (RPCs, verifiers)
├── foundry.lock             # Locked dependency versions
└── README.md

🔗 Repository Links

TODO: Update with your repository structure

  1. Main Repository
  2. Frontend (if separate)
  3. contract (if separate)

Getting Started

Prerequisites

Tool Version Install
git any git-scm.com
foundryup latest See getfoundry.sh
forge / cast / anvil latest run foundryup after install

Verify installation:

forge --version   # e.g. forge 0.3.x
anvil --version
cast --version

Installation

# 1. Clone with submodules
git clone --recurse-submodules https://github.com/StabilityNexus/Template-Repo-EVM-Contracts.git
cd Template-Repo-EVM-Contracts

# 2. If you forgot --recurse-submodules
git submodule update --init --recursive

# 3. Install/update Foundry dependencies
forge install

Environment Setup

cp .env.example .env

Edit .env and fill in:

# Required for deployment
PRIVATE_KEY=0x...

# Required for contract verification
ETHERSCAN_API_KEY=...

# Optional: override default public RPCs
RPC_ETHEREUM=https://mainnet.infura.io/v3/YOUR_KEY
RPC_SEPOLIA=https://sepolia.infura.io/v3/YOUR_KEY

Usage

Build

forge build

Test

# Run all tests
forge test

# Verbose output (shows logs and traces)
forge test -vvv

# Run a specific test file
forge test --match-path test/unit/TODO_ContractTest.t.sol

# Run a specific test function
forge test --match-test testTransfer -vvv

Coverage

forge coverage

# Generate LCOV report
forge coverage --report lcov
genhtml lcov.info --output-directory coverage/

Gas Snapshot

# Generate snapshot
forge snapshot

# Compare against last snapshot
forge snapshot --diff

Format & Lint

forge fmt          # Format Solidity files
forge fmt --check  # Check without writing (used in CI)

Deployment

Make sure your .env is configured before deploying.

Testnet

# Deploy to Sepolia (Ethereum testnet)
forge script script/Deploy.s.sol \
  --rpc-url sepolia \
  --broadcast \
  --verify \
  -vvvv

# Deploy to Mordor (Ethereum Classic testnet)
forge script script/Deploy.s.sol \
  --rpc-url mordor \
  --broadcast \
  -vvvv

Mainnet

# Deploy to Ethereum mainnet
forge script script/Deploy.s.sol \
  --rpc-url ethereum \
  --broadcast \
  --verify \
  -vvvv

# Deploy to Base
forge script script/Deploy.s.sol \
  --rpc-url base \
  --broadcast \
  --verify \
  -vvvv

ℹ️ RPC aliases (sepolia, ethereum, base, etc.) are pre-configured in foundry.toml.


Supported Networks

Pre-configured RPC endpoints in foundry.toml.

| Network | Type | Chain ID | |---|---|---|---| | Ethereum | Mainnet | 1 | | Ethereum Classic | Mainnet | 61 | | Polygon PoS | Mainnet | 137 | | BNB Smart Chain | Mainnet | 56 | | Base | Mainnet | 8453 | | Sepolia | Testnet | 11155111 | | Mordor (ETC) | Testnet | 63 |


CI/CD Workflows

Workflow Trigger What it does
ci.yml Push / PR Format check → Build → Unit tests → Coverage report
security-slither.yml Push / PR Slither static analysis for vulnerabilities
gas-snapshot.yml Push / PR Gas baseline and regression checks
nightly-fuzz.yml Nightly (cron) Deep fuzz & invariant testing
release.yml Tag push Builds and publishes release artifacts

Security

  • Static analysis is run on every PR via Slither (see .github/workflows/security-slither.yml)
  • CodeRabbit AI review is enabled via .coderabbit.yaml
  • Deep fuzz runs nightly to catch edge cases

Found a vulnerability? Please do not open a public issue. Contact the Stability Nexus team privately via Discord or Telegram.


🙌 Contributing

⭐ Don't forget to star this repository if you find it useful! ⭐

Thank you for considering contributing to this project! Contributions are highly appreciated and welcomed. To ensure smooth collaboration, please refer to our Contribution Guidelines.


✨ Maintainers

TODO: Add maintainer information


📍 License

See the LICENSE file for details.


💪 Thanks To All Contributors

Thanks a lot for spending your time helping TODO grow. Keep rocking!

Contributors

© 2025 Stability Nexus

About

Auction-Based Order-Book Exchange

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors