Skip to content

Commit 5e543cb

Browse files
authored
Merge pull request tj#1052 from spacewander/gsm
Add typo checker
2 parents 3a258cb + ba9e6f0 commit 5e543cb

File tree

12 files changed

+75
-123
lines changed

12 files changed

+75
-123
lines changed

.github/.ignore_words

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
gool

.github/workflows/ci.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,17 @@ on:
66
branches: [master]
77
jobs:
88
lint:
9-
runs-on: 'ubuntu-22.04'
9+
runs-on: 'ubuntu-latest'
1010
steps:
1111
- name: 'Get Changed Files'
1212
id: 'files'
1313
uses: 'masesgroup/retrieve-changed-files@v2'
1414
with:
1515
format: 'json'
16+
# a force push will cause the action above to fail. Don't do force push when people are
17+
# reviewing!
1618
- name: Check out code.
17-
uses: actions/checkout@v2
19+
uses: actions/checkout@v3
1820
- name: 'Check EditorConfig Lint'
1921
run: |
2022
sudo apt install -y jq golang
@@ -23,17 +25,27 @@ jobs:
2325
readarray -t changed_files <<<"$(jq -r '.[]' <<<'${{ steps.files.outputs.added_modified }}')"
2426
~/go/bin/editorconfig-checker ${changed_files[@]}
2527
28+
typo:
29+
runs-on: ubuntu-latest
30+
steps:
31+
- name: Check out code.
32+
uses: actions/checkout@v3
33+
- name: spell check
34+
run: |
35+
pip install codespell==2.2
36+
git grep --cached -l '' | grep -v -e 'History\.md' -e 'AUTHORS' -e 'man/.*\.1' -e 'man/.*\.html' | xargs codespell --ignore-words=.github/.ignore_words
37+
2638
build:
2739
strategy:
2840
fail-fast: false
2941
matrix:
3042
platform:
31-
- ubuntu-22.04
43+
- ubuntu-latest
3244
- macos-latest
3345
runs-on: ${{ matrix.platform }}
3446
steps:
3547
- name: Check out code.
36-
uses: actions/checkout@v2
48+
uses: actions/checkout@v3
3749
- name: Linux Install
3850
if: matrix.platform == 'ubuntu-22.04'
3951
run: |

Commands.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,8 +176,8 @@ authors :
176176
1 Guillermo Rauch 0.6%
177177
```
178178

179-
This command can also take a *commitish*, and will print a summary for commits in
180-
the commitish range:
179+
This command can also take a *committish*, and will print a summary for commits in
180+
the committish range:
181181

182182
```bash
183183
$ git summary v42..

bin/git-clear-soft

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env bash
22

33
echo -n "Sure? - This command may delete files that cannot be recovered. Files and directories in .gitignore will be preserved [y/N]: "
4-
read -r ans
5-
if [ "$ans" == "y" ]
4+
read -r answer
5+
if [ "$answer" == "y" ]
66
then git clean -d -f && git reset --hard
77
fi

bin/git-standup

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ git_output() {
227227
echo ""
228228
fi
229229
fi
230-
# TODO optimize:return if the latest commit of a branch is eariler than the 'since' day
230+
# TODO optimize:return if the latest commit of a branch is earlier than the 'since' day
231231
done
232232
else
233233
# shellcheck disable=SC2086

bin/git-summary

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ uncommitted_changes_count() {
195195
}
196196

197197

198-
COLUMN_CMD_DELIMTER="¬" # Hopefully, this symbol is not used in branch names... I use it as a seperator for columns
198+
COLUMN_CMD_DELIMTER="¬" # Hopefully, this symbol is not used in branch names... I use it as a separator for columns
199199
SP="$COLUMN_CMD_DELIMTER|"
200200

201201
print_summary_by_line() {

man/git-magic.1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
.\" generated with Ronn/v0.7.3
22
.\" http://github.com/rtomayko/ronn/tree/0.7.3
33
.
4-
.TH "GIT\-MAGIC" "1" "October 2021" "" "Git Extras"
4+
.TH "GIT\-MAGIC" "1" "May 2023" "" "Git Extras"
55
.
66
.SH "NAME"
77
\fBgit\-magic\fR \- Automate add/commit/push routines
@@ -10,7 +10,7 @@
1010
\fBgit\-magic\fR [\-a] [\-m \fImsg\fR] [\-e] [\-p] [\-f]
1111
.
1212
.SH "DESCRIPTION"
13-
Produces summary of changes for commit message from \fBgit status \-\-porcelain\fR output\. Commits staged changes with the generated commit message and opens editor to modify generated commit message optionally\. Also staging and pushing can be automated optinally\.
13+
Produces summary of changes for commit message from \fBgit status \-\-porcelain\fR output\. Commits staged changes with the generated commit message and opens editor to modify generated commit message optionally\. Also staging and pushing can be automated optionally\.
1414
.
1515
.SH "OPTIONS"
1616
\-a
@@ -93,7 +93,7 @@ Date: Thu Sep 30 20:14:22 2021 +0300
9393
.IP "" 0
9494
.
9595
.SH "AUTHOR"
96-
Written by Alper S\. Soylu \fI54alpersaid@gmail\.com\fR
96+
Written by Alper S\. Soylu <54alpersaid@gmail\.com>
9797
.
9898
.SH "REPORTING BUGS"
9999
<\fIhttps://github\.com/tj/git\-extras/issues\fR>

man/git-magic.html

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/git-magic.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ git-magic(1) -- Automate add/commit/push routines
1010
Produces summary of changes for commit message from `git status --porcelain` output.
1111
Commits staged changes with the generated commit message and
1212
opens editor to modify generated commit message optionally.
13-
Also staging and pushing can be automated optinally.
13+
Also staging and pushing can be automated optionally.
1414

1515
## OPTIONS
1616

man/git-summary.1

Lines changed: 9 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,86 +1,58 @@
1-
.\" generated with Ronn/v0.7.3
2-
.\" http://github.com/rtomayko/ronn/tree/0.7.3
3-
.
4-
.TH "GIT\-SUMMARY" "1" "February 2023" "" "Git Extras"
5-
.
1+
.\" generated with Ronn-NG/v0.9.1
2+
.\" http://github.com/apjanke/ronn-ng/tree/0.9.1
3+
.TH "GIT\-SUMMARY" "1" "June 2023" "" "Git Extras"
64
.SH "NAME"
75
\fBgit\-summary\fR \- Show repository summary
8-
.
96
.SH "SYNOPSIS"
107
\fBgit\-summary\fR [\-\-dedup\-by\-email] [\-\-no\-merges] [<committish>]
11-
.
12-
.br
8+
.P
139
\fBgit\-summary\fR \-\-line [<path>]
14-
.
1510
.SH "DESCRIPTION"
1611
Shows a summary of the repository or a path within it\.
17-
.
1812
.SH "OPTIONS"
1913
<committish>
20-
.
2114
.P
2215
Summarize only the range of commits included in the <committish>\.
23-
.
2416
.P
2517
<path>
26-
.
2718
.P
2819
Summarize only the range of files included in the <path>\.
29-
.
3020
.P
3121
\-\-dedup\-by\-email
32-
.
3322
.P
3423
Remove duplicate authors who belong to the same email address\. For example,
35-
.
3624
.IP "" 4
37-
.
3825
.nf
39-
4026
$ git summary
41-
\.\.\.
27+
\|\.\|\.\|\.
4228
133 TJ Holowaychuk 9\.9%
4329
115 Tj Holowaychuk 8\.5%
4430

4531
$ git summary \-\-dedup\-by\-email
46-
\.\.\.
32+
\|\.\|\.\|\.
4733
248 TJ Holowaychuk 18\.4%
48-
.
4934
.fi
50-
.
5135
.IP "" 0
52-
.
5336
.P
5437
\-\-no\-merges
55-
.
5638
.P
5739
Exclude merge commits\.
58-
.
5940
.P
6041
\-\-line
61-
.
6242
.P
6343
Summarize with lines other than commits\. When \fB\-\-line\fR is specified, the last argument is treated as <path>\.
64-
.
6544
.P
6645
This option can not be used together with \fB\-\-dedup\-by\-email\fR or \fB\-\-no\-merges\fR\.
67-
.
6846
.P
6947
\-\-output\-style <style>
70-
.
7148
.P
72-
Summarizes the repository and print the output accoring to the specified style\. Styles: * \fBtabular\fR: Prints the summary in a tabular form having a header in the first line and the values in the second\. Column separator is a \fB|\fR sorrounded by at least one space on each side\. * \fBoneline\fR: Prints the summary in a single line\. Fields are separated by a \fB/\fR sorrounded by one space on each side\.
73-
.
49+
Summarizes the repository and print the output according to the specified style\. Styles: * \fBtabular\fR: Prints the summary in a tabular form having a header in the first line and the values in the second\. Column separator is a \fB|\fR sorrounded by at least one space on each side\. * \fBoneline\fR: Prints the summary in a single line\. Fields are separated by a \fB/\fR sorrounded by one space on each side\.
7450
.P
7551
Some information like the authors cannot be displayed in this mode\.
76-
.
7752
.SH "EXAMPLES"
7853
Outputs a repo summary:
79-
.
8054
.IP "" 4
81-
.
8255
.nf
83-
8456
$ git summary
8557

8658
project : express
@@ -110,94 +82,59 @@ authors :
11082
1 ewoudj
11183
1 isaacs
11284
1 Matt Colyer
113-
.
11485
.fi
115-
.
11686
.IP "" 0
117-
.
11887
.P
11988
This command can also take a committish, and will print a summary for the range of commits included in the committish:
120-
.
12189
.IP "" 4
122-
.
12390
.nf
124-
12591
$ git summary v42\.\.
126-
.
12792
.fi
128-
.
12993
.IP "" 0
130-
.
13194
.P
13295
Outputs a repo summary by line:
133-
.
13496
.IP "" 4
135-
.
13697
.nf
137-
13898
$ git summary \-\-line
13999

140100
project : git\-extras
141101
lines : 26820
142102
authors :
143-
\.\.\.
144-
.
103+
\|\.\|\.\|\.
145104
.fi
146-
.
147105
.IP "" 0
148-
.
149106
.P
150107
Filter with the path:
151-
.
152108
.IP "" 4
153-
.
154109
.nf
155-
156110
$ git summary \-\-line bin/
157111

158112
project : git\-extras
159113
lines : 4420
160114
authors :
161-
\.\.\.
162-
.
115+
\|\.\|\.\|\.
163116
.fi
164-
.
165117
.IP "" 0
166-
.
167118
.P
168119
Tabular summary
169-
.
170120
.IP "" 4
171-
.
172121
.nf
173-
174122
$ git summary \-\-output\-style tabular
175123
# Repo | Age | Last active | Active on | Commits | Uncommitted | Branch
176124
git\-extras | 13 years | 7 hours ago | 807 days | 1703 | 3 | master
177-
.
178125
.fi
179-
.
180126
.IP "" 0
181-
.
182127
.P
183128
Oneline summary
184-
.
185129
.IP "" 4
186-
.
187130
.nf
188-
189131
$ git summary \-\-output\-style oneline
190132
git\-extras / age: 13 years / last active: 7 hours ago / active on 807 days / commits: 1703 / uncommitted: 3 / branch: master
191-
.
192133
.fi
193-
.
194134
.IP "" 0
195-
.
196135
.SH "AUTHOR"
197136
Written by Tj Holowaychuk <\fItj@vision\-media\.ca\fR>
198-
.
199137
.SH "REPORTING BUGS"
200138
<\fIhttps://github\.com/tj/git\-extras/issues\fR>
201-
.
202139
.SH "SEE ALSO"
203140
<\fIhttps://github\.com/tj/git\-extras\fR>

0 commit comments

Comments
 (0)