Skip to content

Commit

Permalink
docs: add README.md file (#14)
Browse files Browse the repository at this point in the history
Co-authored-by: mrekucci <[email protected]>
  • Loading branch information
mrekucci and mrekucci authored Apr 11, 2024
1 parent af0a038 commit 65f84fb
Showing 1 changed file with 68 additions and 0 deletions.
68 changes: 68 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# mev-commit

Is P2P software that creates a network of execution providers and bidders.
Bidders can broadcast bids to providers and receive commitments from them.
A high throughput POA EVM chain settles the bids at the end of a block slot.

## Main Components
- [mev-commit client](p2p)
- [mev-commit-oracle](oracle)
- [mev-commit-bridge](bridge)
- [mev-commit-geth](external/geth)
- [contracts](contracts)

## Getting Started

The mev-commit repository is a mono-repository that also use submodules for external dependencies.
To clone the repository and its submodules, run the following command:

```shell
git clone --recurse-submodules <[email protected]:primevprotocol/mev-commit.git|https://github.com/primevprotocol/monorepo.git>
```

If you have already cloned the repository and need to update the submodules, run the following command:

```shell
git submodule update --init --recursive
```

## Development

When working with submodules, you can use the `git submodule` command to list available submodules.
To make changes to a submodule, navigate to the submodule directory using the `cd` command.
Before making any changes, ensure that the submodule is up-to-date.
For example, to navigate to the `external/geth` submodule, run the following command:

```shell
cd external/geth
git submodule update --init --recursive
```

Make the necessary changes to the submodule and commit (and push) them.
To make the changes available in the main repository, you need to push the changes to the submodule.
After making changes to the submodule, navigate back to the main repository and commit the changes.
For example, to commit and push changes made to the `external/geth` submodule, run the following commands inside the submodule directory:

```shell
git add -p
git commit -m "<your-commit-message>"
git push
```
Go back to the main repository and commit (and push) the changes made to the submodule:

```shell
git add external/geth
git commit -m "<your-commit-message>"
git push
```

### Go Modules

Since this repository uses [Go Workspaces](https://go.dev/ref/mod#workspaces) to manage Go modules, when making changes to a Go module and its dependencies, ensure that the changes are reflected everywhere by running the following command:

```shell
go list -f '{{.Dir}}' -m | xargs -L1 go mod tidy -C
go work sync
```

> See the [go.work](go.work) file for all the Go modules used in this repository.

0 comments on commit 65f84fb

Please sign in to comment.