Skip to content

Commit 7e02727

Browse files
committed
docs: add recipe for linting of all commits in a PR
* be more explicit / guide more than #24 * closes #35 * connected to #12
1 parent 05b4427 commit 7e02727

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed

.conventional-changelog-lintrc

-5
This file was deleted.

readme.md

+13-3
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,16 @@ As part of `npm test`
6767
}
6868
```
6969
70+
#### Lint all commits in PR
71+
72+
```sh
73+
# On Travis CI
74+
conventional-changelog-lint --from=$TRAVIS_BRANCH to=$TRAVIS_PULL_REQUEST_BRANCH
75+
76+
# E.g.:
77+
conventional-changelog-lint --from=master to=docs/add-pr-recipe
78+
```
79+
7080
#### Travis
7181
7282
```yml
@@ -208,7 +218,7 @@ Perform `git fetch --shallow` before linting.
208218
Most likely you are reading this because you where presented with an error message:
209219
210220
```
211-
'Could not get git history from shallow clone.
221+
'Could not get git history from shallow clone.
212222
Use git fetch --shallow before linting.
213223
Original issue: https://git.io/vyKMq\n Refer to https://git.io/vyKMv for details.'
214224
```
@@ -217,7 +227,7 @@ Most likely you are reading this because you where presented with an error messa
217227
218228
git supports checking out `shallow` clones of a repository to save bandwith in times.
219229
These limited copies do not contain a full git history. This makes `conventional-changelog-lint`
220-
fail, especially when running on large commit ranges.
230+
fail, especially when running on large commit ranges.
221231
To ensure linting works every time you should convert a shallow git repo to a complete one.
222232
Use `git fetch --shallow` to do so.
223233
@@ -226,7 +236,7 @@ Use `git fetch --shallow` to do so.
226236
Ensure full git checkouts on TravisCI, add to `.travis.yml`:
227237
228238
```yml
229-
before_install:
239+
before_install:
230240
- git fetch --unshallow
231241
```
232242

0 commit comments

Comments
 (0)