Skip to content

Commit edbc76b

Browse files
committed
Fix issues found by codespell
1 parent 69d51c9 commit edbc76b

File tree

10 files changed

+23
-23
lines changed

10 files changed

+23
-23
lines changed

.github/workflows/lint.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ jobs:
2525
- uses: codespell-project/actions-codespell@master
2626
with:
2727
skip: '*.po'
28-
ignore_words_list: ba,te,deltion
28+
ignore_words_list: te,ot

curtsies/formatstring.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,7 @@ def join(self, iterable):
461461
# TODO make this split work like str.split
462462
def split(self, sep=None, maxsplit=None, regex=False):
463463
# type: (Text, int, bool) -> List[FmtStr]
464-
"""Split based on seperator, optionally using a regex.
464+
"""Split based on separator, optionally using a regex.
465465
466466
Capture groups are ignored in regex, the whole pattern is matched
467467
and used to split the original FmtStr."""
@@ -597,7 +597,7 @@ def __mul__(self, other):
597597
return sum([self for _ in range(other)], FmtStr())
598598
raise TypeError("Can't multiply those")
599599

600-
# TODO ensure emtpy FmtStr isn't a problem
600+
# TODO ensure empty FmtStr isn't a problem
601601

602602
@property
603603
def shared_atts(self):

curtsies/input.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ def threadsafe_event_trigger(self, event_type):
333333
334334
Returned callback function will create an event of type event_type
335335
which will interrupt an event request if one
336-
is concurrently occuring, otherwise adding the event to a queue
336+
is concurrently occurring, otherwise adding the event to a queue
337337
that will be checked on the next event request."""
338338
readfd, writefd = os.pipe()
339339
self.readers.append(readfd)

curtsies/window.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ def for_stdout(s):
152152

153153

154154
class FullscreenWindow(BaseWindow):
155-
"""2D-text rendering window that dissappears when its context is left
155+
"""2D-text rendering window that disappears when its context is left
156156
157157
FullscreenWindow will only render arrays the size of the terminal
158158
or smaller, and leaves no trace on exit (like top or vim). It never
@@ -280,7 +280,7 @@ def __init__(
280280
on leaving context
281281
hide_cursor (bool): Hides cursor while in context
282282
extra_bytes_callback (f(bytes) -> None): Will be called with extra
283-
bytes inadvertantly read in get_cursor_position(). If not
283+
bytes inadvertently read in get_cursor_position(). If not
284284
provided, a ValueError will be raised when this occurs.
285285
"""
286286
BaseWindow.__init__(self, out_stream=out_stream, hide_cursor=hide_cursor)
@@ -337,7 +337,7 @@ def retrying_read():
337337
c = in_stream.read(1)
338338
if c == "":
339339
raise ValueError(
340-
"Stream should be blocking - should't"
340+
"Stream should be blocking - shouldn't"
341341
" return ''. Returned %r so far",
342342
(resp,),
343343
)

docs/FSArray.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ An array like the above might be repeatedly constructed and rendered with a :py:
5656

5757
Slicing works like it does with a :py:class:`~curtsies.FmtStr`, but in two dimensions.
5858
:py:class:`~curtsies.FSArray` are *mutable*, so array assignment syntax can be used for natural
59-
compositing as in the above exaple.
59+
compositing as in the above example.
6060

6161
If you're dealing with terminal output, the *width* of a string becomes more
6262
important than it's *length* (see :ref:`len-vs-width`).

docs/Input.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ and can be acted upon.
2626
Since it's iterable, ``next()`` can be used to wait for a single event.
2727
:py:meth:`~curtsies.Input.send` works like ``next()`` but takes a timeout
2828
in seconds, which if reached will cause None to be returned signalling
29-
that no keypress or other event occured within the timeout.
29+
that no keypress or other event occurred within the timeout.
3030

3131
Key events are unicode strings, but sometimes event objects
3232
(see :class:`~curtsies.events.Event`) are returned instead.

docs/ansi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ def _colorize_block_contents(self, block):
124124
last_end = 0
125125
# iterate over all color codes
126126
for match in COLOR_PATTERN.finditer(raw):
127-
# add any text preceeding this match
127+
# add any text preceding this match
128128
head = raw[last_end : match.start()]
129129
self._add_text(head)
130130
# update the match end

docs/gameloop.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Gameloop Example
22
^^^^^^^^^^^^^^^^
33

4-
Use scheduled events for realtime interative programs:
4+
Use scheduled events for realtime interactive programs:
55

66
.. literalinclude:: ../examples/fps.py
77

notes/notesfromdarius.txt

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ read this: http://www.cs.utexas.edu/~wcook/Drafts/2009/essay.pdf
1212

1313
(erlang was also cool like that, maybe look at it again)
1414

15-
played at all with sounds fairly diff, cool in that syate very explicty very cool
15+
played at all with sounds fairly diff, cool in that syate very explicitly very cool
1616

1717
i assume you've seen how objc- does it?
1818

@@ -22,7 +22,7 @@ I was guessing it would use font, but I was wrong
2222

2323
or font or something
2424

25-
check out Darius's halp - for editor <-> repl interaction without the repl
25+
check out Darius's help - for editor <-> repl interaction without the repl
2626

2727
I going to get some food
2828

@@ -33,10 +33,10 @@ this could also be pass this message
3333

3434
right now it's not realtime it blocks on getting an event, and has no timer events or - butit'd be nice to change
3535

36-
I thoguht the simpler model was perfect for a repl - wait until user does somethign - but code can do anything
36+
I thoguht the simpler model was perfect for a repl - wait until user does something - but code can do anything
3737
which way?
3838

39-
I guess I don't wan tto deal with threads unless each thread is an event driven loop <- I just don't hvae this yet
39+
I guess I don't want tto deal with threads unless each thread is an event driven loop <- I just don't have this yet
4040

4141
right now it's a single thread of execution
4242

@@ -51,7 +51,7 @@ run code
5151
run code
5252
oh code wants to read on stdin - so this is a greenet, suspend execution and
5353

54-
the realization I had was that in bptuhon-curtiess I 'm also emulating the terminal - I'm responsible for colelcting that the user hit a key at *any* time, not jsut during input
54+
the realization I had was that in bptuhon-curtiess I 'm also emulating the terminal - I'm responsible for colelcting that the user hit a key at *any* time, not just during input
5555

5656
so it really feels like an evented system? - at least queues and messaging and things
5757

@@ -90,8 +90,8 @@ could you only have i
9090

9191
deeplly immutable - E
9292
not obvious what this does
93-
then it's a boolean thing, so presence is enought
94-
shoudl be documentation of that
93+
then it's a boolean thing, so presence is enough
94+
should be documentation of that
9595

9696
self.atts is a dictionary of {fg:blue, bg:red, bold:Trueo
9797

@@ -101,7 +101,7 @@ I'm actually paying lea A. (hs'er) to make a logo! So if I ha
101101

102102
Also if bpython starts to use this as ath main thing, I'lll need to work on cleanign it up.
103103

104-
I guess so I don't have release things set up - I could give you github comit access for this and just put it on another brnach for now?
104+
I guess so I don't have release things set up - I could give you github commit access for this and just put it on another branch for now?
105105

106106
git pull upstream
107107

@@ -110,11 +110,11 @@ the readme is the only docs right now
110110

111111
mostly tests
112112

113-
I wrote the whole thing tried to do it clearly, then had performnace problems and went
113+
I wrote the whole thing tried to do it clearly, then had performance problems and went
114114

115115
just python slice bookkeeping
116116

117-
it's poorly named, it doens't accomplish that - it's just
117+
it's poorly named, it doesn't accomplish that - it's just
118118

119119
asdf[1:]
120120
normalize_slice(4, slice(1, None, None)) -> slice(1, 4, 1)
@@ -149,7 +149,7 @@ meaning that sequence isn't recognizd or isn't valid
149149

150150
this depends on every input having
151151

152-
if ab is passed it assumes it must have alrady been called with a
152+
if ab is passed it assumes it must have already been called with a
153153

154154

155155
ther'e no speed concertn, we could assert that too

tests/test_fmtstr.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ def test_slice(self):
347347
self.assertEqual(s[1:], fmtstr("mp") + " ")
348348
self.assertEqual(blue("a\nb")[0:1], blue("a"))
349349

350-
# considering changing behavior so that this doens't work
350+
# considering changing behavior so that this doesn't work
351351
# self.assertEqual(fmtstr('Hi!', 'blue')[15:18], fmtstr('', 'blue'))
352352

353353

0 commit comments

Comments
 (0)