Skip to content

Commit 2fe04c1

Browse files
committed
Fix up issues detected by proselint
Hack together some extra logic in our bash script to ignore typography errors since proselint doesn't have project-local config that we can use.
1 parent 7744ffc commit 2fe04c1

10 files changed

Lines changed: 23 additions & 70 deletions

File tree

docs/source/api-reference/api.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Module Contents
1616

1717
To interact with the GitHub API you can either authenticate to access protected
1818
functionality or you can interact with it anonymously. Authenticating provides
19-
more functionality to the the user (developer).
19+
more functionality to the user (developer).
2020

2121
To authenticate, you may use :func:`github3.login`.
2222

docs/source/examples/issue.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ Issue Code Examples
33

44
Examples using ``Issue``\ s
55

6-
Administrating Issues
7-
---------------------
6+
Administering Issues
7+
--------------------
88

99
Let's assume you have your username and password stored in ``user`` and ``pw``
1010
respectively, you have your repository name stored in ``repo``, and the number

docs/source/examples/oauth.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ intention is to have users authenticate, you have a few options.
1010
application. (Or save the username somewhere, and just ask for the
1111
password.)
1212
2. Ask the user to supply their credentials once and store them somewhere for
13-
later use. (**VERY VERY BAD**)
13+
later use.
1414
3. Ask the user to supply their credentials once, get an authorization token
1515
and store that for later use.
1616

@@ -75,7 +75,5 @@ privileges, you simply do the following:
7575
# token == auth.token
7676
# in case the update changes the token
7777

78-
Hopefully this helps someone.
79-
8078
.. _redirects: http://developer.github.com/v3/oauth/#redirect-urls
8179
.. _scopes: http://developer.github.com/v3/oauth/#scopes

docs/source/examples/octocat.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ What you should see
99
::
1010

1111

12-
Hey Octocat!
12+
Hey Octocat
1313

1414
MMM. .MMM
1515
MMMMMMMMMMMMMMMMMMM
16-
MMMMMMMMMMMMMMMMMMM __________
17-
MMMMMMMMMMMMMMMMMMMMM | |
18-
MMMMMMMMMMMMMMMMMMMMMMM | Hey Ian! |
19-
MMMMMMMMMMMMMMMMMMMMMMMM |_ ______|
16+
MMMMMMMMMMMMMMMMMMM _________
17+
MMMMMMMMMMMMMMMMMMMMM | |
18+
MMMMMMMMMMMMMMMMMMMMMMM | Hey Ian |
19+
MMMMMMMMMMMMMMMMMMMMMMMM |_ _____|
2020
MMMM::- -:::::::- -::MMMM |/
2121
MM~:~ ~:::::~ ~:~MM
2222
.. MMMMM::. .:::+:::. .::MMMMM ..

docs/source/examples/source/octocat_say.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import github3
22

3-
print("Hey Octocat!")
4-
print(github3.octocat("Hey Ian!"))
3+
print("Hey Octocat")
4+
print(github3.octocat("Hey Ian"))
55
print("What do you think about github3.py?")
66
print(github3.octocat("github3.py rocks!"))
77
print("Thanks Octocat, that means a lot coming from you.")

docs/source/index.rst

Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -168,60 +168,6 @@ Contact
168168
.. _@sigmavirus24: https://twitter.com/sigmavirus24
169169

170170

171-
Testimonials
172-
============
173-
174-
.. raw:: html
175-
176-
<blockquote class="twitter-tweet"><p>gotta hand it to @<a
177-
href="https://twitter.com/sigmavirus24">sigmavirus24</a> ... github3.py is
178-
really well written. It will soon be powering the github stuff on
179-
@<a href="https://twitter.com/workforpie">workforpie</a>
180-
</p>&mdash; Brad Montgomery # (@bkmontgomery) <a
181-
href="https://twitter.com/bkmontgomery/status/325644863561400320">April 20, 2013</a>
182-
</blockquote>
183-
184-
<blockquote class="twitter-tweet"><p>awesome github v3 api wrapper in
185-
python <a href="https://t.co/PhD0Aj5X"
186-
title="https://github.com/sigmavirus24/github3.py">github.com/sigmavirus24/g#</a></p>&mdash;
187-
Mahdi Yusuf (@myusuf3) <a
188-
href="https://twitter.com/myusuf3/status/258571050927915008">October 17,
189-
2012</a></blockquote>
190-
191-
<blockquote class="twitter-tweet">
192-
<p>@<a href="https://twitter.com/sigmavirus24">sigmavirus24</a> github3 is
193-
awesome! Made my life much easier tonight, which is a very good
194-
thing.</p>&mdash; Mike Grouchy (@mgrouchy) <a
195-
href="https://twitter.com/mgrouchy/status/316370772782350336">March 26,
196-
2013</a></blockquote>
197-
198-
<blockquote class="twitter-tweet" data-conversation="none">
199-
<p>@<a href="https://twitter.com/sigmavirus24">sigmavirus24</a> "There are
200-
so many Python client libraries for GitHub API, I tried all of them, and
201-
my conclusion is: github3.py is the best."</p>&mdash; Hong Minhee
202-
(@hongminhee) <a
203-
href="https://twitter.com/hongminhee/status/315295733899210752">March 23,
204-
2013</a></blockquote>
205-
206-
<blockquote class="twitter-tweet">
207-
<p>@<a href="https://twitter.com/sigmavirus24">sigmavirus24</a> I cannot
208-
wait to use your github package for <a
209-
href="https://twitter.com/search/%23zci">#zci</a>. Do you have it packaged
210-
for debian by any chance?</p>&mdash; Zygmunt Krynicki (@zygoon) <a
211-
href="https://twitter.com/zygoon/status/316608301527887872">March 26,
212-
2013</a></blockquote>
213-
214-
<blockquote class="twitter-tweet">
215-
<p>Developing against github3.py's API is a joy, kudos to @<a
216-
href="https://twitter.com/sigmavirus24">sigmavirus24</a></p>&mdash;
217-
Alejandro Gomez (@dialelo) <a
218-
href="https://twitter.com/dialelo/status/316846075015229440">March 27,
219-
2013</a></blockquote>
220-
221-
<script async src="//platform.twitter.com/widgets.js"
222-
charset="utf-8"></script>
223-
224-
225171
.. links
226172
227173
.. _GitHub API:

docs/source/release-notes/0.3.0.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@
5252
5353
import github3
5454
55-
r = github3.repository('sigmavirus24', 'github3.py')
55+
repo = github3.repository('sigmavirus24', 'github3.py')
5656
5757
template = """Some kind of template where you mention this repository
5858
{0}"""
5959
60-
print(template.format(r))
60+
print(template.format(repo))
6161
# Some kind of template where you mention this repository
6262
# sigmavirus24/github3.py
6363

docs/source/release-notes/1.0.0.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
-----------------
55

66
1.0.0 is a huge release. It includes a great deal of changes to ``github3.py``.
7-
It is suggested you read the following release notes *very* carefully.
7+
It is suggested you read the following release notes carefully.
88

99
Unfortunately, it's plausible that some things have slipped through the cracks
1010
in these release notes.

tests/bin/.doclint.swp

12 KB
Binary file not shown.

tests/bin/doclint

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/sh
2+
3+
output="$(find docs/source -name '*.rst' | xargs proselint)"
4+
exit_code=$?
5+
6+
if echo "$output" | grep -qve 'typography' ; then
7+
echo $output
8+
exit $exit_code
9+
fi

0 commit comments

Comments
 (0)