to my shame i did not know how to customize the nmtui default colors (for the sake of my own health and mental stability). after reading a bit, i found out it uses the so-called newt backend with the whiptail app.

long story short… turns out it reads some of the env variables for that backend to setup the colors (if you’re interested, here’s where this happens in the code).

so you can simply set these env variables before calling nmtui. here’s a combination i came up with:

NEWT_COLORS='root=black,black;window=black,black;border=white,black;listbox=white,black;label=blue,black;checkbox=red,black;title=green,black;button=white,red;actsellistbox=white,red;actlistbox=white,gray;compactbutton=white,gray;actcheckbox=white,blue;entry=lightgray,black;textbox=blue,black' nmtui

enjoy and keep your eyes healthy!

  • ColdWater@lemmy.ca
    link
    fedilink
    arrow-up
    0
    ·
    4 months ago

    Luckily I don’t have to use nmtui all that much but this look nice, I might try it

    • xavier666@lemm.ee
      link
      fedilink
      English
      arrow-up
      0
      ·
      4 months ago

      It’s very useful for people who don’t use a desktop environment, such as TWM (tiling window manager) users. I use nmtui all the time.

      • JubilantJaguar@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        4 months ago

        Agreed. But for such a simple tool I find it so ugly and unintuitive that I ended up rolling my own 3-line script using nmcli and fzf that does exactly the same thing more logically and in less keystrokes.

        • xavier666@lemm.ee
          link
          fedilink
          English
          arrow-up
          0
          ·
          4 months ago

          I would be interested in seeing the script. I really need to learn fzf now.

          • JubilantJaguar@lemmy.world
            link
            fedilink
            arrow-up
            0
            ·
            4 months ago

            Sure.

            wn=$(nmcli dev wifi list | fzf)
            ssid="$(echo $wn | awk '{print $2}')"
            read -e -p "Password: " pw
            nmcli dev wifi connect "$ssid" password $pw