Skip to content

Commit

Permalink
2019-12-17T01:09:15.413Z
Browse files Browse the repository at this point in the history
  • Loading branch information
devsnek committed Dec 17, 2019
1 parent accbe73 commit 6ec8a20
Show file tree
Hide file tree
Showing 11 changed files with 301 additions and 58 deletions.
7 changes: 5 additions & 2 deletions dotfiles/config.fish
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ for p in $HOME/bin $HOME/n/bin $HOME/.npm-global/bin $HOME/.jsvu $HOME/Desktop/t
end

if command --search ccache >/dev/null do
set -gx CXX "clang++"
set -gx CC "clang"
set -gx CXX "ccache clang++"
set -gx CC "ccache clang"
end

alias erc "$EDITOR ~/.config/fish/config.fish"
Expand Down Expand Up @@ -73,3 +73,6 @@ set fish_greeting ""
if command --search direnv >/dev/null do
direnv hook fish | source
end

# The next line updates PATH for the Google Cloud SDK.
if [ -f '/home/snek/google-cloud-sdk/path.fish.inc' ]; . '/home/snek/google-cloud-sdk/path.fish.inc'; end
18 changes: 9 additions & 9 deletions dotfiles/htoprc
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
# Beware! This file is rewritten by htop when settings are changed in the interface.
# The parser is also very primitive, and not human-friendly.
fields=0 48 17 18 38 39 2 46 47 49 1
sort_key=1
fields=0 48 17 18 38 39 2 46 47 49 1
sort_key=46
sort_direction=1
hide_threads=0
hide_kernel_threads=1
hide_userland_threads=0
hide_userland_threads=1
shadow_other_users=0
show_thread_names=0
show_program_path=1
show_program_path=0
highlight_base_name=0
highlight_megabytes=1
highlight_threads=1
tree_view=1
tree_view=0
header_margin=1
detailed_cpu_time=0
cpu_count_from_zero=1
update_process_names=0
account_guest_in_cpu_meter=0
color_scheme=5
delay=15
left_meters=AllCPUs Memory Swap
left_meter_modes=1 1 1
right_meters=Tasks LoadAverage Uptime
right_meter_modes=2 2 2
left_meters=AllCPUs Memory Swap
left_meter_modes=1 1 1
right_meters=Tasks LoadAverage Uptime
right_meter_modes=2 2 2
22 changes: 12 additions & 10 deletions dotfiles/i3/config
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,19 @@ bindsym Shift+XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @D
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle
bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle

bindsym XF86AudioPlay exec playerctl play-pause
bindsym XF86AudioPause exec playerctl pause
bindsym XF86AudioNext exec playerctl next
bindsym XF86AudioPrev exec playerctl previous

# Screen brightness
bindsym XF86MonBrightnessUp exec xbacklight -inc 5
bindsym XF86MonBrightnessDown exec xbacklight -dec 5
bindsym Shift+XF86MonBrightnessUp exec xbacklight -inc 1
bindsym Shift+XF86MonBrightnessDown exec xbacklight -dec 1
bindsym XF86MonBrightnessUp exec --no-startup-id light -A 5
bindsym XF86MonBrightnessDown exec --no-startup-id light -U 5
bindsym Shift+XF86MonBrightnessUp exec --no-startup-id light -A 1
bindsym Shift+XF86MonBrightnessDown exec --no-startup-id light -U 1

# Screenshot
bindsym Print exec /home/snek/n/bin/node /home/snek/.npm-global/bin/snekshot
bindsym --release Print exec --no-startup-id /home/snek/n/bin/node /home/snek/.npm-global/bin/snekshot

# start a terminal
bindsym $mod+Return exec kitty
Expand Down Expand Up @@ -142,8 +147,5 @@ mode "resize" {
# Enter resize mode
bindsym $mod+r mode "resize"

bar {
font pango:FiraCode 9
status_command /home/snek/bin/i3status-rs /home/snek/.config/i3/status.toml
position top
}
# Start up polybar
exec_always --no-startup-id ~/.config/polybar/start.sh &
1 change: 1 addition & 0 deletions dotfiles/i3/i3
35 changes: 0 additions & 35 deletions dotfiles/i3/status.toml

This file was deleted.

163 changes: 163 additions & 0 deletions dotfiles/polybar/config
Original file line number Diff line number Diff line change
@@ -0,0 +1,163 @@
;==========================================================
;
;
; ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ █████╗ ██████╗
; ██╔══██╗██╔═══██╗██║ ╚██╗ ██╔╝██╔══██╗██╔══██╗██╔══██╗
; ██████╔╝██║ ██║██║ ╚████╔╝ ██████╔╝███████║██████╔╝
; ██╔═══╝ ██║ ██║██║ ╚██╔╝ ██╔══██╗██╔══██║██╔══██╗
; ██║ ╚██████╔╝███████╗██║ ██████╔╝██║ ██║██║ ██║
; ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝
;
;
; To learn more about how to configure Polybar
; go to https://github.com/polybar/polybar
;
; The README contains a lot of information
;
;==========================================================

[colors]
background = #222
background-alt = #444
foreground = #dfdfdf
foreground-alt = #555
primary = #ffb52a
secondary = #e60053
alert = #bd2c40

[bar/top]
width = 100%
height = 20
radius = 0.0
fixed-center = true

background = ${colors.background}
foreground = ${colors.foreground}

line-size = 3
line-color = #f00

border-size = 4
border-color = #00000000

padding-left = 0
padding-right = 2

module-margin-left = 1
module-margin-right = 2

font-0 = FiraCode:size=8;1
font-1 = FiraCode:size=8;1
font-2 = Siji:size=10;1

modules-left = i3
modules-center = date
modules-right = pulseaudio xbacklight wlan eth battery powermenu

tray-position = right
tray-padding = 2

cursor-click = pointer
cursor-scroll = ns-resize

[module/i3]
type = internal/i3
format = <label-state> <label-mode>
index-sort = true
enable-scroll = false
enable-click = false

label-mode-padding = 2
label-mode-foreground = #000
label-mode-background = ${colors.primary}

; focused = Active workspace on focused monitor
label-focused = %index%
label-focused-background = ${colors.background-alt}
label-focused-padding = 2

; unfocused = Inactive workspace on any monitor
label-unfocused = %index%
label-unfocused-padding = 2

; visible = Active workspace on unfocused monitor
label-visible = %index%
label-visible-background = ${self.label-focused-background}
label-visible-padding = ${self.label-focused-padding}

; urgent = Workspace with urgency hint set
label-urgent = %index%
label-urgent-background = ${colors.alert}
label-urgent-padding = 2

[module/xbacklight]
type = internal/xbacklight

format = <label>
label = BL %percentage%%

[module/wlan]
type = internal/network
interface = wlp0s20f3
interval = 10.0

format-connected = <ramp-signal> <label-connected>
label-connected = %local_ip%

format-disconnected =

ramp-signal-0 = 
ramp-signal-1 = 
ramp-signal-2 = 
ramp-signal-3 = 
ramp-signal-4 = 
ramp-signal-foreground = ${colors.foreground-alt}

[module/eth]
type = internal/network
interface = enp0s31f6
interval = 10.0

format-connected-prefix = ""
format-connected-prefix-foreground = ${colors.foreground-alt}
label-connected = %local_ip%

[module/date]
type = internal/date
interval = 5

label = %date% %time%
date = "%a %Y-%m-%d"
time = %H:%M:%S

[module/pulseaudio]
type = internal/pulseaudio

format-volume = <label-volume>
label-volume = VOL %percentage%%
label-volume-foreground = ${root.foreground}

label-muted = muted
label-muted-foreground = #666

[module/battery]
type = internal/battery
battery = BAT0
adapter = ADP1
full-at = 99

format-charging = Charging <label-charging>

format-discharging = Discharging <label-discharging>

; POWERMENU
include-file = ~/.config/polybar/powermenu.ini

[settings]
screenchange-reload = true

[global/wm]
margin-top = 5
margin-bottom = 5

; vim:ft=dosini
1 change: 1 addition & 0 deletions dotfiles/polybar/polybar
27 changes: 27 additions & 0 deletions dotfiles/polybar/powermenu.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
[module/powermenu]
type = custom/menu

expand-right = true
format-spacing = 1

label-open = 
label-open-foreground = ${colors.secondary}
label-close =  cancel
label-close-foreground = ${colors.secondary}
label-separator = |
label-separator-foreground = ${colors.foreground-alt}

menu-0-0 = reboot
menu-0-0-exec = menu-open-1
menu-0-1 = power off
menu-0-1-exec = menu-open-2

menu-1-0 = cancel
menu-1-0-exec = menu-open-0
menu-1-1 = reboot
menu-1-1-exec = sudo reboot

menu-2-0 = power off
menu-2-0-exec = sudo poweroff
menu-2-1 = cancel
menu-2-1-exec = menu-open-0
7 changes: 7 additions & 0 deletions dotfiles/polybar/start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/env sh

killall -q polybar

while pgrep -x polybar >/dev/null; do sleep 1; done

polybar top &
Loading

0 comments on commit 6ec8a20

Please sign in to comment.