Add basic gruvbox light theme using 256 colors
Add basic gitignore file Add opening config files in correct vim file-types Exclude vim file artifacts Fix dark theme against changes in tmux v2.9 Fix typos Improve plugin installer Update README Update changes to gruvbox dark theme Update config and remove deprecated/outdated configuration Update tmux-gruvbox-dark.conf
This commit is contained in:
parent
6149fd8b5d
commit
9cb521fef1
6 changed files with 113 additions and 16 deletions
10
.gitignore
vendored
Normal file
10
.gitignore
vendored
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
# Editors
|
||||||
|
.idea/
|
||||||
|
|
||||||
|
# vim
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
*~
|
||||||
|
|
||||||
|
# Systems
|
||||||
|
**/.DS_Store
|
|
@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
||||||
### Added
|
### Added
|
||||||
- Added CHANGELOG file ([#9](https://github.com/egel/tmux-gruvbox/issues/9))
|
- Added CHANGELOG file ([#9](https://github.com/egel/tmux-gruvbox/issues/9))
|
||||||
- Added theme installable through TPM ([#4](https://github.com/egel/tmux-gruvbox/issues/4))
|
- Added theme installable through TPM ([#4](https://github.com/egel/tmux-gruvbox/issues/4))
|
||||||
|
- Added light-medium theme ([#3](https://github.com/egel/tmux-gruvbox/issues/3)]
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
### Deprecated
|
### Deprecated
|
||||||
|
|
25
README.md
25
README.md
|
@ -1,14 +1,17 @@
|
||||||
# Gruvbox color theme configuration for Tmux
|
# Gruvbox color theme configuration for Tmux
|
||||||
|
|
||||||
Theme with 'retro groove' flavor for [Tmux][github-tmux], based on Pavel Pertsev's [gruvbox colorscheme][github-grovbox] and inspired by work of [Gordon Chiam](https://gist.github.com/gchiam/4606522f513cc64b79ce).
|
Theme with 'retro groove' flavor for [Tmux][github-tmux], based on Pavel Pertsev's [gruvbox colorscheme][github-grovbox] and inspired by work of [Gordon Chiam](https://gist.github.com/gchiam/4606522f513cc64b79ce). Subthemes switching inspired by [tmux-color-solarized][tmux-color-solarized].
|
||||||
|
|
||||||
> Screenshot made from Mac OSX builtin terminal with xterm-256color and [Hack font][github-hack].
|
> Screenshots made from macOS builtin terminal with xterm-256color and [Hack font][github-hack].
|
||||||
|
|
||||||
<img src="http://i.imgur.com/OqnVzqf.png" title="Tmux grovbox colorscheme" style="width: 100%; max-width: 600px; text-align: center;" />
|
|
||||||
|
|
||||||
|
| Dark theme | Light theme |
|
||||||
|
|---|---|
|
||||||
|
| <img src="https://i.imgur.com/STohAcp.png" title="Tmux grovbox dark colorscheme" style="width: 100%; max-width: 600px; text-align: center;" /> | <img src="https://i.imgur.com/zQZEFtU.png" title="Tmux grovbox light colorscheme" style="width: 100%; max-width: 600px; text-align: center;" /> |
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
### Install manually
|
### Install manually
|
||||||
|
|
||||||
The simplest way is just:
|
The simplest way is just:
|
||||||
|
|
||||||
> HINT: Always make a backup of your config files before any action.
|
> HINT: Always make a backup of your config files before any action.
|
||||||
|
@ -18,17 +21,21 @@ cat tmux-gruvbox-dark.conf >> ~/.tmux.conf
|
||||||
```
|
```
|
||||||
|
|
||||||
### Install through [Tmux Plugin Manager](https://github.com/tmux-plugins/tpm)
|
### Install through [Tmux Plugin Manager](https://github.com/tmux-plugins/tpm)
|
||||||
Add plugin to the list of TPM plugins in `.tmux.conf`
|
|
||||||
```
|
Add plugin to the list of TPM plugins in `.tmux.conf` and select desired theme
|
||||||
|
|
||||||
|
```bash
|
||||||
set -g @plugin 'egel/tmux-gruvbox'
|
set -g @plugin 'egel/tmux-gruvbox'
|
||||||
|
set -g @tmux-gruvbox 'dark' # or 'light'
|
||||||
```
|
```
|
||||||
Hit `prefix + I` to fetch the plugin and source it.
|
|
||||||
Your tmux should be updated with the theme at this point.
|
Hit `prefix + I` to fetch the plugin and source it. Your Tmux should be updated with the theme at this point.
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
GPLv3 - Maciej Sypień
|
GPLv3 - Maciej Sypień
|
||||||
|
|
||||||
[github-tmux]: https://github.com/tmux/tmux
|
[github-tmux]: https://github.com/tmux/tmux
|
||||||
[github-grovbox]: https://github.com/morhetz/gruvbox
|
[github-grovbox]: https://github.com/morhetz/gruvbox
|
||||||
[github-hack]: https://github.com/chrissimpkins/Hack
|
[github-hack]: https://github.com/chrissimpkins/Hack
|
||||||
|
[tmux-color-solarized]: https://github.com/seebi/tmux-colors-solarized
|
||||||
|
|
|
@ -1,4 +1,25 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||||
tmux source-file "$CURRENT_DIR/tmux-gruvbox-dark.conf"
|
THEME_OPTION="@tmux-gruvbox"
|
||||||
|
DEFAULT_THEME="dark"
|
||||||
|
|
||||||
|
get_theme() {
|
||||||
|
local option="$1"
|
||||||
|
local default_value="$2"
|
||||||
|
local option_value
|
||||||
|
option_value=$(tmux show-option -gqv "$option")
|
||||||
|
if [ -z "$option_value" ]; then
|
||||||
|
print "$default_value"
|
||||||
|
else
|
||||||
|
print "$option_value"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
main() {
|
||||||
|
local theme
|
||||||
|
theme=$(get_theme "$THEME_OPTION" "$DEFAULT_THEME")
|
||||||
|
tmux source-file "$CURRENT_DIR/tmux-gruvbox-${theme}.conf"
|
||||||
|
}
|
||||||
|
|
||||||
|
main
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
## COLORSCHEME: gruvbox dark
|
## COLORSCHEME: gruvbox dark (medium)
|
||||||
set-option -g status "on"
|
set-option -g status "on"
|
||||||
|
|
||||||
# default statusbar color
|
# default statusbar color
|
||||||
|
@ -35,14 +35,16 @@ set-window-option -g window-status-bell-style bg=colour167,fg=colour235 # bg=red
|
||||||
|
|
||||||
## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
|
## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
|
||||||
set-option -g status-justify "left"
|
set-option -g status-justify "left"
|
||||||
set-option -g status-left-style none
|
set-option -g status-left-style attr="none"
|
||||||
set-option -g status-left-length "80"
|
set-option -g status-left-length "80"
|
||||||
set-option -g status-right-style none
|
set-option -g status-right-style none
|
||||||
set-option -g status-right-length "80"
|
set-option -g status-right-length "80"
|
||||||
set-window-option -g window-status-separator ""
|
set-window-option -g window-status-separator ""
|
||||||
|
|
||||||
set-option -g status-left "#[fg=colour248, bg=colour241] #S #[fg=colour241, bg=colour237, nobold, noitalics, nounderscore]"
|
set-option -g status-left "#[bg=colour241,fg=colour248] #S #[bg=colour237,fg=colour241,nobold,noitalics,nounderscore]"
|
||||||
set-option -g status-right "#[fg=colour239, bg=colour237, nobold, nounderscore, noitalics]#[fg=colour246,bg=colour239] %Y-%m-%d %H:%M #[fg=colour248, bg=colour239, nobold, noitalics, nounderscore]#[fg=colour237, bg=colour248] #h "
|
set-option -g status-right "#[bg=colour237,fg=colour239 nobold, nounderscore, noitalics]#[bg=colour239,fg=colour246] %Y-%m-%d %H:%M #[bg=colour239,fg=colour248,nobold,noitalics,nounderscore]#[bg=colour248,fg=colour237] #h "
|
||||||
|
|
||||||
set-window-option -g window-status-current-format "#[fg=colour237, bg=colour214, nobold, noitalics, nounderscore]#[fg=colour239, bg=colour214] #I #[fg=colour239, bg=colour214, bold] #W #[fg=colour214, bg=colour237, nobold, noitalics, nounderscore]"
|
set-window-option -g window-status-current-format "#[bg=colour214,fg=colour237,nobold,noitalics,nounderscore]#[bg=colour214,fg=colour239] #I #[bg=colour214,fg=colour239,bold] #W #[bg=colour237,fg=colour214,nobold,noitalics,nounderscore]"
|
||||||
set-window-option -g window-status-format "#[fg=colour237,bg=colour239,noitalics]#[fg=colour223,bg=colour239] #I #[fg=colour223, bg=colour239] #W #[fg=colour239, bg=colour237, noitalics]"
|
set-window-option -g window-status-format "#[bg=colour239,fg=colour237,noitalics]#[bg=colour239,fg=colour223] #I #[bg=colour239,fg=colour223] #W #[bg=colour237,fg=colour239,noitalics]"
|
||||||
|
|
||||||
|
# vim: set ft=tmux tw=0 nowrap:
|
||||||
|
|
56
tmux-gruvbox-light.conf
Normal file
56
tmux-gruvbox-light.conf
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
## COLORSCHEME: gruvbox light (medium)
|
||||||
|
#
|
||||||
|
# Some colors are not used by gruvbox light medium theme.
|
||||||
|
# The main idea is to find best version of colors that fit
|
||||||
|
# the spirit of gruvbox light theme with limited numbers of
|
||||||
|
# 256 color palette.
|
||||||
|
|
||||||
|
set-option -g status "on"
|
||||||
|
|
||||||
|
# default statusbar colors
|
||||||
|
set-option -g status-style bg=colour252,fg=colour239 # bg=notInGruvboxPallete, #fg=fg1
|
||||||
|
|
||||||
|
# default window title colors
|
||||||
|
set-window-option -g window-status-style bg=colour66,fg=colour229 # bg=aqua, fg=bg5
|
||||||
|
|
||||||
|
# default window with an activity alert
|
||||||
|
set-window-option -g window-status-activity-style bg=colour237,fg=colour241 # bg=bg1, fg=notInGruvboxPallete
|
||||||
|
|
||||||
|
# active window title colors
|
||||||
|
set-window-option -g window-status-current-style bg=default,fg=colour237 # bg=default, fg=bg1
|
||||||
|
|
||||||
|
# pane border
|
||||||
|
set-option -g pane-active-border-style fg=colour241 # fg=notInGruvboxPallete
|
||||||
|
set-option -g pane-border-style fg=colour252 # bg1=notInGruvboxPallete
|
||||||
|
|
||||||
|
# message infos (visible while writing command)
|
||||||
|
set-option -g message-style bg=colour252,fg=colour241 # bg=notInGruvboxPallete, fg=notInGruvboxPallete
|
||||||
|
|
||||||
|
# writing commands inactive
|
||||||
|
set-option -g message-command-style bg=colour124,fg=colour241 # bg=notInGruvboxPallete, fg=notInGruvboxPallete
|
||||||
|
|
||||||
|
# pane number display
|
||||||
|
set-option -g display-panes-active-colour colour241 # notInGruvboxPallete
|
||||||
|
set-option -g display-panes-colour colour248 # notInGruvboxPallete
|
||||||
|
|
||||||
|
# clock
|
||||||
|
set-window-option -g clock-mode-colour colour172 # orange
|
||||||
|
|
||||||
|
# bell
|
||||||
|
set-window-option -g window-status-bell-style bg=colour124,fg=colour229 # bg=red, fg=bg
|
||||||
|
|
||||||
|
## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
|
||||||
|
set-option -g status-justify "left"
|
||||||
|
set-option -g status-left-style attr="none"
|
||||||
|
set-option -g status-left-length "80"
|
||||||
|
set-option -g status-right-style attr="none"
|
||||||
|
set-option -g status-right-length "80"
|
||||||
|
set-window-option -g window-status-separator ""
|
||||||
|
|
||||||
|
set-option -g status-left "#[bg=colour243,fg=colour255] #S #[bg=colour252,fg=colour243,nobold,noitalics,nounderscore]"
|
||||||
|
set-option -g status-right "#[bg=colour252,fg=colour243,nobold,nounderscore,noitalics]#[bg=colour243,fg=colour255] %Y-%m-%d %H:%M #[bg=colour243,fg=colour237,nobold,noitalics,nounderscore]#[bg=colour237,fg=colour255] #h "
|
||||||
|
|
||||||
|
set-window-option -g window-status-current-format "#[bg=colour215,fg=colour252,nobold,noitalics,nounderscore]#[bg=colour215,fg=colour239] #I #[bg=colour215,fg=colour239,bold] #W #[bg=colour252,fg=colour215,nobold,noitalics,nounderscore]"
|
||||||
|
set-window-option -g window-status-format "#[bg=colour249,fg=colour252,noitalics]#[bg=colour249,fg=colour241] #I #[bg=colour249,fg=colour241] #W #[bg=colour252,fg=colour249,noitalics]"
|
||||||
|
|
||||||
|
# vim: set ft=tmux tw=0 nowrap:
|
Loading…
Add table
Add a link
Reference in a new issue