~zethra/term2alpha

Create neovim alpha headers from terminal output
Don't output blank lines
Remove unused files
Add link to catimg in README

clone

read-only
https://git.sr.ht/~zethra/term2alpha
read/write
git@git.sr.ht:~zethra/term2alpha

You can also use your local clone with git send-email.

#term2alpha

This is a program to create headers for Alpha, the Neovim greeter from the ANSI colored output of other terminal commands. Namely, catimg, a program for rendering images in the terminal.

Example, my alpha header

#Example Usage

How I created the above example.

Generate the alpha header with the following command using catimg:

catimg -H 30 pfp.png | term2alpha > header.lua

The -H flag from catimg controls the height of it's output. term2alpha does not do any resizing, so make sure the terminal output you're feeding into it is the desired size.

The in your Neovim config, require the generated header.lua and set that as one of the sections in your alpha config:

local dashboard = require('alpha.themes.dashboard')
dashboard.config.layout[2] = require('header')
require('alpha').setup(dashboard.config)

#Limitations

term2alpha has only been tested on catimg output at this time and may not work correctly on other terminal output. As of now, it only supports 24bit color codes, and ignores other ANSI control sequences.