# AGENTS.md

Go implementation of the Ethereum protocol

## Setup

```
go mod download
```

## Commands

```
make geth
make evm
make test    # run the test suite, must pass before any commit
make lint    # lint
make fmt
make clean
```

## Layout

- `core/`     311 source files
- `crypto/`   204 source files
- `eth/`      173 source files
- `cmd/`      118 source files
- `p2p/`      94 source files
- `accounts/` 88 source files

## Conventions

- Tests live alongside the code they cover, following `accounts/abi/abi_test.go`.
- CI defines what passing means. See `.github/workflows/freebsd.yml`, and keep it green.
- TODO: add the two or three conventions a newcomer always gets wrong here.

## Gotchas

- Generated output is committed (`build/`). Search will return the compiled copy, so edit the source, not that.
- `crypto/secp256k1/libsecp256k1/src/precomputed_ecmult.c` is 2353KB. It will not fit comfortably in context, so read it in parts.

---

Drafted by agentreadme.com from what is in this repository. Everything marked TODO
needs a human. Check it in as AGENTS.md at the root.
