-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #63 from kogisin/kogisin/60-add-contributing-docs
docs: add helpful docs for audit
- Loading branch information
Showing
3 changed files
with
76 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,18 @@ | ||
# Contributing | ||
|
||
TODO: add context | ||
We welcome contributions from anyone who is willing to create a new PR on budget module, make sure that you read and comply with this document. See the [open issues](https://github.com/tendermint/budget/issues) that we need help with. Feel free to inform us if you are willing to work on any issue. Note that the `master` branch contains the latest development version. | ||
|
||
We follow standard github best practices: | ||
|
||
- Fork the repository | ||
- Make sure your `branch` is from the tip of `master` branch | ||
- Make some commits to resolve an issue | ||
- Submit a pull request to `master` | ||
|
||
Rule of thumb: | ||
|
||
- Make sure you run tests by running `make test-all` locally to see there is any issue | ||
- Review all the checks on your PR and review code coverage report | ||
- Assign reviewers from code owners (@dongsam @kogisin @hallazzang) | ||
|
||
Thank you for your contribution! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,68 @@ | ||
# Technical Setup | ||
|
||
## Setup git hooks for Conventional Commit | ||
To ensure you have a successful experience working with our budget module, Tendermint recommends this technical setup. | ||
|
||
## Github Integration | ||
|
||
Click the GitHub icon in the sidebar for GitHub integration and follow the prompts. | ||
|
||
Clone the repos you work in | ||
|
||
- Fork or clone the https://github.com/tendermint/budget repository. | ||
|
||
Internal Tendermint users have different permissions, if you're not sure, fork the repo. | ||
|
||
## Software Requirement | ||
|
||
To build the project: | ||
|
||
- [Golang](https://golang.org/dl/) v1.16 or higher | ||
- [make](https://www.gnu.org/software/make/) to use `Makefile` targets | ||
|
||
## Development Environment Setup | ||
|
||
Setup git hooks for conventional commit. | ||
|
||
1. Install [`pre-commit`](https://pre-commit.com/) | ||
2. Run this command: | ||
|
||
``` | ||
$ pre-commit install --hook-type commit-msg | ||
``` | ||
|
||
2. Run the following command: | ||
```bash | ||
pre-commit install --hook-type commit-msg | ||
``` | ||
|
||
3. (Optional for macOS users) Install GNU `grep`: | ||
1. Run `brew install grep` | ||
2. Add this line to your shell profile: | ||
|
||
4. Run the following command | ||
```bash | ||
brew install grep | ||
``` | ||
|
||
5. Add the line to your shell profile: | ||
```bash | ||
export PATH="/usr/local/opt/grep/libexec/gnubin:$PATH" | ||
``` | ||
|
||
Now, whenever you make a commit, the `pre-commit` hook will be run to check if the commit message conforms [Conventional Commit](https://www.conventionalcommits.org/) rule. | ||
|
||
## Building | ||
|
||
To build the budget module node and command line client, run the `make build` command from the project's root folder. The output of the build will be generated in the `build` folder. | ||
For cross-builds use the standard `GOOS` and `GOARCH` env vars. i.e. to build for windows: | ||
```bash | ||
GOOS=windows GOARCH=amd64 make build | ||
``` | ||
export PATH="/usr/local/opt/grep/libexec/gnubin:$PATH" | ||
``` | ||
Now, whenever you make a commit, the `pre-commit` hook will be run to check if the commit message | ||
conforms [Conventional Commit](https://www.conventionalcommits.org/) rule. | ||
## Testing | ||
Run `make test-all` command to run tests. | ||
> 💡 you can also use the default `go` command to build the project, check the content of the [Makefile](https://github.com/tendermint/budget/blob/master/Makefile#L139) for reference | ||
## Installation | ||
To install the node client on your machine, run `make install` command from the project's root folder. | ||
|
||
> 💡 you can also use the default `go` command to build the project, check the content of the [Makefile](https://github.com/tendermint/budget/blob/master/Makefile#L87) for reference |