wkdict: A CLI dictionary app in your terminal app

1 minute read

Published:

PyPI version Build Status GitHub stars GitHub forks GitHub issues GitHub license

Happy Chinese Spring Festival 2019! A new year gift for my beloved open-source community: a light-weight text-based dictionary application called, wkdict has just been released for this special occasion! This cross-platform program talks with Wiktionary’s API with the requested query(i.e. A single English word), and parses the returned JSON object in to a clean and readable format. The following snapshot gives you a taste of what this application looks like:

Install on Mac/Linux

Make sure you have the python3 installed on your machine, and use the following command to install wkdict

pip3 install wkdict

Usage

In terminal, run the application using

wkdict "word-you-wanna-lookup"

For example, wkdict love will give you the following result:

1) love	(UK, US) IPA: /lʌv/
   🏷  noun

	📗 Definitions
	☞ love (countable and uncountable, plural loves)
	☞ (uncountable) Strong affection.
	☞ (countable) A person who is the object of romantic feelings; a
	  darling, a sweetheart, a beloved.

	📘 Examples
	➡ A mother’s love is not easily shaken.
	➡ My husband’s love is the most important thing in my
	  life.
	➡ He on his side / Leaning half-raised, with looks of
	  cordial love / Hung over her enamoured.
...

Command options

Usage: wkdict [OPTIONS] WORD

Options:
  --limit INTEGER  Maximum number of entries/examples shown.  [default: 3]
  --version        Show the version and exit.
  --help           Show this message and exit.

Changelog

Curren app version(master branch) is 0.1.0.

Changes in current version:

  • Better formatting of dictionary entries
  • Add unicode support
  • Add test cases
  • Add Command-Line Options