@ -47,27 +39,27 @@ For macOS, you can reference this [guide](http://tldrdevnotes.com/bash-upgrade-3
## Dev Environment
**Most repos from [harmony-one](https://github.com/harmony-one) assumes the GOPATH convention. More information [here](https://github.com/golang/go/wiki/GOPATH).**
**Most repos from [woop-chain](https://github.com/woop-chain) assumes the GOPATH convention. More information [here](https://github.com/golang/go/wiki/GOPATH).**
### First Install
Clone and set up all of the repos with the following set of commands:
Included in this repo is a Dockerfile that has a full harmony development environment and
Included in this repo is a Dockerfile that has a full woop development environment and
comes with emacs, vim, ag, tig and other creature comforts. Most importantly, it already has the go environment
with our C/C++ based library dependencies (`libbls` and `mcl`) set up correctly for you.
You can build the docker image for yourself with the following commands:
```bash
cd $(go env GOPATH)/src/github.com/harmony-one/harmony
cd $(go env GOPATH)/src/github.com/woop-chain/woop
make clean
docker build -t harmony .
docker build -t woop .
```
> If your build machine has an ARM-based chip, like Apple silicon (M1), the image is built for `linux/arm64` by default. To build for `x86_64`, apply the `--platform` arg like so:
> Learn more about the `--platform` arg and multi-CPU architecture support, [here](https://docs.docker.com/engine/reference/builder/#automatic-platform-args-in-the-global-scope) and [here](https://docs.docker.com/desktop/multi-arch/).
@ -97,26 +89,26 @@ docker build -t harmony .
Then you can start your docker container with the following command:
> Note that the harmony repo will be shared between your docker container and your host machine. However, everything else in the docker container will be ephemeral.
> Note that the woop repo will be shared between your docker container and your host machine. However, everything else in the docker container will be ephemeral.
If you need to open another shell, just do:
```bash
docker exec -it harmony /bin/bash
docker exec -it woop /bin/bash
```
Learn more about docker [here](https://docker-curriculum.com/).
## Build
The `make` command should automatically build the Harmony binary & all dependent libs.
The `make` command should automatically build the Woop binary & all dependent libs.
However, if you wish to bypass the Makefile, first export the build flags:
@ -159,7 +151,7 @@ Note that all test Docker containers bind several ports to the host machine for
* `9798` - Shard 1 Rosetta (for an explorer)
* `9899` - Shard 0 WS for an explorer
* `9898` - Shard 1 WS for an explorer
> This allows you to use curl, hmy CLI, postman, rosetta-cli, etc... on your host machine to play with or probe the localnet that was used for the test.
> This allows you to use curl, wiki CLI, postman, rosetta-cli, etc... on your host machine to play with or probe the localnet that was used for the test.
### Go tests
To run this test, do:
@ -175,7 +167,7 @@ make test-rpc
```
This test starts a localnet (within the Docker container), **ensures it reaches a consensus**, and runs a series of tests to ensure correct RPC behavior.
This test also acts as a preliminary integration test (more thorough tests are done on the testnets).
> The tests ran by this command can be found [here](https://github.com/harmony-one/harmony-test/tree/master/localnet).
> The tests ran by this command can be found [here](https://github.com/woop-chain/woop-test/tree/master/localnet).
If you wish to debug further with the localnet after the tests are done, open a new shell and run:
```bash
@ -183,9 +175,9 @@ make test-rpc-attach
```
> This will open a shell in the docker container that is running the Node API tests.
>
> Note that the docker container has the [Harmony CLI](https://docs.harmony.one/home/wallets/harmony-cli) on path,
> therefore you can use that to debug if needed. For example, one could do `hmy blockchain latest-headers` to check
> the current block height of localnet. Reference the documentation for the CLI [here](https://docs.harmony.one/home/wallets/harmony-cli)
> Note that the docker container has the [Woop CLI](https://docs.wikiwoop.com/home/wallets/woop-cli) on path,
> therefore you can use that to debug if needed. For example, one could do `wiki blockchain latest-headers` to check
> the current block height of localnet. Reference the documentation for the CLI [here](https://docs.wikiwoop.com/home/wallets/woop-cli)
> for more details & commands.
### Rosetta tests
@ -195,7 +187,7 @@ make test-rosetta
```
This test starts a localnet (within the Docker container), **ensures it reaches a consensus**, and runs the Construction & Data API checks using the [rosetta-cli](https://github.com/coinbase/rosetta-cli).
This test also acts as a preliminary integration test (more thorough tests are done on the testnets).
> The config for this test can be found [here](https://github.com/harmony-one/harmony-test/blob/master/localnet/configs/localnet_rosetta_test_s0.json) & [here](https://github.com/harmony-one/harmony-test/blob/master/localnet/configs/localnet_rosetta_test_s1.json)
> The config for this test can be found [here](https://github.com/woop-chain/woop-test/blob/master/localnet/configs/localnet_rosetta_test_s0.json) & [here](https://github.com/woop-chain/woop-test/blob/master/localnet/configs/localnet_rosetta_test_s1.json)
Similar to the RPC tests, if you wish to debug further with the localnet after the tests are done, open a new shell and run:
```bash
@ -204,10 +196,10 @@ make test-rosetta-attach
## License
Harmony is licensed under GNU Lesser General Public License v3.0. See [`LICENSE`](LICENSE) file for
Woop is licensed under GNU Lesser General Public License v3.0. See [`LICENSE`](LICENSE) file for
the terms and conditions.
Harmony includes third-party open-source code. In general, a source subtree
Woop includes third-party open-source code. In general, a source subtree
with a `LICENSE` or `COPYRIGHT` file is from a third party, and our
modifications thereto are licensed under the same third-party open source
license.
@ -216,7 +208,7 @@ Also please see [our Fiduciary License Agreement](FLA.md) if you are
contributing to the project. By your submission of your contribution to us, you
and we mutually agree to the terms and conditions of the agreement.
## Contributing To Harmony
## Contributing To Woop
See [`CONTRIBUTING`](CONTRIBUTING.md) for details.
@ -235,10 +227,3 @@ See [`CONTRIBUTING`](CONTRIBUTING.md) for details.