Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/folke/splashcii

Simple cli tool that shows a random ascii art from https://www.asciiur.com/
https://github.com/folke/splashcii

ascii-art asciiur cli command-line doom-emacs nodejs

Last synced: 27 days ago
JSON representation

Simple cli tool that shows a random ascii art from https://www.asciiur.com/

Awesome Lists containing this project

README

        

# 🎨 Splashcii

Splashcii is a simple command-line tool that queries and displays a random ascii art from [Asciiur](https://www.asciiur.com/)

## Install

Use your favorite package manager to install `splashcii`

```shell
$ npm install -g splashcii
...

$ yarn global add splashcii
...

$ pnpm add -g splashcii
...
```

## Usage

```shell
$ splashcii halloween
.-.
(o o) boo!
| O \
\ \
`~~~'
```

Query results are cached, so they're only fetched once, the first time you search for a certain keyword.

## Doom Emacs Banner

Example to use a random **halloween** ascii-art for your doom banner. Make sure `splascii` is on your path.

![Doom Emacs](assets/doom-emacs.png)

```elisp
(defvar +fl/splashcii-query ""
"The query to search on asciiur.com")

(defun +fl/splashcii-banner ()
(mapc (lambda (line)
(insert (propertize (+doom-dashboard--center +doom-dashboard--width line)
'face 'doom-dashboard-banner) " ")
(insert "\n"))
(split-string (with-output-to-string
(call-process "splashcii" nil standard-output nil +fl/splashcii-query))
"\n" t)))

(setq +doom-dashboard-ascii-banner-fn #'+fl/splashcii-banner)

(setq +fl/splashcii-query "christmas")
```