jimeh / tmux-themepack

A pack of various Tmux themes.
1.67k stars 203 forks source link

Adding Ram Available #40

Closed sauljabin closed 2 years ago

sauljabin commented 4 years ago

Hello team, thanks for this plugin, i'm using it and it's so useful.

I would like to add the available ram, how can I do this?

jimeh commented 4 years ago

Hi @sauljabin, most of the themes offer a number of overridable options you can use to add additional things to the status bar. Most themes have the same set of options available right now, but they might diverge in the future, so it's typically a good idea to look at the variables available in the specific theme.

For example, the powerline/default/green theme's customizable options can be seen here.

So for example, if you wanted to add some text to the left side of the session name, you would add this to your Tmux config before you load the theme:

set -g @themepack-status-left-area-left-prefix "session: "

All those options are rendered into the status-left and status-right options, so for details on how it's formatting works, check out the Tmux documentation for status-left.

As an example, if you want to display the line of STDOUT from an external command, like for example displaying system uptime with uptime, that can be done with like so:

set -g @themepack-status-right-area-left-prefix "#(uptime) "
sauljabin commented 4 years ago

Thanks @jimeh