DAO smart contracts — ERC-20 token, governance, and timelock (OpenZeppelin + Hardhat)
  • JavaScript 100%
Find a file
Anderson e44c2dceaa
All checks were successful
CI / Compile & Test Contracts (push) Successful in 41s
ci: trigger initial CI run
2026-05-17 04:22:35 +00:00
.gitea/workflows ci: add Forgejo Actions workflow 2026-05-17 04:20:02 +00:00
contracts Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
scripts Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
.ci-trigger ci: trigger initial CI run 2026-05-17 04:22:35 +00:00
.env.example Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
.gitignore Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
hardhat.config.cjs Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
package.json Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00
README.md Initial commit: AeThex DAO contracts 2026-02-14 21:57:08 +00:00

AeThex Foundation Smart Contracts

Governance contracts for the AeThex ecosystem built on OpenZeppelin.

Contracts

Contract Description
AethexToken.sol ERC-20 governance token with voting capabilities
AethexGovernor.sol On-chain governance (proposals, voting)
AethexTimelock.sol Time-locked execution of governance decisions

Setup

npm install

Development

# Start local node
npm run node

# Compile contracts
npm run compile

# Run tests
npm run test

# Deploy to local network
npm run deploy:local

Deployment

# Deploy to Sepolia testnet
npm run deploy:sepolia

# Deploy to mainnet (use with caution)
npm run deploy:mainnet

# Verify on Etherscan
npx hardhat verify --network sepolia <CONTRACT_ADDRESS>

Environment Variables

Copy .env.example to .env and fill in:

ALCHEMY_API_KEY=         # Alchemy API key for RPC
POLYGON_PRIVATE_KEY=     # Deployer wallet private key
ETHERSCAN_API_KEY=       # For contract verification
POLYGONSCAN_API_KEY=     # For Polygon verification

Architecture

                    ┌──────────────────┐
                    │  AethexToken     │
                    │  (ERC-20 + Vote) │
                    └────────┬─────────┘
                             │
                    ┌────────▼─────────┐
                    │  AethexGovernor  │
                    │  (Proposals)     │
                    └────────┬─────────┘
                             │
                    ┌────────▼─────────┐
                    │  AethexTimelock  │
                    │  (Execution)     │
                    └──────────────────┘

License

MIT