Skip to content

Commit 724f7ee

Browse files
committed
📝 Docs: add rules into docs
1 parent bd1d98b commit 724f7ee

File tree

1 file changed

+64
-1
lines changed

1 file changed

+64
-1
lines changed

README.md

Lines changed: 64 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ $ sgc
3535
3636
You can even create a global config. Just go to your users home and create a `.sgcrc`. The global config will be triggered if no project configurations are present.
3737

38-
### Types
38+
**Options:**
39+
- [types](#types)
40+
- [rules](#rules)
41+
42+
### types
3943

4044
> Types will define your git commits.
4145
@@ -76,3 +80,62 @@ or the `package.json`:
7680
}
7781
}
7882
```
83+
84+
### rules
85+
86+
Available rules:
87+
88+
- [max-char](#max-char)
89+
- [min-char](#min-char)
90+
- [end-with-dot](#end-with-dot)
91+
92+
#### max-char
93+
94+
**Type:** `number`
95+
96+
**Default:** `undefined`
97+
98+
If a number is set, it will not allow to commit messages **more than** the given number
99+
100+
Example:
101+
```json
102+
{
103+
"rules": {
104+
"max-char": 10
105+
}
106+
}
107+
```
108+
109+
#### min-char
110+
111+
**Type:** `number`
112+
113+
**Default:** `undefined`
114+
115+
If a number is set, it will not allow to commit messages **less than** the given number
116+
117+
Example:
118+
```json
119+
{
120+
"rules": {
121+
"min-char": 10
122+
}
123+
}
124+
```
125+
126+
#### end-with-dot
127+
128+
**Type:** `boolean`
129+
130+
**Default:** `true`
131+
132+
If it is set to false, it will not allow to commit messages with a dot at the
133+
134+
Example:
135+
```json
136+
{
137+
"rules": {
138+
"end-with-dot": false
139+
}
140+
}
141+
```

0 commit comments

Comments
 (0)