Lynx Colors

Lynx Colors

Change Lynx ui colors

I have been using Lynx for a good long while and there was always a minor annoyance. The colors. I never thought to investigate how to change the colors…until today.

Turns out that it is a pretty simple gadget. Lynx.lss can be found in /etc and this is where all the colors can be changed. Maybe you are logged into a remote server, if so you'll need to copy that file into your $HOME directory.

cp /etc/lynx.lss $HOME/

After that there are two ways to make Lynx use that file;

The $LYNXLSS environment variable

export LYNX_LSS="$HOME/lynx.lss"

can be added to your [shell]rc file, in my case .bashrc like so

echo "export LYNX_LSS=\"$HOME/lynx.lss\"" >> $HOME/.bashrc

which appends to the end of .bashrc or you could use the -lss command line flag like so:

lynx -lss=~/lynx.lss

But, since I am a $HOME prude, I like to drop these sorts of things into my $HOME/.config and that looks like this:

mkdir -p ~/.config/lynx && cp /etc/lynx.lss ~/.config/lynx
echo "export LYNX_LSS=\"$HOME/.config/lynx/lynx.lss\"" >> $HOME/.bashrc

And, that works for me.

tags: bash lynx cli

Author: snubspreker

Created: 2020-05-28 Thu 12:21

Validate