Skip to content

Commit

Permalink
Add renaming advice based on IETF draft-knodel-terminology-00
Browse files Browse the repository at this point in the history
Add a new "usage" dictionary with usage advice based on:
https://tools.ietf.org/id/draft-knodel-terminology-00.html#rfc.section.1.1.1

Offer to replace master/slave with:
- Primary-secondary
- Leader-follower
- Active-standby
- Primary-replica
- Writer-reader
- Coordinator-worker
- Parent-helper
  • Loading branch information
hadess committed Jun 11, 2020
1 parent 540ddc5 commit 0a0eb2e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions codespell_lib/_codespell.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
('clear', 'for unambiguous errors', '', False, None),
('rare', 'for rare but valid words', '_rare', None, None),
('informal', 'for informal words', '_informal', True, True),
('usage', 'for recommended terms', '_usage', False, False),
('code', 'for words common to code and/or mathematics', '_code', None, None), # noqa: E501
('names', 'for valid proper names that might be typos', '_names', None, None), # noqa: E501
('en-GB_to_en-US', 'for corrections from en-GB to en-US', '_en-GB_to_en-US', True, True), # noqa: E501
Expand Down
4 changes: 4 additions & 0 deletions codespell_lib/data/dictionary_usage.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
master->primary, leader, active, writer, coordinator, parent,
masters->primaries, leaders, actives, writers, coordinators, parents,
slave->secondary, follower, standby, replica, reader, worker, helper,
slaves->secondaries, followers, standbys, replicas, readers, workers, helpers,
2 changes: 2 additions & 0 deletions codespell_lib/tests/test_dictionary.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,8 @@ def test_error_checking_in_aspell(err, rep, err_aspell, rep_aspell, match):
allowed_dups = {
('dictionary.txt', 'dictionary_en-GB_to_en-US.txt'),
('dictionary.txt', 'dictionary_rare.txt'),
('dictionary.txt', 'dictionary_usage.txt'),
('dictionary_rare.txt', 'dictionary_usage.txt'),
}


Expand Down

0 comments on commit 0a0eb2e

Please sign in to comment.