• Haskell 51.5%
  • HTML 43.6%
  • Nix 4.9%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2025-10-31 00:38:07 -04:00
app Add example for html-a11y 2025-03-26 20:27:19 -04:00
example Add a screen reader accessible HTML mode 2025-03-26 19:59:28 -04:00
.gitignore Add example info.json 2024-07-20 10:11:35 -04:00
default.nix Update to GHC 9.8 2025-10-31 00:38:07 -04:00
flake.lock Update to GHC 9.8 2025-10-31 00:38:07 -04:00
flake.nix Update to GHC 9.8 2025-10-31 00:38:07 -04:00
LICENSE Initial commit 2024-02-07 18:21:19 -05:00
package.nix Make colors cli args 2024-07-18 21:09:40 -04:00
README.md Add build instructions 2024-07-20 10:18:27 -04:00
sasha-fetch2.cabal Update to GHC 9.8 2025-10-31 00:38:07 -04:00
shell.nix Update to GHC 9.8 2025-10-31 00:32:30 -04:00

sasha-fetch2

This is a little tool I wrote to generate to fetch card on my website
and Gemini page and the curl-able terminal output viewable with
curl fetch.sashanoraa.gay. You can use it to create your own too!

This is a successor to my original sasha-fetch
script that I used to generate these.

Website

Screenshot of the fetch output on my website

Terminal

Screenshot of the fetch output in the terminal

Usage

Generate HTML

sasha-fetch2 html <colors> < info.json > out.html

Generate terminal fetch

sasha-fetch2 term <colors> <image> <image height> < info.json > out.txt

Generate plain

sasha-fetch2 plain < info.json > out.txt

Info

info.json contains the data in the fetch card. The file contains an array of line objects. Each
line must contain a "name" field, which is the text on the left side of line. Each line can also
have a "value" field, which is the text on the right side if the line. And optionally a "url" field
which will make the value a link in HTML that points to the provided URL.

See ./example/info.json for an example.

Colors

The html and term commands both have a color argument. This is actually four arguments which
are the left and right side colors of the names and values in the order:

  • name left color
  • name right color
  • value left color
  • value right color

Each color value is a color in HSL written as H,S,L ex. 324,91,47.

Building

Requirements:

  • GHC
  • Cabal

Build:

cabal build -O