Debian Codegraph @

docs/demos/scenario.txt

raw
1 sudo pip uninstall gitlint
2
3 virtualenv ~/gitlint-demo
4
5 source ~/gitlint-demo
6
7 mkdir ~/my-git-repo
8
9 git init
10
11 echo "test" > myfile.txt
12
13 git add .
14
15 git commit
16
17 WIP: This is a commit message title.
18 Second line not empty
19 This body line exceeds the defacto standard length of 80 characters per line in a commit m
20 essage.
21
22 cd ..
23
24
25 asciicinema rec demo.json
26
27 ------------------------------------
28
29 pip install gitlint
30
31 # Go to your git repo
32
33 cd my-git-repo
34
35 # Run gitlint to check for violations in the last commit message
36
37 gitlint
38
39 # For reference, here you can see that last commit message
40
41 git log -1
42
43 # You can also install gitlint as a git commit-msg hook
44
45 gitlint install-hook
46
47 # Let's try it out
48
49 echo "This is a test" > foo.txt
50
51 git add .
52
53 git commit
54
55 WIP: Still working on this awesome patchset that will change the world forever!
56
57 [Keep commit -> yes]
58
59 # You can modify gitlint's behavior by adding a .gitlint file
60
61 gitlint generate-config
62
63 vim .gitlint
64
65 gitlint
66
67 # Or specify additional config via the commandline
68
69 gitlint --ignore title-trailing-punctuation
70
71 # For more info, visit: http://jorisroovers.github.io/gitlint
72
73 exit
74
75 ------------------------------