GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add typos for source code spelling check (#4690) · GenericMappingTools/pygmt@4172333

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • .github/ISSUE_TEMPLATE
    • 4-release_checklist.md
  • Makefile
  • doc/techref
    • justification_codes.md
  • environment.yml
  • pygmt
    • src
      • velo.py
    • tests
      • test_session_management.py
  • pyproject.toml
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎.github/ISSUE_TEMPLATE/4-release_checklist.md‎

Copy file name to clipboardExpand all lines: .github/ISSUE_TEMPLATE/4-release_checklist.md
+1-1Lines changed: 1 addition & 1 deletion
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ assignees: ''
3333
- [ ] Update warnings in `pygmt/_show_versions.py` as well as notes in [Not working transparency](https://www.pygmt.org/dev/install.html#not-working-transparency) regarding GMT-Ghostscript incompatibility
3434
- [ ] Reserve a DOI on [Zenodo](https://zenodo.org) by clicking on "New Version"
3535
- [ ] Finish up the "Changelog entry for v0.x.x" Pull Request (Use the previous changelog PR as a reference)
36-
- [ ] Run `make codespell` to check common misspellings. If there are any, either fix them or add them to `ignore-words-list` in `pyproject.toml`
36+
- [ ] Run `make spellcheck` to check common misspellings. If there are any, either fix them or add them to the relevant spelling configuration in `pyproject.toml`
3737
- [ ] Draft the announcement on https://hackmd.io/@pygmt
3838

3939
**Release**:
Collapse file

‎Makefile‎

Copy file name to clipboardExpand all lines: Makefile
+6-3Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ help:
1616
@echo " test_no_images run the test suite (including all doctests) but skip image comparisons"
1717
@echo " format run Ruff to automatically format the code"
1818
@echo " check run Ruff to check code style and quality"
19-
@echo " codespell run codespell to check common misspellings"
19+
@echo " spellcheck run codespell and typos to check common misspellings"
2020
@echo " typecheck run mypy for static type check"
2121
@echo " clean clean up build and generated files"
2222
@echo " distclean clean up build and generated files, including project metadata files"
@@ -67,8 +67,11 @@ check:
6767
ruff check $(FORMAT_FILES)
6868
ruff format --check $(FORMAT_FILES)
6969

70-
codespell:
71-
@codespell
70+
spellcheck:
71+
@status=0; \
72+
codespell || status=1; \
73+
typos || status=1; \
74+
exit $$status
7275

7376
typecheck:
7477
mypy ${PROJECT}
Collapse file

‎doc/techref/justification_codes.md‎

Copy file name to clipboardExpand all lines: doc/techref/justification_codes.md
+2-2Lines changed: 2 additions & 2 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ figure (**reference point**) and a point on the feature (**anchor point**). For
1010
users can use a two-character code, a combination of a vertical code and a horizontal
1111
code (order-independent):
1212

13-
- Vertical: **T**(op), **M**(iddle), **B**(ottom)
14-
- Horizontal: **L**(eft), **C**(entre), **R**(ight)
13+
- Vertical: **T** (Top), **M** (Middle), **B** (Bottom)
14+
- Horizontal: **L** (Left), **C** (Centre), **R** (Right)
1515

1616
For example, `"TL"` means **T**op **L**eft.
1717

Collapse file

‎environment.yml‎

Copy file name to clipboardExpand all lines: environment.yml
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ dependencies:
2727
- codespell
2828
- prek
2929
- ruff>=0.15.5
30+
- typos
3031
# Dev dependencies (unit testing)
3132
- matplotlib-base
3233
- pytest>=6.0
Collapse file

‎pygmt/src/velo.py‎

Copy file name to clipboardExpand all lines: pygmt/src/velo.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ def velo( # noqa : PLR0913
239239
Select the quantity that will be used with the CPT given via ``cmap``
240240
to set the fill color. Choose from **m**\ agnitude (vector magnitude
241241
or rotation magnitude), **e**\ ast-west velocity, **n**\ orth-south
242-
velocity, or **u**\ ser-supplied data column (supplied after the
242+
velocity, or **u** (user-supplied data column after the
243243
required columns). To instead use the corresponding error estimates
244244
(i.e., vector or rotation uncertainty) to lookup the color and paint
245245
the error ellipse or wedge instead, append **+e**.
Collapse file

‎pygmt/tests/test_session_management.py‎

Copy file name to clipboardExpand all lines: pygmt/tests/test_session_management.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def test_begin_end():
2121
end() # Kill the global session
2222
begin()
2323
with Session() as lib:
24-
lib.call_module("basemap", ["-R10/70/-3/8", "-JX4i/3i", "-Ba"])
24+
lib.call_module("basemap", ["-R10/70/-3/8", "-JX4i/3i", "-Bafg"])
2525
end()
2626
begin() # Restart the global session
2727
assert Path("pygmt-session.pdf").exists()
@@ -42,7 +42,7 @@ def test_gmt_compat_6_is_applied(capsys):
4242
lib.call_module("gmtset", ["GMT_COMPATIBILITY=5"])
4343
begin()
4444
with Session() as lib:
45-
lib.call_module("basemap", ["-R10/70/-3/8", "-JX4i/3i", "-Ba"])
45+
lib.call_module("basemap", ["-R10/70/-3/8", "-JX4i/3i", "-Bafg"])
4646
out, err = capsys.readouterr() # capture stdout and stderr
4747
assert out == ""
4848
assert err != (
Collapse file

‎pyproject.toml‎

Copy file name to clipboardExpand all lines: pyproject.toml
+16Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,22 @@ fallback_version = "999.999.999+unknown"
7373
[tool.codespell]
7474
ignore-words-list = "astroid,te,tripel,trough"
7575

76+
[tool.typos.default]
77+
extend-ignore-re = [
78+
# Ignore lines that end with `# codespell:ignore`
79+
# TODO: Refactor the re if codespell support is dropped in the future.
80+
"(?Rm)^.*(#|//)\\s*codespell:ignore$",
81+
]
82+
extend-ignore-words-re = [
83+
"astroid",
84+
"fo", # codespell:ignore
85+
"OCE", # codespell:ignore
86+
"[tT]ripel",
87+
]
88+
extend-ignore-identifiers-re = [
89+
"pn",
90+
]
91+
7692
[tool.coverage.run]
7793
omit = ["*/tests/*", "*pygmt/__init__.py"]
7894

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.