Skip to content

Commit

Permalink
Update dev docs
Browse files Browse the repository at this point in the history
Adds some additional links on some workflow steps and removes an older
unused section.

There is also a little bit more detail on the desired commit message
format.

Signed-off-by: Patrick East <east.patrick@gmail.com>
  • Loading branch information
patrick-east committed Apr 16, 2020
1 parent 5e6a138 commit 71454de
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 13 deletions.
28 changes: 28 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,34 @@ the following line at the end of your commit message:
Fixes #<ISSUE_NUMBER>
```

If the changes are isolated to a specific OPA package or directory please
include a prefix on the first line of the commit message with the following
format:

```
<package or directory path>: <description>
```

For example, a change to the `ast` package:
```
ast: Fix X when Y happens
<Details...>
Fixes: #123
Signed-off-by: Random J Developer <random@developer.example.org>
```

or a change in the OPA website content (found in `./docs/website/**`:
```
docs/website: Add X to homepage for Y
<Details...>
Fixes: #456
Signed-off-by: Random J Developer <random@developer.example.org>
```

## Developer Certificate Of Origin

The OPA project requires that contributors sign off on changes submitted to OPA repositories.
Expand Down
20 changes: 7 additions & 13 deletions docs/devel/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,14 @@ with `make check`.
git commit -s
git push origin somefeature
```

> Make sure to use a [good commit message](../../CONTRIBUTING.md#commit-messages)

1. Submit a Pull Request via https://github.com/\<GITHUB USERNAME>/opa. You
should be prompted to with a "Compare and Pull Request" button that
mentions your branch.
1. Submit a Pull Request from your fork. See the official [GitHub Documentation](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request-from-a-fork)
for instructions to create the request.

> Hint: You should be prompted to with a "Compare and Pull Request" button
that mentions your new branch on [https://github.com/open-policy-agent/opa](https://github.com/open-policy-agent/opa)

1. Once your Pull Request has been reviewed and signed off please squash your
commits. If you have a specific reason to leave multiple commits in the
Expand Down Expand Up @@ -132,16 +136,6 @@ More details on the pattern: [https://github.com/go-modules-by-example/index/blo
Update these the same way as any other Go package. Ensure that any build script
only uses `go run ./vendor/<tool pkg>` to force using the correct version.

## Rego

If you need to modify the Rego syntax you must update ast/rego.peg. Both `make
build` and `make test` will re-generate the parser but if you want to test the
parser generation explicitly you can run `make generate`.

If you are modifying the Rego syntax you must commit the parser source file
(ast/parser.go) that `make generate` produces when you are done. The generated
code is kept in the repository so that commands such as `go get` work.

## Go

If you need to update the version of Go used to build OPA you must update these
Expand Down

0 comments on commit 71454de

Please sign in to comment.