Merge branch 'master' into master
This commit is contained in:
commit
892e659b11
4 changed files with 38 additions and 7 deletions
|
@ -48,8 +48,7 @@ To enable plugins set up the `@dracula-plugins` option in you `.tmux.conf` file,
|
|||
The order that you define the plugins will be the order on the status bar left to right.
|
||||
|
||||
```bash
|
||||
# available plugins: battery, cpu-usage, git, gpu-usage, ram-usage, tmux-ram-usage, network, network-bandwidth, network-ping, ssh-session, attached-clients, network-vpn, weather, time, spotify-tui, kubernetes-context, synchronize-panes
|
||||
|
||||
# available plugins: battery, cpu-usage, git, gpu-usage, ram-usage, tmux-ram-usage, network, network-bandwidth, network-ping, ssh-session, attached-clients, network-vpn, weather, time, mpc, spotify-tui, kubernetes-context, synchronize-panes
|
||||
set -g @dracula-plugins "cpu-usage gpu-usage ram-usage"
|
||||
```
|
||||
|
||||
|
@ -75,7 +74,7 @@ Switch powerline symbols
|
|||
# for left
|
||||
set -g @dracula-show-left-sep
|
||||
|
||||
# for right symbol (can set any symbol you like as seperator)
|
||||
# for right symbol (can set any symbol you like as separator)
|
||||
set -g @dracula-show-right-sep
|
||||
```
|
||||
|
||||
|
@ -95,7 +94,7 @@ set -g @dracula-refresh-rate 5
|
|||
Switch the left smiley icon
|
||||
|
||||
```bash
|
||||
# it can accept `session`, `smiley`, `window`, or any character.
|
||||
# it can accept `hostname` (full hostname), `session`, `shortname` (short name), `smiley`, `window`, or any character.
|
||||
set -g @dracula-show-left-icon session
|
||||
```
|
||||
|
||||
|
|
|
@ -28,13 +28,14 @@ Configuration and options can be found at [draculatheme.com/tmux](https://dracul
|
|||
- Custom status texts from external scripts
|
||||
- GPU VRAM usage
|
||||
- GPU power draw
|
||||
- Color code based on if prefix is active or not
|
||||
- List of windows with current window highlighted
|
||||
- When prefix is enabled smiley face turns from green to yellow
|
||||
- Color code based on whether a prefix is active or not
|
||||
- List of windows with the current window highlighted
|
||||
- When prefix is enabled, a smiley face turns from green to yellow
|
||||
- When charging, 'AC' is displayed
|
||||
- If forecast information is available, a ☀, ☁, ☂, or ❄ unicode character corresponding with the forecast is displayed alongside the temperature
|
||||
- Info if the Panes are synchronized
|
||||
- Spotify playback (needs the tool spotify-tui installed)
|
||||
- Music Player Daemon status (needs the tool mpc installed)
|
||||
- Current kubernetes context
|
||||
- Countdown to tmux-continuum save
|
||||
- Current working directory of tmux pane
|
||||
|
|
|
@ -57,6 +57,8 @@ main()
|
|||
left_icon="#W";;
|
||||
hostname)
|
||||
left_icon="#H";;
|
||||
shortname)
|
||||
left_icon="#h";;
|
||||
*)
|
||||
left_icon=$show_left_icon;;
|
||||
esac
|
||||
|
@ -214,6 +216,10 @@ main()
|
|||
IFS=' ' read -r -a colors <<<$(get_tmux_option "@dracula-attached-clients-colors" "cyan dark_gray")
|
||||
script="#($current_dir/attached_clients.sh)"
|
||||
|
||||
elif [ $plugin = "mpc" ]; then
|
||||
IFS=' ' read -r -a colors <<<$(get_tmux_option "@dracula-mpc-colors" "green dark_gray")
|
||||
script="#($current_dir/mpc.sh)"
|
||||
|
||||
elif [ $plugin = "spotify-tui" ]; then
|
||||
IFS=' ' read -r -a colors <<<$(get_tmux_option "@dracula-spotify-tui-colors" "green dark_gray")
|
||||
script="#($current_dir/spotify-tui.sh)"
|
||||
|
|
25
scripts/mpc.sh
Executable file
25
scripts/mpc.sh
Executable file
|
@ -0,0 +1,25 @@
|
|||
#!/usr/bin/env bash
|
||||
# setting the locale, some users have issues with different locales, this forces the correct one
|
||||
export LC_ALL=en_US.UTF-8
|
||||
|
||||
current_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
source $current_dir/utils.sh
|
||||
|
||||
main()
|
||||
{
|
||||
# storing the refresh rate in the variable RATE, default is 5
|
||||
RATE=$(get_tmux_option "@dracula-refresh-rate" 5)
|
||||
|
||||
if ! command -v mpc &> /dev/null
|
||||
then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
FORMAT=$(get_tmux_option "@dracula-mpc-format" "%title% - %artist%")
|
||||
mpc_playback=$(mpc current -f "${FORMAT}")
|
||||
echo ${mpc_playback}
|
||||
|
||||
}
|
||||
|
||||
# run the main driver
|
||||
main
|
Loading…
Reference in a new issue