Skip to content

Commit 8a15a8f

Browse files
committed
Add initial examples
1 parent 59d6403 commit 8a15a8f

File tree

8 files changed

+303
-0
lines changed

8 files changed

+303
-0
lines changed

README.md

+7
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
11
# gitconsensus_examples
2+
3+
4+
** Democracy
5+
** Meritocracy
6+
** Oligarchy
7+
** Anarchy
8+
** Autocracy

examples/anarchy/.gitconsensus.yaml

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: false
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 1
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 0.01
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 1
22+
23+
# Close pull requests that don't pass after seven days without any activity (new commits).
24+
timeout: 168
25+
26+
# Do not allow changes to the license.
27+
license_lock: true
28+
29+
# Allow the consensus rules (this file) to be changed.
30+
consensus_lock: false
31+
32+
# Wait for at least one hour before merging.
33+
consensus_delay: 1
34+
35+
# Allow anyone to vote on this project, even if they've never contributed.
36+
contributors_only: false
37+
38+
# Don't put any restrictions on who can vote.
39+
collaborators_only: false

examples/autocracy/.gitconsensus.yaml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# Only one vote is needed.
15+
quorum: 1
16+
17+
# Only these people can vote.
18+
whitelist:
19+
- 'ProjectOverlord'
20+
21+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
22+
threshold: 1
23+
24+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
25+
merge_delay: 0
26+
27+
# Close pull requests that don't pass after seven days without any activity (new commits).
28+
timeout: 168
29+
30+
# Do not allow changes to the license.
31+
license_lock: true
32+
33+
# Allow the consensus rules (this file) to be changed.
34+
consensus_lock: true
35+
36+
# Wait for at least four days before merging any new consensus rules.
37+
consensus_delay: 0
38+
39+
# Allow anyone to vote on this project, even if they've never contributed.
40+
contributors_only: false
41+
42+
# Don't put any restrictions on who can vote.
43+
collaborators_only: false

examples/consensus/.gitconsensus.yaml

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 3
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 1
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 12
22+
23+
# Number of votes at which the merge_delay gets ignored, assuming no negative votes.
24+
delay_override: 6
25+
26+
# Close pull requests that don't pass after seven days without any activity (new commits).
27+
timeout: 168
28+
29+
# Do not allow changes to the license.
30+
license_lock: true
31+
32+
# Allow the consensus rules (this file) to be changed.
33+
consensus_lock: false
34+
35+
# Wait for at least four days before merging any new consensus rules.
36+
consensus_delay: 96
37+
38+
# Allow anyone to vote on this project, even if they've never contributed.
39+
contributors_only: false
40+
41+
# Don't put any restrictions on who can vote.
42+
collaborators_only: false
43+
44+

examples/democracy/.gitconsensus.yaml

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 3
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 0.51
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 12
22+
23+
# Number of votes at which the merge_delay gets ignored, assuming no negative votes.
24+
delay_override: 6
25+
26+
# Close pull requests that don't pass after seven days without any activity (new commits).
27+
timeout: 168
28+
29+
# Do not allow changes to the license.
30+
license_lock: true
31+
32+
# Allow the consensus rules (this file) to be changed.
33+
consensus_lock: false
34+
35+
# Wait for at least four days before merging any new consensus rules.
36+
consensus_delay: 96
37+
38+
# Allow anyone to vote on this project, even if they've never contributed.
39+
contributors_only: false
40+
41+
# Don't put any restrictions on who can vote.
42+
collaborators_only: false
+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 3
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 0.74
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 12
22+
23+
# Number of votes at which the merge_delay gets ignored, assuming no negative votes.
24+
delay_override: 6
25+
26+
# Close pull requests that don't pass after seven days without any activity (new commits).
27+
timeout: 168
28+
29+
# Do not allow changes to the license.
30+
license_lock: true
31+
32+
# Allow the consensus rules (this file) to be changed.
33+
consensus_lock: false
34+
35+
# Wait for at least four days before merging any new consensus rules.
36+
consensus_delay: 96
37+
38+
# Only allow people who have contributed to the project to vote.
39+
contributors_only: true
40+
41+
# Don't put any restrictions on who can vote.
42+
collaborators_only: false

examples/oligarchy/.gitconsensus.yaml

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 3
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 0.74
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 12
22+
23+
# Number of votes at which the merge_delay gets ignored, assuming no negative votes.
24+
delay_override: 6
25+
26+
# Close pull requests that don't pass after seven days without any activity (new commits).
27+
timeout: 168
28+
29+
# Do not allow changes to the license.
30+
license_lock: true
31+
32+
# Allow the consensus rules (this file) to be changed.
33+
consensus_lock: false
34+
35+
# Wait for at least four days before merging any new consensus rules.
36+
consensus_delay: 96
37+
38+
# Allow anyone to vote on this project, even if they've never contributed.
39+
contributors_only: false
40+
41+
# Only allow people marked as collaborators in the group to vote.
42+
collaborators_only: true
+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# See https://github.com/gitconsensus/GitConsensusCLI for more information about this file.
2+
3+
version: 3
4+
5+
# Don't count any vote from a user who votes for multiple options
6+
prevent_doubles: true
7+
8+
# Add extra labels for the vote counts and age when merging
9+
extra_labels: false
10+
11+
12+
pull_requests:
13+
14+
# At least three people should sign off on any pull request.
15+
quorum: 3
16+
17+
# Required percentage of "yes" votes (ignoring abstentions). It's a good idea to give "no" votes more power.
18+
threshold: 0.74
19+
20+
# Number of hours after last action (commit or opening the pull request) before issue can be merged
21+
merge_delay: 12
22+
23+
# Number of votes at which the merge_delay gets ignored, assuming no negative votes.
24+
delay_override: 6
25+
26+
# Close pull requests that don't pass after seven days without any activity (new commits).
27+
timeout: 168
28+
29+
# Do not allow changes to the license.
30+
license_lock: true
31+
32+
# Allow the consensus rules (this file) to be changed.
33+
consensus_lock: false
34+
35+
# Wait for at least four days before merging any new consensus rules.
36+
consensus_delay: 96
37+
38+
# Allow anyone to vote on this project, even if they've never contributed.
39+
contributors_only: false
40+
41+
# Don't put any restrictions on who can vote.
42+
collaborators_only: false
43+
44+

0 commit comments

Comments
 (0)