Skip to repository content

tenant.openagents/omega

No repository description is available.

OpenAgents Git authority 2026-07-28T06:18:25.483Z Public web read
NIP-34 coordinate30617:7649603503856e5148d571eac2766b288a8ff1e9e35d380337a1d2b0015b4f92:omega
MaintainersHidden in public view
References2 branches · 1 tag
Read-only clonegit clone https://openagents.com/git/tenant.openagents/omega.git
Browse files

truecolor.sh

20 lines · 749 B · shellscript
1#!/usr/bin/env bash
2# Copied from: https://unix.stackexchange.com/a/696756
3# Based on: https://gist.github.com/XVilka/8346728 and https://unix.stackexchange.com/a/404415/395213
4
5awk -v term_cols="${width:-$(tput cols || echo 80)}" -v term_lines="${height:-1}" 'BEGIN{
6    s="/\\";
7    total_cols=term_cols*term_lines;
8    for (colnum = 0; colnum<total_cols; colnum++) {
9        r = 255-(colnum*255/total_cols);
10        g = (colnum*510/total_cols);
11        b = (colnum*255/total_cols);
12        if (g>255) g = 510-g;
13        printf "\033[48;2;%d;%d;%dm", r,g,b;
14        printf "\033[38;2;%d;%d;%dm", 255-r,255-g,255-b;
15        printf "%s\033[0m", substr(s,colnum%2+1,1);
16        if (colnum%term_cols==term_cols) printf "\n";
17    }
18    printf "\n";
19}'
20
Served at tenant.openagents/omega Member data and write actions are omitted.