Migrate to kitty and Fira Code
822f37eb3233e1e0a492ab30ec737bf5a6f4bade
1 parent
dedb469a
.dircolors
+3 -0
| 8 | 8 | TERM rxvt-unicode-256color |
|
| 9 | 9 | TERM st |
|
| 10 | 10 | TERM st-256color |
|
| 11 | 11 | TERM vte-256color |
|
| 12 | 12 | TERM xterm-256color |
|
| 13 | + | TERM xterm-256color |
|
| 14 | + | TERM xterm-termite |
|
| 15 | + | TERM xterm-kitty |
|
| 13 | 16 | ||
| 14 | 17 | ## Documentation |
|
| 15 | 18 | # |
|
| 16 | 19 | # standard colors |
|
| 17 | 20 | # |
.xmobarrc
+14 -14
| 1 | 1 | -- Xmobar configuration |
|
| 2 | + | -- vim: ft=haskell |
|
| 2 | 3 | ||
| 3 | 4 | Config { |
|
| 4 | - | font = "xft:Inconsolata:size=14,monospace:size=12" |
|
| 5 | + | font = "xft:Fira Code:size=12,monospace:size=12" |
|
| 6 | + | , textOffset = 18 |
|
| 5 | 7 | , borderColor = "black" |
|
| 6 | 8 | , border = TopB |
|
| 7 | 9 | , bgColor = "#000000" |
|
| 8 | 10 | , fgColor = "#777777" |
|
| 9 | 11 | , position = Bottom |
|
| 10 | 12 | , persistent = True |
|
| 11 | 13 | , commands = |
|
| 12 | - | [ Run DynNetwork [ "--template", "<dev> <tx> <rx>", "-w", "7", "-S", "True" ] 10 |
|
| 13 | - | , Run MultiCpu [ "--template", "<total0>% <total1>% <total2>% <total3>%", "-w", "3" ] 50 |
|
| 14 | - | , Run Memory [ "--template", "<available>/<total> MB" ] 50 |
|
| 15 | - | , Run Date "%b %d %Y %H:%M" "date" 10 |
|
| 16 | - | , Run DiskU [("/", "<used>/<size>"), ("/home", "<used>/<size>")] [] 20 |
|
| 17 | - | , Run Com "xmobar-unison-status" [] "dropbox" 10 |
|
| 18 | - | , Run Com "todo-widget" [] "todo" 10 |
|
| 19 | - | , Run Com "xmobar-brightness" [] "brightness" 10 |
|
| 20 | - | , Run CoreTemp [ "--template", "<core0>° <core1>°" ] 50 |
|
| 21 | - | , Run Wireless "wlp2s0" [ "--template", "☎ <essid>/<quality>"] 10 |
|
| 22 | - | , Run Battery [ "--template", "⌁ <left>%" ] 100 |
|
| 23 | - | , Run StdinReader |
|
| 14 | + | [ Run StdinReader |
|
| 15 | + | , Run MultiCpu [ "--template", "<total0> <total1> <total2> <total3>", "-w", "3" ] 50 |
|
| 16 | + | , Run Memory [ "--template", "<available>" ] 50 |
|
| 17 | + | , Run Date "%b %d %H:%M" "date" 10 |
|
| 18 | + | , Run DiskU [("/", "<free>"), ("/home", "<free>")] [] 20 |
|
| 19 | + | , Run CommandReader "xmobar-unison-status" "unison" |
|
| 20 | + | , Run Com "todo-widget" [] "todo" 10 |
|
| 21 | + | , Run Com "xmobar-brightness" [] "brightness" 10 |
|
| 22 | + | , Run Wireless "wlp2s0" [ "--template", "<essid>/<fc=#666><quality></fc>"] 10 |
|
| 23 | + | , Run Battery [ "--template", "<fc=#555>⌁</fc> <left>" ] 100 |
|
| 24 | 24 | ] |
|
| 25 | 25 | , sepChar = "%" |
|
| 26 | 26 | , alignSep = "}{" |
|
| 27 | - | , template = "%StdinReader% }{ %todo% %brightness% %battery% %wlp2s0wi% %dropbox% %multicpu% · %memory% · %disku% · %dynnetwork% <fc=#aaaaaa>%date%</fc> " |
|
| 27 | + | , template = "%StdinReader% }{ %unison% %todo% <fc=#555>☀</fc> %brightness% %battery% %wlp2s0wi% %disku% %memory% %multicpu% <fc=#aaaaaa>%date%</fc> " |
|
| 28 | 28 | } |
.xmonad/xmonad.hs
+8 -3
| 46 | 46 | where |
|
| 47 | 47 | cfg = myXPConfig { position = CenteredAt 0.5 0.3 |
|
| 48 | 48 | , defaultText = "" } |
|
| 49 | 49 | ||
| 50 | 50 | termName :: FilePath |
|
| 51 | - | termName = "alacritty" |
|
| 51 | + | termName = "kitty" |
|
| 52 | 52 | ||
| 53 | 53 | main :: IO () |
|
| 54 | 54 | main = do |
|
| 55 | 55 | home <- getHomeDirectory |
|
| 56 | 56 | xmproc <- spawnPipe "xmobar" |
| 63 | 63 | , handleEventHook = mconcat [docksEventHook, handleEventHook def] |
|
| 64 | 64 | , keys = myKeys home |
|
| 65 | 65 | , logHook = dynamicLogWithPP (barConfig xmproc) |
|
| 66 | 66 | , layoutHook = smartBorders $ avoidStruts $ myLayout |
|
| 67 | 67 | , manageHook = floatNextHook <+> manageDocks <+> manageHook def |
|
| 68 | - | , startupHook = startup <+> docksStartupHook |
|
| 68 | + | , startupHook = docksStartupHook |
|
| 69 | 69 | } `additionalKeysP` myXF86Keys |
|
| 70 | 70 | where |
|
| 71 | - | myLayout = layoutHook def |
|
| 71 | + | myLayout = tiled ||| Mirror tiled ||| Full |
|
| 72 | + | tiled = Tall nmaster delta ratio |
|
| 73 | + | nmaster = 1 |
|
| 74 | + | ratio = 1/2 |
|
| 75 | + | delta = 4/100 |
|
| 76 | + | ||
| 72 | 77 | myXF86Keys = |
|
| 73 | 78 | [ ("<XF86MonBrightnessUp>", safeSpawn "light" ["-A", "5"]) |
|
| 74 | 79 | , ("<XF86MonBrightnessDown>", safeSpawn "light" ["-U", "5"]) |
|
| 75 | 80 | , ("<XF86AudioRaiseVolume>", safeSpawn "amixer" ["-q", "sset", "Master", "2+"]) |
|
| 76 | 81 | , ("<XF86AudioLowerVolume>", safeSpawn "amixer" ["-q", "sset", "Master", "2-"]) |
bin/xmobar-brightness
+1 -1
| 2 | 2 | ||
| 3 | 3 | max=$(cat ~/settings/max-brightness) |
|
| 4 | 4 | actual=$(cat ~/settings/actual-brightness) |
|
| 5 | 5 | ratio=$(($actual * 100 / $max)) |
|
| 6 | 6 | ||
| 7 | - | printf "☀ $(($ratio))%%" |
|
| 7 | + | printf "$(($ratio))" |
|
| 8 | 8 | ||
| 9 | 9 |
bin/xmobar-unison-status
+15 -11
| 1 | 1 | #!/bin/sh |
|
| 2 | 2 | ||
| 3 | - | status="$(systemctl --user is-active dropbox)" |
|
| 3 | + | while :; do |
|
| 4 | + | status="$(systemctl --user is-active dropbox)" |
|
| 4 | 5 | ||
| 5 | - | case "$status" in |
|
| 6 | - | "active") |
|
| 7 | - | if $(unison dropbox -testserver); then |
|
| 8 | - | echo "<fc=aquamarine>✔</fc>" |
|
| 9 | - | else |
|
| 10 | - | echo "<fc=maroon>↯</fc>" |
|
| 11 | - | fi ;; |
|
| 12 | - | *) |
|
| 13 | - | echo "<fc=maroon>✘</fc>" ;; |
|
| 14 | - | esac |
|
| 6 | + | case "$status" in |
|
| 7 | + | "active") |
|
| 8 | + | if $(unison dropbox -testserver 2>/dev/null); then |
|
| 9 | + | echo "<fc=aquamarine>✔</fc>" |
|
| 10 | + | else |
|
| 11 | + | echo "<fc=maroon>↯</fc>" |
|
| 12 | + | fi ;; |
|
| 13 | + | *) |
|
| 14 | + | echo "<fc=maroon>✘</fc>" ;; |
|
| 15 | + | esac |
|
| 16 | + | ||
| 17 | + | sleep 5 |
|
| 18 | + | done |