Code Monkey home page Code Monkey logo

.tmux's Introduction

.tmux

Self-contained, pretty and versatile .tmux.conf configuration file.

Screenshot

Installation

Requirements:

  • tmux >= 2.6 running inside Linux, Mac, OpenBSD, Cygwin or WSL
  • awk, perl and sed
  • outside of tmux, $TERM must be set to xterm-256color

⚠️ Before installing, you may want to backup your existing configuration.

You can install Oh my tmux! at any of the following locations:

  • ~
  • $XDG_CONFIG_HOME/tmux
  • ~/.config/tmux

Installing in ~:

$ cd
$ git clone https://github.com/gpakosz/.tmux.git
$ ln -s -f .tmux/.tmux.conf
$ cp .tmux/.tmux.conf.local .

Installing in $XDG_CONFIG_HOME/tmux:

$ git clone https://github.com/gpakosz/.tmux.git "/path/to/oh-my-tmux"
$ mkdir -p "$XDG_CONFIG_HOME/tmux"
$ ln -s "/path/to/oh-my-tmux/.tmux.conf" "$XDG_CONFIG_HOME/tmux/tmux.conf"
$ cp "/path/to/oh-my-tmux/.tmux.conf.local" "$XDG_CONFIG_HOME/tmux/tmux.conf.local"

Installing in ~/.config/tmux:

$ git clone https://github.com/gpakosz/.tmux.git "/path/to/oh-my-tmux"
$ mkdir -p "~/.config/tmux"
$ ln -s "/path/to/oh-my-tmux/.tmux.conf" "~/.config/tmux/tmux.conf"
$ cp "/path/to/oh-my-tmux/.tmux.conf.local" "~/.config/tmux/tmux.conf.local"

⚠️ When installing $XDG_CONFIG_HOME/tmux or ~/.config/tmux, the configuration file names don't have a leading . character.

❗️ You should never alter the main .tmux.conf or tmux.conf file. If you do, you're on your own. Instead, every customization should happen in your .tmux.conf.local or tmux.conf.local customization file copy.

If you're a Vim user, setting the $EDITOR environment variable to vim will enable and further customize the vi-style key bindings (see tmux manual).

If you're new to tmux, I recommend you to read tmux 2: Productive Mouse-Free Development by @bphogan.

Now proceed to adjust your .local customization file copy.

Troubleshooting

  • I'm running tmux HEAD and things don't work properly. What should I do?

    Please open an issue describing what doesn't work with upcoming tmux. I'll do my best to address it.

  • Status line is broken and/or gets duplicated at the bottom of the screen. What gives?

    This particularly happens on Linux when the distribution provides a version of glib that received Unicode 9.0 upgrades (glib >= 2.50.1) while providing a version of glibc that didn't (glibc < 2.26). You may also configure LC_CTYPE to use an UTF-8 locale. Typically VTE based terminal emulators rely on glib's g_unichar_iswide() function while tmux relies on glibc's wcwidth() function. When these two functions disagree, display gets messed up.

    This can also happen on macOS when using iTerm2 and "Use Unicode version 9 character widths" is enabled in Preferences... > Profiles > Text

    For that reason, the default sample .local customization file stopped using Unicode characters for which width changed in between Unicode 8.0 and 9.0 standards, as well as Emojis.

  • I installed Powerline and/or (patched) fonts but can't see Powerline symbols.

    First, you don't need to install Powerline. You only need fonts patched with Powerline symbols or the standalone PowerlineSymbols.otf font. Then make sure your .local customization file copy uses the Powerline code points for tmux_conf_theme_left_separator_XXX values.

  • I'm using Bash On Windows (WSL), colors and the Powerline look are broken.

    There is currently a bug in the new console powering Bash On Windows preventing text attributes (bold, underscore, ...) to combine properly with colors. The workaround is to search your .local customization file copy and replace attributes with 'none'.

    Also, until Window's console replaces its GDI based render with a DirectWrite one, Powerline symbols will be broken.

    The alternative is to use the Mintty terminal for WSL.

Features

  • C-a acts as secondary prefix, while keeping default C-b prefix
  • visual theme inspired by Powerline
  • maximize any pane to a new window with <prefix> +
  • SSH/Mosh aware username and hostname status line information
  • mouse mode toggle with <prefix> m
  • laptop battery status line information
  • uptime status line information
  • optional highlight of focused pane
  • configurable new windows and panes behavior (optionally retain current path)
  • SSH/Mosh aware split pane (reconnects to remote server)
  • copy to OS clipboard (needs xsel, xclip, or wl-copy on Linux)
  • support for 4-digit hexadecimal Unicode characters
  • Facebook PathPicker integration if available
  • Urlscan (preferred) or Urlview integration if available

The "maximize any pane to a new window with <prefix> +" feature is different from builtin resize-pane -Z as it allows you to further split a maximized pane. It's also more flexible by allowing you to maximize a pane to a new window, then change window, then go back and the pane is still in maximized state in its own window. You can then minimize a pane by using <prefix> + either from the source window or the maximized window.

Maximize pane

Mouse mode allows you to set the active window, set the active pane, resize panes and automatically switches to copy-mode to select text.

Mouse mode

Bindings

tmux may be controlled from an attached client by using a key combination of a prefix key, followed by a command key. This configuration uses C-a as a secondary prefix while keeping C-b as the default prefix. In the following list of key bindings:

  • <prefix> means you have to either hit Ctrl + a or Ctrl + b
  • <prefix> c means you have to hit Ctrl + a or Ctrl + b followed by c
  • <prefix> C-c means you have to hit Ctrl + a or Ctrl + b followed by Ctrl + c

This configuration uses the following bindings:

  • <prefix> e opens the .local customization file copy with the editor defined by the $EDITOR environment variable (defaults to vim when empty)

  • <prefix> r reloads the configuration

  • C-l clears both the screen and the tmux history

  • <prefix> C-c creates a new session

  • <prefix> C-f lets you switch to another session by name

  • <prefix> C-h and <prefix> C-l let you navigate windows (default <prefix> n and <prefix> p are unbound)

  • <prefix> Tab brings you to the last active window

  • <prefix> - splits the current pane vertically

  • <prefix> _ splits the current pane horizontally

  • <prefix> h, <prefix> j, <prefix> k and <prefix> l let you navigate panes ala Vim

  • <prefix> H, <prefix> J, <prefix> K, <prefix> L let you resize panes

  • <prefix> < and <prefix> > let you swap panes

  • <prefix> + maximizes the current pane to a new window

  • <prefix> m toggles mouse mode on or off

  • <prefix> U launches Urlscan (preferred) or Urlview, if available

  • <prefix> F launches Facebook PathPicker, if available

  • <prefix> Enter enters copy-mode

  • <prefix> b lists the paste-buffers

  • <prefix> p pastes from the top paste-buffer

  • <prefix> P lets you choose the paste-buffer to paste from

Additionally, copy-mode-vi matches my own Vim configuration

Bindings for copy-mode-vi:

  • v begins selection / visual mode
  • C-v toggles between blockwise visual mode and visual mode
  • H jumps to the start of line
  • L jumps to the end of line
  • y copies the selection to the top paste-buffer
  • Escape cancels the current operation

Configuration

While this configuration tries to bring sane default settings, you may want to customize it further to your needs.

❗️ Again, you should never alter the main .tmux.conf or tmux.conf file. If you do, you're on your own.

Please refer to the sample .local customization file to know more about the variables that allow you to alter different behaviors. Upon successful installation, pressing <prefix> e will open your .local customization file copy with the editor defined by the $EDITOR environment variable (defaults to vim when empty).

Enabling the Powerline look

Powerline originated as a status-line plugin for Vim. Its popular eye-catching look is based on the use of special symbols: Powerline Symbols

To make use of these symbols, there are several options:

Then edit your .local customization file copy (with <prefix> e) and adjust the following variables:

tmux_conf_theme_left_separator_main='\uE0B0'
tmux_conf_theme_left_separator_sub='\uE0B1'
tmux_conf_theme_right_separator_main='\uE0B2'
tmux_conf_theme_right_separator_sub='\uE0B3'

The Powerline manual contains further details on how to install fonts containing the Powerline symbols. You don't need to install Powerline itself though.

Configuring the status line

Edit your .local customization file copy (<prefix> e) and adjust the tmux_conf_theme_status_left and tmux_conf_theme_status_right variables to your own preferences.

This configuration supports the following builtin variables:

  • #{battery_bar}: horizontal battery charge bar
  • #{battery_hbar}: 1 character wide, horizontal battery charge bar
  • #{battery_vbar}: 1 character wide, vertical battery charge bar
  • #{battery_percentage}: battery percentage
  • #{battery_status}: is battery charging or discharging?
  • #{circled_session_name}: circled session number, up to 20
  • #{hostname}: SSH/Mosh aware hostname information
  • #{hostname_ssh}: SSH/Mosh aware hostname information, blank when not connected to a remote server through SSH/Mosh
  • #{loadavg}: load average
  • #{pairing}: is session attached to more than one client?
  • #{prefix}: is prefix being depressed?
  • #{root}: is current user root?
  • #{synchronized}: are the panes synchronized?
  • #{uptime_y}: uptime years
  • #{uptime_d}: uptime days, modulo 365 when #{uptime_y} is used
  • #{uptime_h}: uptime hours
  • #{uptime_m}: uptime minutes
  • #{uptime_s}: uptime seconds
  • #{username}: SSH/Mosh aware username information
  • #{username_ssh}: SSH aware username information, blank when not connected to a remote server through SSH/Mosh

Beside the variables mentioned above, the tmux_conf_theme_status_left and tmux_conf_theme_status_right variables support usual tmux syntax, e.g. using #() to call an external command that inserts weather information provided by wttr.in:

tmux_conf_theme_status_right='#{prefix}#{pairing}#{synchronized} #(curl -m 1 wttr.in?format=3 2>/dev/null; sleep 900) , %R , %d %b | #{username}#{root} | #{hostname} '

The sleep 900 call makes sure the network request is issued at most every 15 minutes whatever the value of status-interval.

Weather information from wttr.in

💡 You can also define your own custom variables by writing special functions, see the sample .local customization file for instructions.

Finally, remember tmux_conf_theme_status_left and tmux_conf_theme_status_right end up being given to tmux as status-left and status-right which means they're passed through strftime(). As such, the % character has a special meaning and needs to be escaped by doubling it, e.g.

tmux_conf_theme_status_right='#(echo foo %% bar)'

See also man 3 strftime.

Using TPM plugins

This configuration now comes with built-in TPM support:

  • use the set -g @plugin ... syntax to enable a plugin
  • whenever a plugin introduces a variable to be used in status-left or status-right, you can use it in tmux_conf_theme_status_left and tmux_conf_theme_status_right variables, see instructions above 👆
  • ⚠️ do not add set -g @plugin 'tmux-plugins/tpm' to any configuration file
  • ⛔️ do not add run '~/.tmux/plugins/tpm/tpm' to any configuration file

⚠️ The TPM bindings differ slightly from upstream:

  • installing plugins: <prefix> + I
  • uninstalling plugins: <prefix> + Alt + u
  • updating plugins: <prefix> + u

See the sample .local customization file for instructions.

Using the configuration under Cygwin within Mintty

I don't recommend running this configuration with Cygwin anymore. Forking under Cygwin is extremely slow and this configuration issues a lot of run-shell commands under the hood. As such, you will experience high CPU usage. As an alternative consider using Mintty terminal for WSL.

cygwin

It is possible to use this configuration under Cygwin within Mintty, however support for Unicode symbols and emojis lacks behind Mac and Linux.

Particularly, Mintty's text rendering is implemented with GDI which has limitations:

  • color emojis are only available through DirectWrite starting with Windows 8.1
  • display of double width symbols, like the battery discharging symbol indicator (U+1F50B) is buggy

To get Unicode symbols displayed properly, you have to use font linking. Open regedit.exe then navigate to the registry key at HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink and add a new entry for you preferred font to link it with the Segoe UI Symbol font.

regedit

.tmux's People

Contributors

alanoliveira avatar arttaylor avatar asuza avatar ciceropablo avatar divok avatar frederick888 avatar gpakosz avatar luisdavim avatar mattysweeps avatar nmahoney avatar pianojockl avatar sarumont avatar ytang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

.tmux's Issues

Using tab on vim with autocomplete plugin runs weird

When I use tab to scroll through autocomplete options and try to select them it does not work correctly. I have noticed at the bottom right I can "^I" so I am assuming for some reason it is trying to use call C-i .

Note: I am using neovim. It seems that setting setw -g mode-keys vi will give me the correct selection, but there is still the lag time as it tries to process ^I then uses tab.

Thank you for your great tmux config.

Unable to get powerline fonts working in tmux

I've uncommented

tmux_conf_theme=powerline_patched_font

Reloaded my tmux conf

Downloaded and installed my powerline patched fonts of choice from here:
https://github.com/Lokaltog/powerline-fonts

I've set the fonts in iterm2 to use the new font (for regular and on-ascii)

Yet I'm seeing '?' characters instead of powerline symbols.

Sorry if this isn't the appropriate place to ask this, but have I missed something?

image

Thanks.
-Seth

Tips for getting maximize_pane to work with Tmux 1.9

This is more of a tip than an issue. Also I haven't tried your config yet, but thought you might find this info useful.

Basically, since v1.8 Tmux has supported a native pane maximizing (changelog). Personally I didn't notice until v1.9 was released, as it's tucked away within the resize-pane command. Specifically resize-pane -Z will toggle the current pane between normal state and maximized/zoomed state.

So my suggestion is, update your maximize_pane function to just call tmux resize-pane -Z if the current Tmux version is 1.8 or later.

As performing version comparisons in bash so you can determine if it's 1.8 or later, I've had that same issue myself, and here's the solution I came to:
https://github.com/jimeh/tmuxifier/blob/master/libexec/tmuxifier-tmux-version

And here's an example of using it:
https://github.com/jimeh/tmuxifier/blob/33f26bca564329fad094f25a8d38af042b85dadc/lib/layout-helpers.sh#L236-L255

Got these errors after installing it today.

It's working fine! but when I source the config file I get this:

❯ . ~/.tmux.conf
/Users/mz/.tmux.conf:8: command not found: setw
/Users/mz/.tmux.conf:14: command not found: bind
/Users/mz/.tmux.conf:19: command not found: bind
/Users/mz/.tmux.conf:22: command not found: bind
/Users/mz/.tmux.conf:534: parse error near `\n'

Unable to toggle mouse mode

I use <prefix>M to try to toggle mouse mode. Unfortunately, this is what I got

'cut -c3- ~/.tmux.conf | sh -s toggle_mouse' returned 1

And mouse mode was not triggered.

I am on OSX 10.10.5 and have zsh

Weird terminal behavior

Hi, would you know what could be cause of the behavior as shown in the screenshot?

I have used tmux for years but I moved to your config and suddenly it started behaving... awkwardly as you can see, with double/tripple status bar etc.
2017-01-30-102306_1920x1080_scrot

I am using latest Ubuntu 16.10 with latest bash, tmux 2.2 and latest code of gpakosz/.tmux

Adding custom status elements

Is it possible to add custom status elements without overriding .tmux.conf — i.e. inside the .tmux.conf.local?

Case in point, I’d like to add dickeyxxx/tmux-spotify-info. If I’m reading the .tmux.conf correctly this isn’t currently possible. Could this maybe be added?

Here’s a quick’n’dirty example of an implementation. The delimiters are a bit tricky so I left them out for now:

diff --git a/.tmux.conf b/.tmux.conf
index 3abdffb..8884bd5 100644
--- a/.tmux.conf
+++ b/.tmux.conf
@@ -211,6 +211,10 @@ run 'cut -c3- ~/.tmux.conf | sh -s apply_configuration'
 #       tmux_conf_theme_mode_attr=${tmux_conf_theme_mode_attr:-bold}
 #       tmux setw -g mode-style fg=$tmux_conf_theme_mode_fg,bg=$tmux_conf_theme_mode_bg,$tmux_conf_theme_mode_attr
 #
+#       # extra status lines
+#       tmux_conf_extra_left=${tmux_conf_extra_left:-}
+#       tmux_conf_extra_right=${tmux_conf_extra_right:-}
+#
 #       # status line
 #       tmux_conf_theme_status_fg=${tmux_conf_theme_status_fg:-colour253} # white
 #       tmux_conf_theme_status_bg=${tmux_conf_theme_status_bg:-colour232} # dark gray
@@ -218,7 +222,7 @@ run 'cut -c3- ~/.tmux.conf | sh -s apply_configuration'
 #
 #       tmux_conf_theme_session_fg=${tmux_conf_theme_session_fg:-colour16}  # black
 #       tmux_conf_theme_session_bg=${tmux_conf_theme_session_bg:-colour226} # yellow
-#       status_left="#[fg=$tmux_conf_theme_session_fg,bg=$tmux_conf_theme_session_bg,bold] ❐ #S #[fg=$tmux_conf_theme_session_bg,bg=$tmux_conf_theme_status_bg,nobold]$left_separator_black"
+#       status_left="#[fg=$tmux_conf_theme_session_fg,bg=$tmux_conf_theme_session_bg,bold] ❐ #S #[fg=$tmux_conf_theme_session_bg,bg=$tmux_conf_theme_status_bg,nobold]$left_separator_black$tmux_conf_extra_left"
 #       if [ x"`tmux -q -L tmux_theme_status_left_test -f /dev/null new-session -d \; show -g -v status-left \; kill-session`" = x"[#S] " ] ; then
 #         status_left="$status_left "
 #       fi
@@ -303,7 +307,7 @@ run 'cut -c3- ~/.tmux.conf | sh -s apply_configuration'
 #         status_right_hostname="#[fg=$tmux_conf_theme_hostname_bg,nobold]${status_right_hostname}$right_separator_black#[fg=$tmux_conf_theme_hostname_fg,bg=$tmux_conf_theme_hostname_bg,bold] #h "
 #       fi
 #
-#       status_right="${status_right_prefix}${status_right_battery}${status_right_time}${status_right_date}${status_right_username}${status_right_hostname}"
+#       status_right="${status_right_prefix}${tmux_conf_extra_right}${status_right_battery}${status_right_time}${status_right_date}${status_right_username}${status_right_hostname}"
 #       tmux set -g status-right-length 64 \; set -g status-right "$status_right"
 #
 #       # clock

With this, I can just add the following line to my .tmux.conf.local:

tmux_conf_extra_right='#(~/.tmux/tmux-spotify-info)'

Ideally this would be an array and .tmux.conf would add the necessary delimiters.

screenshot can't open

why not add the screenshot to the readme.md ,and it would be better with the url
thank you!

Patched symbols not showing

I'm aware this is an annoying and perhaps minor issue, but I've been googling for multiple hours now without a solution.

Here is what's wrong: The symbols, that if I understood correctly are introduced when patching a font, are not displaying for me. Others, however, work without problem, such as the battery symbol. Please have a look at the screenshot to see what I mean.

https://s9.postimg.org/ki2d54szz/powerline_issue.png

I checked font settings and encoding settings (UTF-8) in iTerm2 (which I'm mainly using). I also tried different patched fonts, including Source Code and Meslo, both show the same behavior. I checked locale, which for some reason is empty but I haven't been able to define it permanently. Don't know if that's important. I'm sure I've tried other things but forgot about it since they also didn't fix the problem.

Any what it could be or how to narrow the source down? I didn't run into this issue with the tmux-powerline repository maintained by erikw, which is why I suspect it's the config, but I don't know enough about it to be sure.

Problem with Powerline Theme

First off, this may be a font issue rather than a tmux configuration issue and if so, I apologize for wasting your time.

Now, onto the actual problem. When using the Hack font (http://github.com/chrissimpkins/Hack) with your theme, the left separator doesn't want to display even though the font supports the left separator. I've included screenshots of what it looks like in the tmux theme and with the font supporting the character via echoing it to the terminal window.

screenshot 2016-02-19 13 47 45

screenshot 2016-02-19 13 48 08

Let me know if you have any other steps I should do to troubleshoot this.

Thanks!

“run '~/.tmux/plugins/tpm/tpm'” has no effect in .tmux.conf.local

# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-resurrect'
#
# # Other examples:
# # set -g @plugin 'github_username/plugin_name'
# # set -g @plugin '[email protected]/user/plugin'
# # set -g @plugin '[email protected]/user/plugin'
#
# # Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'

This was the code I added to .tmux.conf.local at the bottom. But it seems that tpm could't run as I expected.

When I added the code to .tmux.conf and reloaded the configuration,the error below was throwed:

'cut -c3- ~/.tmux.conf | sh -s _apply_configuration' returned 127

But the strange thing was that I could use plugin of tmux normally this time. Spliting new pane would also throw the error.

How could I fix the error ? Any suggestion would be appreciated.

tmux as shell

When you run tmux as the shell in a terminal emulator, i.e. without running bash/zsh/etc first, the status line doesn't get changed from the default one. Is this expected behavior or is there a way to still apply your script?

copy mode doesn't work

I was able to go to copy mode but the vim binding doesn't seem to work. I tried pressing 'v' in copy mode but it won't highlight the parts i want to copy. Also the top right box is stuck at 0/0.

Cannot set pane border

I added following lines in ~/.tmux.conf.local to change border color, but it does not take effect, am I missing anything?

set -g pane-border-fg green
set -g pane-border-bg black
set -g pane-active-border-fg white
set -g pane-active-border-bg yellow

iTerm2 compatibility

Hello guys

I am having some issues running .tmux on iterm2 Build 3.0.12

I have random duplicate status bar like shown in this screen shot attached here

It works perfectly with native Term app though

screen shot 2016-11-20 at 9 43 41 am

Add support to pin battery

Some of us have multiple batteries in our laptops. Would be great to be able to pin battery id, or the conf dynamically show level for all combined.

Powerline is not working!

I have installed powerline and powerline fonts. I use Agnoster theme for Oh-My-Zsh. It works fine. But in tmux I am not able to use powerline. I installed your configuration in tmux 2.3 and I getting different output.

This is my output.

Output

I run in Ubuntu Gnome 16.04.

unable to override some colors in the theme

Some of the colours like the tmux_conf_theme_username_bg, for example, can't be overwritten using the tmux.conf.local file.

this fixes the issue:

diff --git a/.tmux.conf b/.tmux.conf
index cd1830a..e6ba423 100644
--- a/.tmux.conf
+++ b/.tmux.conf
@@ -267,13 +267,13 @@ run 'cut -c3- ~/.tmux.conf | sh -s apply_configuration'
 #       tmux_conf_theme_prefix_bg=${tmux_conf_theme_prefix_bg:-colour16}        # black
 #       tmux_conf_theme_time_date_fg=${tmux_conf_theme_time_date_fg:-colour247} # light gray
 #       tmux_conf_theme_time_date_bg=${tmux_conf_theme_time_date_bg:-colour232} # dark gray
-#       tmux_conf_theme_username_fg=colour254                                   # white
-#       tmux_conf_theme_username_bg=colour160                                   # red
-#       tmux_conf_theme_hostname_fg=colour16                                    # black
-#       tmux_conf_theme_hostname_bg=colour254                                   # white
+#       tmux_conf_theme_username_fg=${tmux_conf_theme_username_fg:-colour254}   # white
+#       tmux_conf_theme_username_bg=${tmux_conf_theme_username_bg:-colour160}   # red
+#       tmux_conf_theme_hostname_fg=${tmux_conf_theme_hostname_fg:-colour16}    # black
+#       tmux_conf_theme_hostname_bg=${tmux_conf_theme_hostname_bg:-colour254}   # white
 #
 #       if [ x"$prefix_enabled" = x"true" ] ; then
-#         status_right_prefix="#{?client_prefix,#[fg=$tmux_conf_theme_prefix_fg]#[bg=$tmux_conf_theme_prefix_bg]#[bold]⌨ #[fg=$tmux_conf_theme_prefix_fg]#[bg=$tmux_conf_theme_status_bg]#[nobold],}"
+#         status_right_prefix="#{?client_prefix,#[fg=$tmux_conf_theme_prefix_fg]#[bg=$tmux_conf_theme_prefix_bg]#[bold]⌨  #[fg=$tmux_conf_theme_prefix_fg]#[bg=$tmux_conf_theme_status_bg]#[nobold],}"
 #       fi
 #       if [ x"$battery_enabled" = x"true" ] ; then
 #         status_right_battery="${tmux_conf_battery:-#(cut -c3- ~/.tmux.conf | sh -s battery ${tmux_conf_battery_style:-bar} ${tmux_conf_battery_symbol:-block} ${tmux_conf_battery_symbol_count:-auto} \"${tmux_conf_battery_palette:-colour160,colour254,colour16}\" ${tmux_conf_battery_status:-enabled})} "

_apply_theme problem?

Hey there,

Was wondering if you could help me. When I use the package I end up having an issue where the statusline disappears sometimes and other times it stacks on itself after a few seconds (so I have multiple status lines covering the bottom part of my screen. I've isolated the issue to within the _apply_theme but am not sure how to move forward since I'm not even sure what's happening. It's probably related to status line but I think there might also be issues with just the encoding and all that

High CPU consumption usage

When running tmux v2.2 with this .tmux configuration under MSYS2,
CPU usage goes russian mountains, with big spikes attributed to a system process.

This doesn't happen when running tmux without this .tmux.conf .

I suspect an issue with some system call such as battery level.

why it?

hi, i do this:

  • 1, install the tmux sudo apt-get install tmux
    • and it is tmux2.0
  • 2, install powerline pip install powerline-status and sudo apt-get install powerline
  • 3, install your config just like readme 1, 2, 3, 4
  • 4, I change some config as readme
  • then I restart terminal and turn into tmux but it does not work at all, just like the original tmux
  • and Why?
  • anyway, Thx!

maximize pane to center of screen

Hi,

I was reading your post about the maximize pane to a new window and it seems to come close to something im interested in. I started using a 4k monitor recently. When I maximize my tmux pane, all of the text goes very far to the left since the high resolution can fit so many panes. This has been straining my neck. What I'd like is to be able to center the zoomed pane in my monitor. Have you thought about this at all? Is it possible doing something like your maximize_pane() function?

thanks

Powerline or colors wrong?

screenshot from 2016-11-23 09-16-42

What am I doing wrong :O ? Installed powerline and it looks like this :/ And why don't I have any colors in my bash?
Thanks for the conf file!

Edit status line

Hello there!

How can I add/remove things to the status line in a way that doesn't break everything?

Adding modifications to .tmux.conf.local not only completely overrides everything, but is also overriden in the next second by the default

SSH username/hostname not showing

First of all, thanks for your work.

I enabled tmux_conf_theme_username and tmux_conf_theme_hostname. It shows my local username, but when I access a server using SSH it doesn't change the username and hostname even after restarting tmux.

Any ideas about what I should do?

I'm using tmux 2.1 on OS X.

tmux 2.4 bind-key changes

In tmux version 2.4 there were some changes to key bindings (at least for vi-copy mode)
(I think commit: 76d6d3641f271be1756e41494960d96714e7ee58 for https://github.com/tmux/tmux)

of the ones that I am aware, is that the name for the key table 'vi-copy' was changed to 'copy-mode-vi' and to trigger the commands need to use the send-keys command

workaround (for users) is to rewrite the keybindings in .tmux.conf.local
examples:
unbind-key -T copy-mode-vi Escape
bind-key -T copy-mode-vi Escape send-keys -X cancel

bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi V send-keys -X rectangle-toggle

bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'

Config not completely loaded

I’m following the instructions from the readme file to install the configuration. However, when I then start tmux, it seems like not all of the configuration was loaded. Most strikingly, the powerline-inspired status bar isn’t displayed. Other options, such as renumber-windows, are also not enabled. Starting via tmux -f ~/.tmux.conf makes no difference.

In fact, I cannot see any difference before and after soft-linking ~/.tmux/.tmux.conf into ~.

tmux -V outputs:

tmux 1.9a

In fact, this .tmux config used to work, and I think it stopped working after the tmux version was updated on the system (RHEL 6).

In case that helps, tmux -vvv outputs

got 207 from server
got 203 from server
got 204 from server

How to rollback?

Hello,

How do I go back from your config to one of mine? I've removed ~/.tmux.conf* and restored my original config. Reloaded w/ C-a+r but I still see stausbar items in there (although key mapping is now restored).

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.