show-waifu

A command-line app using the Safebooru + Danbooru API to show anime fanart in your terminal.

Using the CLI app to show an anime girl in a terminal

Installation

Download show-waifu-1.0.0.tar.gz from releases and extract it using either a GUI or the command line.

If you're using the command line run

sh tar -xf show-waifu-1.0.0.tar.gz

Move the show-waifu executable into your bin

```sh

If ~/bin doesn't exist, create it using the following

mkdir -p ~/bin mv show-waifu ~/bin ```

Test it to see if it works, it should output an image in your terminal

sh ~/bin/show-waifu

To make show-waifu available everywhere on the command line, add ~/bin to $PATH and reload the Bash configuration

sh echo 'export PATH=~/bin:$PATH' >> ~/.bash_profile source ~/.bash_profile

Test it again and if it works, you're all set to use it!

sh show-waifu

Safebooru vs Danbooru

Safebooru Danbooru
Safe for work Fairly safe Not really safe
Searching
  • Basic amount of options
  • Has no tag limit
  • Large variety of options
  • Has a tag limit depending on level
Image details
  • Link
  • Rating
  • Dimensions
  • Tags
  • Character
  • Source
  • Artist
  • Link
  • Rating
  • Dimensions
  • Tags

More details can be found below

Searching: Safebooru's cheatsheet + Danbooru's cheatsheet

Image ratings: Safebooru's image ratings + Danbooru's image ratings

Danbooru Authentication

For Anonymous and Member-level users, authentication provides no benefits.

Depending on your account level, authenticating comes with some benefits: an increased tag limit and a longer search timemout length. You can authenticate by doing the following:

Example usage

Read from stdin and show an image

sh curl -s https://pbs.twimg.com/media/DoWo3unU4AA2etL\?format\=jpg\&name\=large | show-waifu

Search for a specific image on Safebooru based on tags, and print details

sh show-waifu safe --details --tags="ncr_veteran_ranger night~"

Use a local file and change its height for viewing

sh show-waifu --height 10 file ~/Pictures/doge.jpg

Command line options

``` USAGE: show-waifu [OPTIONS] [SUBCOMMAND]

FLAGS: --help Prints help information -V, --version Prints version information

OPTIONS: -h, --height Resize the image to a provided height -w, --width Resize the image to a provided width

SUBCOMMANDS: dan Look at random images from Danbooru file View an image from your file system help Prints this message or the help of the given subcommand(s) safe Look at random images from Safebooru url View an image from a url ```

dan (subcommand)

``` USAGE: show-waifu dan [FLAGS] [OPTIONS]

FLAGS: -d, --details Show data related to image (artist, source, character, url, rating, dimensions, tags) -e, --explicit Only display images with explicit sexual content -h, --help Prints help information -q, --questionable Only display images with some nox-explicit nudity or sexual content -s, --safe Only display images lacking sexual content. Includes lingerie, swimsuits, innocent romance, etc. NOTE: this doesn't mean "safe for work." -V, --version Prints version information

OPTIONS: -k, --key Pass your Danbooru API key for authentication. NOTE: This doesn't set a persistent environmental variable and instead only works for one session -t, --tags Search for an image based on Danbooru tags. Pass as a string separated by spaces or commas. Look at Danbooru's cheatsheet for a full list of search options -u, --username Pass your Danbooru username for authentication. NOTE: This doesn't set a persistent environmental variable and instead only works for one session ```

safe (subcommand)

``` USAGE: show-waifu safe [FLAGS] [OPTIONS]

FLAGS: -d, --details Show data related to image (url, rating, dimensions, tags) -h, --help Prints help information -q, --questionable Only display images with suggestive content -V, --version Prints version information

OPTIONS: -t, --tags Search for an image based on Safebooru tags. Pass as a string separated by spaces or commas. Look at Safebooru's cheatsheet for a full list of search options ```