cURL Art

This is a playful and unusual way to view the artwork from my Daily Generative Art project using cURL, a command-line program for reading data over the internet. The output of cURL Art is a cross between pixel and ASCII art, using the colors available to the particular terminal you run the command from.

Original image
cURL Art representations

Terminal primer

If you’re comfortable with running command-line code, you can skip this section.

cURL is a program that runs on the command-line. If you’re on macOS, you can use Terminal (Applications > Utilities > Terminal) or your terminal app of choice. On another OS you may need to install cURL before you can continue.

If you’ve never used a terminal app before: Don’t worry, it’s very simple. Nothing on this page is unsafe to run. When you first open your terminal you’ll probably see something similar to:

Last login: Wed Feb 13 16:41:42 on ttys000
Users-Computer:~ user$ |

From here, you’ll type out a command and then press return/enter. When you see a $ at the beginning of an example, that just means that the terminal prompt is ready for you to enter a command. You won’t type the $ yourself.

Last login: Wed Feb 13 16:41:42 on ttys000
Users-Computer:~ user$ |

Usage

The simplest command is:

$ curl "samiare.net/daily/190128"

This will find the image for that entry, 028_ 190128, and render it in text in your terminal with the default settings. You can replace 190128 with any date (in the form YYMMDD) for which an art piece has been posted.

Options

There are four options that can be appended to the URL to influence the output: width, height, colors and dither.

Multiple options can be chained together. The first option is always preceded by a question mark (?), and each subsequent one with an ampersand (&).

$ curl "samiare.net/daily/190128?width=20&dither=shade&colors=bw"

Tips & common issues

There is also a help url, if you want a reminder of the options and usage:

$ curl "samiare.net/daily/help"