From da5e999c13959f8d0d593f1096253d18387e71a0 Mon Sep 17 00:00:00 2001 From: CramMK Date: Mon, 22 Jun 2020 23:22:30 +0200 Subject: [PATCH] polybar changes and add ~/scripts to $PATH --- dotfiles/i3/config | 6 ++++-- dotfiles/polybar/config | 13 ++++++------- dotfiles/polybar/scripts/spotify.sh | 2 +- dotfiles/scripts/lock-laptop | 2 +- dotfiles/zsh/zshrc | 2 +- 5 files changed, 13 insertions(+), 12 deletions(-) diff --git a/dotfiles/i3/config b/dotfiles/i3/config index 5e55fe7..793f1d3 100644 --- a/dotfiles/i3/config +++ b/dotfiles/i3/config @@ -169,6 +169,9 @@ bindsym XF86MonBrightnessDown exec light -U 5 # decrease screen brightness bindsym $mod+n workspace next bindsym $mod+p workspace prev +# switch to firefox when link gets clicked +for_window [urgent="latest" class="Firefox"] focus + # PC specific configurations: # WORKSTATION START {%@@ if profile == "work" @@%} @@ -220,8 +223,7 @@ bindsym $mod+Ctrl+2 move workspace to output $monitor2 bindsym $mod+Shift+BackSpace exec "~/scripts/lock-laptop" # Custom Workspaces -for_window [class="discord"] move container to workspace 8 -for_window [class="Firefox"] move container to workspace 9 +#for_window [class="discord"] move container to workspace 8 # Monitors # Integrated diff --git a/dotfiles/polybar/config b/dotfiles/polybar/config index eda1897..8747534 100644 --- a/dotfiles/polybar/config +++ b/dotfiles/polybar/config @@ -65,7 +65,7 @@ module-margin = 1 modules-left = i3tabs title modules-center = spotify_current -modules-right = firefox spotify discord pipe backlight volume battery pipe date time pipe +modules-right = firefox spotify discord pipe backlight volume battery pipe network pipe date time pipe separator = wm-name = i3 @@ -81,7 +81,7 @@ monitor = ${env:MONITOR:} modules-left = i3tabs title modules-center = spotify_current -modules-right = firefox spotify discord pipe volume battery date time +modules-right = firefox spotify discord pipe volume battery pipe network pipe date time separator = ############################################################################### @@ -206,10 +206,10 @@ interface = wlo1 interval = 10.0 format-connected = -label-connected = %essid% +label-connected = 泌 %essid% format-disconnectded = -label-disconnected = NO WIFI +label-disconnected = 泌 No Wifi ############################################################################### [module/backlight] @@ -232,13 +232,12 @@ type = custom/script exec = ~/.config/polybar/scripts/spotify.sh %artist% - %title% tail = true interval = 2 -click-left = spotify ############################################################################### [module/spotify] type = custom/text content = "" -click-left = spotify +click-left = spotify & ############################################################################### [module/discord] @@ -250,7 +249,7 @@ click-left = Discord & [module/firefox] type = custom/text content = "" -click-left = "firefox" +click-left = firefox & ############################################################################### [module/pipe] diff --git a/dotfiles/polybar/scripts/spotify.sh b/dotfiles/polybar/scripts/spotify.sh index 15d3561..79a0cee 100755 --- a/dotfiles/polybar/scripts/spotify.sh +++ b/dotfiles/polybar/scripts/spotify.sh @@ -16,7 +16,7 @@ main() { album=$(echo "$meta" | sed -nr '/xesam:album"/,+2s/^ +variant +string "(.*)"$/\1/p' | tail -1| sed 's/\&/\\&/g'| sed 's#\/#\\/#g') title=$(echo "$meta" | sed -nr '/xesam:title"/,+2s/^ +variant +string "(.*)"$/\1/p' | tail -1 | sed 's/\&/\\&/g'| sed 's#\/#\\/#g') - echo " ${*:-%artist% - %title%}" | sed "s/%artist%/$artist/g;s/%title%/$title/g;s/%album%/$album/g"i | sed "s/\&/\&/g" | sed "s#\/#\/#g" + echo "${*:-%artist% - %title%}" | sed "s/%artist%/$artist/g;s/%title%/$title/g;s/%album%/$album/g"i | sed "s/\&/\&/g" | sed "s#\/#\/#g" } diff --git a/dotfiles/scripts/lock-laptop b/dotfiles/scripts/lock-laptop index ad8fb61..8eeee2d 100755 --- a/dotfiles/scripts/lock-laptop +++ b/dotfiles/scripts/lock-laptop @@ -42,6 +42,6 @@ i3lock \ --veriftext="Tadasu..." \ --noinputtext="" \ --locktext="Itterasshai!" \ - --wrongtext="Machigau!" \ + --wrongtext="Chigau!" \ \ --ring-width 4 diff --git a/dotfiles/zsh/zshrc b/dotfiles/zsh/zshrc index d11d4b0..a0c983c 100644 --- a/dotfiles/zsh/zshrc +++ b/dotfiles/zsh/zshrc @@ -11,7 +11,7 @@ zstyle ':vcs_info:git:*' formats '%b' export TERM="xterm-256color" export EDITOR="vim" export LANG="en_US.UTF-8" -export PATH=$PATH:$HOME/.local/bin +export PATH=$PATH:$HOME/.local/bin:$HOME/scripts ## Aliases alias vimrc="vim ~/.vimrc"