Skip to main content

Look up words in the Garner Usage Dictionary from the command-line.

Project description

Garner

Garner is a command-line interface for the Garner Usage Dictionary.

Install

On macOS or Linux with Homebrew:

brew install jmcguire/garner/garner-dict

Or, on any system with Python 3.9 or newer, install the Python package with pipx:

pipx install garner-dict

Both install the command as garner. Try it with:

garner affect
garner --search accomodate
garner --help

Pipe a long entry through less for paged output:

garner affect | less

About Distribution

This is an independent command-line interface and packaging project. It is not an official publication of Bryan A. Garner or of the Garner Usage Dictionary. The code is MIT licensed, but the dictionary content is copyrighted by Bryan A. Garner and is not licensed by this repository. See NOTICE.

The Homebrew package is intentionally published in the maintainer's personal tap (jmcguire/garner), not in homebrew/core. That makes the source, maintainer, and content notice explicit, and does not imply that the dictionary content has been approved for official Homebrew distribution. The PyPI package and Homebrew formula bundle the same compiled dictionary database. Anyone who uses or redistributes it remains responsible for respecting the applicable rights.

Developer Notes

Clone this repository, then create a development environment:

python3 -m venv venv
./venv/bin/python -m pip install -r requirements.txt

The Markdown files in definitions/ are the editable source of truth. Garner builds them into an SQLite database for fast lookup and search. Build the local database before trying source changes:

./venv/bin/garner --build

Then use the tool normally:

./venv/bin/garner affect
./venv/bin/garner --search accomodate

Tests

Run the tests with:

./venv/bin/python -m unittest discover -s tests

The tests use a small fixture dictionary in tests/fixtures/definitions, not the full definitions collection. They build a temporary SQLite database from those entries and cover core lookup, search, forwarding, and formatting behavior without making small source-formatting changes needlessly brittle.

Licensing

The code in this repository is MIT licensed. See LICENSE.

The dictionary content and bundled definitions are copyrighted by Bryan A. Garner. See NOTICE.

Releases

Release preparation is scripted:

./venv/bin/python scripts/release 1.1.0

See RELEASING.md for the release and distribution checklist.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

garner_dict-0.1.3.tar.gz (5.0 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

garner_dict-0.1.3-py3-none-any.whl (5.1 MB view details)

Uploaded Python 3

File details

Details for the file garner_dict-0.1.3.tar.gz.

File metadata

  • Download URL: garner_dict-0.1.3.tar.gz
  • Upload date:
  • Size: 5.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for garner_dict-0.1.3.tar.gz
Algorithm Hash digest
SHA256 d6cf4d95f02492582a823c2b566cad39342b760326e349f7ddd062606d3bd4ba
MD5 11a13aaab783236119f65c08cf06d960
BLAKE2b-256 9fd25224c56f3f7f8bd44c93574fccbbe47797685807d08e23ab722434519ad4

See more details on using hashes here.

File details

Details for the file garner_dict-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: garner_dict-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 5.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for garner_dict-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 33c6c8d20a40cc0dae191af956ddeac4b18fdc56acee8a408f0235f264e5c24a
MD5 cfbef21b35567db836cb99749d085d3b
BLAKE2b-256 9e8545a117668bc2bb77703a1391da8448d6c0f0c7dd3fc4102ac6c85f31f250

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page