Giter VIP home page Giter VIP logo

tmux-theme's Introduction

Add NerdFont icons to tmux window name

Icons window active red window active orange window zoomed window zoomed with icon after window zoomed with icon before window index

Features

  • hi-customize theme color
  • customize zoom sign
  • auto set icon based-on window name using regex
  • auto set background based-on session name using regex

Requirements

  • tpm for install and load plugin
  • Nerd font for display icons

Setup

  1. add below line to your tmux.conf with predefined icons for window name
set -g @plugin 'dtanphat9388/tmux-theme'
set -g @tmux-theme-window-icon "
 (z|ba)?sh|term
 n?vim|code|tmux|book.*
 book|man(ual)?|docs?|cheat
󱃾 kube.*|k8s|helm(file)?
 ai|copilot
"
  1. Reload tmux config with command tmux source-file.
  2. press <prefix>I to install and boooom
  3. If tmux theme not effect, relaunch tmux with command tmux kill-server
  4. Remove following redundance options if you have:
    • remove status-position option

Theme customize via options

set -g @plugin 'dtanphat9388/tmux-theme'
+set -g @tmux-theme-{option_name}
+ #...
option name default value desc
color-bg terminal transparent
color-active #17C3B2 color on active (ex: window, border)
color-inactive #686868 color on inactive (ex: window, border)
left-color-bg #FFFFFF
left-length 25 length of left section
right-color-bg #FFFFFF
right-length 50 length of right section
right-label #{host_short} length of right section
window-name-format #W length of right section
window-zoom-format [#W] length of right section
window-icon show icon by window name
border-color-active color-active
border-color-inactive color-inactive

Icons

Icons

  • icons will appear for window name match with regex
  • window name is case-insensitive
set -g @tmux-theme-window-icon "
 (z|ba)?sh|term
 n?vim|code|tmux|book.*
 book|man(ual)?|docs?|cheat
󱃾 kube.*|k8s|helm(file)?
 ai|copilot
"

Window and border color

  • set active color window active red window active orange
set -g @tmux-theme-color-active "red"

Window name and zoom format

  • default format [#W] window zoomed
  • use '' icon as zoom indicator '#W ' in after window zoomed with icon after
  • use '' icon as zoom indicator ' #W' in before window zoomed with icon before
  • use #I in window name to enable window index (ex: #I:#W ) window index
set -g @tmux-theme-window-name-format '#W'
set -g @tmux-theme-window-zoom-format '#W '

Well-know issues

  • icons is smaller because your font is mono font

tmux-theme's People

Contributors

dtanphat9388 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.