Wikit – Search Wikipedia on Linux Command Line
Wikit is a free and open-source command-line program for easily viewing Wikipedia summaries of search queries on the Linux command line; it is built using Nodejs.
The verb Wikit (derived from “wikipedia it“) means looking up something on wikipedia.org, the popular and remarkable open-source encyclopedia on the Internet.
To install Wikit on Linux systems, you must have nodejs and npm installed, if not install it using your default package manager as shown.
$ sudo apt install nodejs #Debian/Ubuntu $ sudo yum install nodejs npm #RHEL/CentOS $ sudo dnf install nodejs npm #Fedora 22+
Installing nodejs and npm from the default repositories will give you the little older version. Therefore, read our article to get a more recent version of nodejs and npm in Linux.
After installing the necessary dependencies, run the following command to install wikit in Linux (the -g
flag tells npm to install wikit globally).
$ sudo npm install wikit -g
Once Wikit is installed on your system, you can run it using the following syntax.
$ wikit Linux

The output shown is the paragraphs of the Wikipedia article before the table of contents and the line length is neatly wrapped based on your terminal’s window size, with a max of about 80 characters.
If you are running wikit on a desktop computer with a web browser installed, you can open the full Wikipedia article in a browser using the -b
flag as below.
$ wikit linux -b
To define the line wrap length to number (minimum 15), use the -l
option as shown.
$ wikit linux --line 90

For more information, go to the Wikit Github repository.
Lastly, do check out these fancy command line-based tools for various tasks.
You can use the comment form below to ask any questions or share any useful thoughts with us.