Wiki CLI is a command line Wikipedia viewer and saver.
Installation#
Manually on Linux and macOS#
You can download Wiki CLI on Linux:
curl -LO https://github.com/betapictoris/wiki/releases/latest/download/wiki
On macOS you can download the binary with:
curl -L https://github.com/betapictoris/wiki/releases/latest/download/wiki-darwin -o wiki
Then you can install the binary to a location in your PATH
:
# For a global system installation
sudo install -Dt /usr/local/bin -m 755 wiki
# For a user installation
install -Dt ~/.local/bin -m 755 ./wiki
Make sure that your system uses these locations if you have problems accessing the wiki
command from PATH
.
Debian (using apt
)#
You can download the .deb
file on Debian using curl
:
curl -LO https://github.com/betapictoris/wiki/releases/latest/download/wiki.deb
Then you can install using apt
:
sudo apt install ./wiki.deb
Windows#
Download wiki.exe
from the GitHub releases page and store it in a location in your PATH
.
Compiling#
To compile Wiki CLI you’ll need Go 1.19 or higher installed. Afterwards you can clone the repository using git
:
git clone github.com/betapictoris/wiki
cd ./wiki/
Then you can build the application:
go build ./main.go
A wiki
or wiki.exe
file will be created you can then install the binary like usual.
Usage#
You can view Wikipedia articles by running the following command:
wiki [name of article]
You can save the articles as a markdown file by running the following command:
wiki -s [name of article]