Skip to content

Commit 11d82cf

Browse files
author
Ronan Barrett
committed
initial push
1 parent c213ce2 commit 11d82cf

File tree

1,000 files changed

+362373
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,000 files changed

+362373
-0
lines changed

.github/workflows/ci.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: CI
2+
on: [pull_request]
3+
4+
jobs:
5+
golangci:
6+
name: lint
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v2
10+
- name: golangci-lint
11+
uses: golangci/golangci-lint-action@v1
12+
with:
13+
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
14+
version: v1.26
15+
args: -c .golangci.yaml
16+
17+
tests:
18+
name: Tests
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@v2
22+
23+
- run: make test

.golangci.yaml

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
linters:
2+
enable:
3+
# default
4+
- deadcode
5+
- errcheck
6+
- gosimple
7+
- govet
8+
- ineffassign
9+
- staticcheck
10+
- structcheck
11+
- typecheck
12+
- unused
13+
- varcheck
14+
# added
15+
- depguard
16+
# dupl
17+
- gochecknoinits
18+
- goconst
19+
- gocritic
20+
- gocyclo
21+
- gofmt
22+
- goimports
23+
- interfacer
24+
- misspell
25+
- nakedret
26+
- prealloc
27+
- scopelint
28+
- stylecheck
29+
- unconvert
30+
- unparam
31+
- gosec
32+
- golint
33+
disable:
34+
- gochecknoglobals # Using globals for prometheus counters (global shared context)
35+
- lll # hard to fulfill
36+
- maligned # not worth it atm.
37+
38+
run:
39+
modules-download-mode: vendor

CODE_OF_CONDUCT.md

+76
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as
6+
contributors and maintainers pledge to make participation in our project and
7+
our community a harassment-free experience for everyone, regardless of age, body
8+
size, disability, ethnicity, sex characteristics, gender identity and expression,
9+
level of experience, education, socio-economic status, nationality, personal
10+
appearance, race, religion, or sexual identity and orientation.
11+
12+
## Our Standards
13+
14+
Examples of behavior that contributes to creating a positive environment
15+
include:
16+
17+
* Using welcoming and inclusive language
18+
* Being respectful of differing viewpoints and experiences
19+
* Gracefully accepting constructive criticism
20+
* Focusing on what is best for the community
21+
* Showing empathy towards other community members
22+
23+
Examples of unacceptable behavior by participants include:
24+
25+
* The use of sexualized language or imagery and unwelcome sexual attention or
26+
advances
27+
* Trolling, insulting/derogatory comments, and personal or political attacks
28+
* Public or private harassment
29+
* Publishing others' private information, such as a physical or electronic
30+
address, without explicit permission
31+
* Other conduct which could reasonably be considered inappropriate in a
32+
professional setting
33+
34+
## Our Responsibilities
35+
36+
Project maintainers are responsible for clarifying the standards of acceptable
37+
behavior and are expected to take appropriate and fair corrective action in
38+
response to any instances of unacceptable behavior.
39+
40+
Project maintainers have the right and responsibility to remove, edit, or
41+
reject comments, commits, code, wiki edits, issues, and other contributions
42+
that are not aligned to this Code of Conduct, or to ban temporarily or
43+
permanently any contributor for other behaviors that they deem inappropriate,
44+
threatening, offensive, or harmful.
45+
46+
## Scope
47+
48+
This Code of Conduct applies within all project spaces, and it also applies when
49+
an individual is representing the project or its community in public spaces.
50+
Examples of representing a project or community include using an official
51+
project e-mail address, posting via an official social media account, or acting
52+
as an appointed representative at an online or offline event. Representation of
53+
a project may be further defined and clarified by project maintainers.
54+
55+
## Enforcement
56+
57+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
58+
reported by contacting the project team at [email protected]. All
59+
complaints will be reviewed and investigated and will result in a response that
60+
is deemed necessary and appropriate to the circumstances. The project team is
61+
obligated to maintain confidentiality with regard to the reporter of an incident.
62+
Further details of specific enforcement policies may be posted separately.
63+
64+
Project maintainers who do not follow or enforce the Code of Conduct in good
65+
faith may face temporary or permanent repercussions as determined by other
66+
members of the project's leadership.
67+
68+
## Attribution
69+
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71+
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
72+
73+
[homepage]: https://www.contributor-covenant.org
74+
75+
For answers to common questions about this code of conduct, see
76+
https://www.contributor-covenant.org/faq

CONTRIBUTING.md

+94
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
# Contributing Guidelines
2+
3+
This project is [Apache licensed](LICENSE.md) and accepts contributions via
4+
GitHub pull requests. This document outlines some of the conventions on
5+
development workflow, commit message formatting, contact points, and other
6+
resources to make it easier to get your contribution accepted.
7+
8+
9+
## Certificate of Origin
10+
11+
By contributing to this project you agree to the [Developer Certificate of
12+
Origin (DCO)](DCO). This document was created by the Linux Kernel community and
13+
is a simple statement that you, as a contributor, have the legal right to make
14+
the contribution.
15+
16+
In order to show your agreement with the DCO you should include at the end of
17+
commit message, the following line: `Signed-off-by: John Doe <[email protected]>`,
18+
using your real name.
19+
20+
This can be done easily using the [`-s`](https://github.com/git/git/blob/b2c150d3aa82f6583b9aadfecc5f8fa1c74aca09/Documentation/git-commit.txt#L154-L161) flag on the `git commit`.
21+
22+
23+
## Support Channels
24+
25+
The official support channels, for both users and contributors, are:
26+
27+
- GitHub [issues](https://github.com/voi-go/escalate-permissions/issues)*
28+
29+
30+
## How to Contribute
31+
32+
Pull Requests (PRs) are the main and exclusive way to contribute to the
33+
official `escalate-permissions` project.
34+
35+
36+
### Setup
37+
38+
[Fork][fork], then clone the repository:
39+
40+
```
41+
git clone [email protected]:your_github_username/escalate-permissions.git
42+
cd escalate-permissions
43+
git remote add upstream https://github.com/voi-oss/escalate-permissions.git
44+
git fetch upstream
45+
```
46+
47+
Install escalate-permissions dependencies:
48+
49+
```
50+
make vendor
51+
```
52+
53+
Make sure that the tests and the linters pass:
54+
55+
```
56+
make lint
57+
make test
58+
```
59+
60+
61+
### Making Changes
62+
63+
Start by creating a new branch for your changes:
64+
65+
```
66+
git checkout master
67+
git fetch upstream
68+
git rebase upstream/master
69+
git checkout -b new-feature
70+
```
71+
72+
Make your changes, then ensure that `make lint` and `make test` still pass. If
73+
you're satisfied with your changes, push them to your fork.
74+
75+
```
76+
git push origin new-feature
77+
```
78+
79+
Then use the GitHub UI to open a pull request.
80+
81+
At this point, you're waiting on us to review your changes. We *try* to respond
82+
to issues and pull requests within a few business days, and we may suggest some
83+
improvements or alternatives. Once your changes are approved, one of the
84+
project maintainers will merge them.
85+
86+
We're much more likely to approve your changes if you:
87+
88+
* Add tests for new functionality.
89+
* Write a [good commit message][commit-message].
90+
* Maintain backward compatibility.
91+
92+
[fork]: https://github.com/uber-go/zap/fork
93+
[open-issue]: https://github.com/voi-go/escalate-permissions/issues/new
94+
[commit-message]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html

0 commit comments

Comments
 (0)