1636 lines
46 KiB
Org Mode
1636 lines
46 KiB
Org Mode
#+TITLE: Desktop Configuration
|
||
|
||
This =.org= document is where I store all of my small time user-level configuration.
|
||
|
||
I prefer to use programs that I can extend the functionality of via configuration files and source code.
|
||
|
||
* i3
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/i3/config :mkdirp yes
|
||
# Autostart
|
||
# Background
|
||
exec_always --no-startup-id feh --bg-scale ~/dotfiles/guix/home/files/wallpapers/fog-wallpaper.jpg
|
||
|
||
# Redshift
|
||
exec_always --no-startup-id redshift
|
||
|
||
# Picom
|
||
exec_always --no-startup-id picom &
|
||
|
||
# Turn Caps Lock into Escape because Caps Lock is useless unless you're a DB admin.
|
||
exec_always --no-startup-id xmodmap ~/dotfiles/guix/home/files/xmodmap/xmodmap
|
||
|
||
# Set key repeat rate so text cursors move faster.
|
||
exec_always --no-startup-id xset r rate 200 35
|
||
|
||
# Dunst
|
||
exec_always --no-startup-id dunst
|
||
|
||
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
|
||
# screen before suspend. Use loginctl lock-session to lock your screen.
|
||
# exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
|
||
|
||
# NetworkManager is the most popular way to manage wireless networks on Linux,
|
||
# and nm-applet is a desktop environment-independent system tray GUI for it.
|
||
exec --no-startup-id nm-applet
|
||
|
||
# i3 config file (v4)
|
||
set $mod Mod4
|
||
|
||
# Title Bars
|
||
for_window [class=".*"] border pixel 0
|
||
|
||
# Gaps
|
||
smart_gaps on
|
||
gaps inner 10
|
||
gaps outer 10
|
||
|
||
# Font for window titles. Will also be used by the bar unless a different font
|
||
# is used in the bar {} block below.
|
||
font pango:Fira Code Regular 12
|
||
|
||
# This font is widely installed, provides lots of unicode glyphs, right-to-left
|
||
# text rendering and scalability on retina/hidpi displays (thanks to pango).
|
||
# font pango:DejaVu Sans Mono 8
|
||
|
||
# The combination of xss-lock, nm-applet and pactl is a popular choice, so
|
||
# they are included here as an example. Modify as you see fit.
|
||
|
||
|
||
# Use pactl to adjust volume in PulseAudio.
|
||
set $refresh_i3status killall -SIGUSR1 i3status
|
||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status
|
||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status
|
||
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
|
||
bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
|
||
|
||
# Use Mouse+$mod to drag floating windows to their wanted position
|
||
floating_modifier $mod
|
||
|
||
# Lock
|
||
bindsym Control+Shift+e exec loginctl lock-session
|
||
|
||
# start a terminal
|
||
bindsym $mod+Return exec alacritty
|
||
|
||
# kill focused window
|
||
bindsym $mod+Shift+q kill
|
||
|
||
# start dmenu (a program launcher)
|
||
bindsym $mod+d exec rofi -show drun -columns 3 -theme ~/dotfiles/guix/home/files/rofi/config.rasi
|
||
# There also is the (new) i3-dmenu-desktop which only displays applications
|
||
# shipping a .desktop file. It is a wrapper around dmenu, so you need that
|
||
# installed.
|
||
# bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
|
||
|
||
# change focus
|
||
bindsym $mod+h focus left
|
||
bindsym $mod+j focus down
|
||
bindsym $mod+k focus up
|
||
bindsym $mod+l focus right
|
||
|
||
# move focused window
|
||
bindsym $mod+Shift+h move left
|
||
bindsym $mod+Shift+j move down
|
||
bindsym $mod+Shift+k move up
|
||
bindsym $mod+Shift+l move right
|
||
|
||
# split in horizontal orientation
|
||
bindsym $mod+b split h
|
||
|
||
# split in vertical orientation
|
||
bindsym $mod+v split v
|
||
|
||
# enter fullscreen mode for the focused container
|
||
bindsym $mod+f fullscreen toggle
|
||
|
||
# change container layout (stacked, tabbed, toggle split)
|
||
bindsym $mod+s layout stacking
|
||
bindsym $mod+w layout tabbed
|
||
bindsym $mod+e layout toggle split
|
||
|
||
# toggle tiling / floating
|
||
bindsym $mod+Shift+space floating toggle
|
||
|
||
# change focus between tiling / floating windows
|
||
bindsym $mod+space focus mode_toggle
|
||
|
||
# focus the parent container
|
||
bindsym $mod+a focus parent
|
||
|
||
# focus the child container
|
||
#bindsym $mod+d focus child
|
||
|
||
# Define names for default workspaces for which we configure key bindings later on.
|
||
# We use variables to avoid repeating the names in multiple places.
|
||
set $ws1 "1"
|
||
set $ws2 "2"
|
||
set $ws3 "3"
|
||
set $ws4 "4"
|
||
set $ws5 "5"
|
||
set $ws6 "6"
|
||
set $ws7 "7"
|
||
set $ws8 "8"
|
||
set $ws9 "9"
|
||
set $ws10 "10"
|
||
|
||
# switch to workspace
|
||
bindsym $mod+1 workspace number $ws1
|
||
bindsym $mod+2 workspace number $ws2
|
||
bindsym $mod+3 workspace number $ws3
|
||
bindsym $mod+4 workspace number $ws4
|
||
bindsym $mod+5 workspace number $ws5
|
||
bindsym $mod+6 workspace number $ws6
|
||
bindsym $mod+7 workspace number $ws7
|
||
bindsym $mod+8 workspace number $ws8
|
||
bindsym $mod+9 workspace number $ws9
|
||
bindsym $mod+0 workspace number $ws10
|
||
|
||
# move focused container to workspace
|
||
bindsym $mod+Shift+1 move container to workspace number $ws1
|
||
bindsym $mod+Shift+2 move container to workspace number $ws2
|
||
bindsym $mod+Shift+3 move container to workspace number $ws3
|
||
bindsym $mod+Shift+4 move container to workspace number $ws4
|
||
bindsym $mod+Shift+5 move container to workspace number $ws5
|
||
bindsym $mod+Shift+6 move container to workspace number $ws6
|
||
bindsym $mod+Shift+7 move container to workspace number $ws7
|
||
bindsym $mod+Shift+8 move container to workspace number $ws8
|
||
bindsym $mod+Shift+9 move container to workspace number $ws9
|
||
bindsym $mod+Shift+0 move container to workspace number $ws10
|
||
|
||
# reload the configuration file
|
||
bindsym $mod+Shift+c reload
|
||
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
|
||
bindsym $mod+Shift+r restart
|
||
# exit i3 (logs you out of your X session)
|
||
bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"
|
||
|
||
# resize window (you can also use the mouse for that)
|
||
mode "resize" {
|
||
# These bindings trigger as soon as you enter the resize mode
|
||
|
||
# Pressing left will shrink the window’s width.
|
||
# Pressing right will grow the window’s width.
|
||
# Pressing up will shrink the window’s height.
|
||
# Pressing down will grow the window’s height.
|
||
bindsym j resize shrink width 10 px or 10 ppt
|
||
bindsym k resize grow height 10 px or 10 ppt
|
||
bindsym l resize shrink height 10 px or 10 ppt
|
||
bindsym semicolon resize grow width 10 px or 10 ppt
|
||
|
||
# same bindings, but for the arrow keys
|
||
bindsym Left resize shrink width 10 px or 10 ppt
|
||
bindsym Down resize grow height 10 px or 10 ppt
|
||
bindsym Up resize shrink height 10 px or 10 ppt
|
||
bindsym Right resize grow width 10 px or 10 ppt
|
||
|
||
# back to normal: Enter or Escape or $mod+r
|
||
bindsym Return mode "default"
|
||
bindsym Escape mode "default"
|
||
bindsym $mod+r mode "default"
|
||
}
|
||
|
||
bindsym $mod+r mode "resize"
|
||
|
||
# Start i3bar to display a workspace bar (plus the system information i3status
|
||
# finds out, if available)
|
||
# panel
|
||
bar {
|
||
colors {
|
||
background #2f343f
|
||
statusline #2f343f
|
||
separator #4b5262
|
||
|
||
# colour of border, background, and text
|
||
focused_workspace #2f343f #bf616a #d8dee8
|
||
active_workspace #2f343f #2f343f #d8dee8
|
||
inactive_workspace #2f343f #2f343f #d8dee8
|
||
urgent_workspacei #2f343f #ebcb8b #2f343f
|
||
}
|
||
status_command i3status
|
||
position top
|
||
}
|
||
#+end_src
|
||
|
||
* i3status
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/i3status/config :mkdirp yes
|
||
general {
|
||
output_format = "i3bar"
|
||
colors = false
|
||
markup = pango
|
||
interval = 5
|
||
color_good = '#2f343f'
|
||
color_degraded = '#ebcb8b'
|
||
color_bad = '#ba5e57'
|
||
}
|
||
|
||
order += "load"
|
||
order += "cpu_temperature 0"
|
||
order += "disk /"
|
||
order += "disk /home"
|
||
order += "ethernet enp0s13f0u2u1"
|
||
order += "wireless wlp0s20f3"
|
||
order += "volume master"
|
||
order += "battery 0"
|
||
order += "tztime local"
|
||
|
||
load {
|
||
format = "<span background='#f59335'> %5min Load </span>"
|
||
}
|
||
|
||
cpu_temperature 0 {
|
||
format = "<span background='#bf616a'> %degrees °C </span>"
|
||
path = "/sys/class/thermal/thermal_zone0/temp"
|
||
}
|
||
|
||
disk "/" {
|
||
format = "<span background='#fec7cd'> %free Free </span>"
|
||
}
|
||
|
||
disk "/home" {
|
||
format = "<span background='#a1d569'> %free Free </span>"
|
||
}
|
||
|
||
ethernet enp0s13f0u2u1 {
|
||
format_up = "<span background='#88c0d0'> %ip </span>"
|
||
format_down = "<span background='#88c0d0'> Disconnected </span>"
|
||
}
|
||
|
||
wireless wlp0s20f3 {
|
||
format_up = "<span background='#b48ead'> %essid </span>"
|
||
format_down = "<span background='#b48ead'> Disconnected </span>"
|
||
}
|
||
|
||
volume master {
|
||
format = "<span background='#ebcb8b'> %volume </span>"
|
||
format_muted = "<span background='#ebcb8b'> Muted </span>"
|
||
device = "default"
|
||
mixer = "Master"
|
||
mixer_idx = 0
|
||
}
|
||
|
||
battery 0 {
|
||
last_full_capacity = true
|
||
format = "<span background='#a3be8c'> %status %percentage </span>"
|
||
format_down = "No Battery"
|
||
status_chr = "Charging"
|
||
status_bat = "Battery"
|
||
status_unk = "Unknown"
|
||
status_full = "Charged"
|
||
path = "/sys/class/power_supply/BAT0/uevent"
|
||
low_threshold = 10
|
||
}
|
||
|
||
tztime local {
|
||
format = "<span background='#81a1c1'> %time </span>"
|
||
format_time = " %a %-d %b %H:%M"
|
||
}
|
||
#+end_src
|
||
|
||
* Rofi
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/rofi/config.rasi :mkdirp yes
|
||
configuration {
|
||
modi: "drun";
|
||
font: "Fira Code Regular 10";
|
||
show-icons: true;
|
||
icon-theme: "Reversal-dark";
|
||
display-drun: "";
|
||
drun-display-format: "{name}";
|
||
sidebar-mode: false;
|
||
}
|
||
|
||
@theme "/dev/null"
|
||
|
||
* {
|
||
bg: #151515;
|
||
fg: #e8e8d3;
|
||
accent: #687363;
|
||
button: #1c1c1c;
|
||
|
||
background-color: @bg;
|
||
text-color: @fg;
|
||
}
|
||
|
||
window {
|
||
border-radius: 7px;
|
||
width: 50%;
|
||
padding: 32px;
|
||
}
|
||
|
||
prompt {
|
||
background-color: @button;
|
||
enabled: true;
|
||
padding: 0.5% 32px 0% -0.5%;
|
||
font: "Rubik 10";
|
||
}
|
||
|
||
entry {
|
||
placeholder: "Search";
|
||
background-color: @button;
|
||
placeholder-color: @fg;
|
||
expand: true;
|
||
padding: 0.15% 0% 0% 0%;
|
||
}
|
||
|
||
inputbar {
|
||
children: [ prompt, entry ];
|
||
background-color: @button;
|
||
expand: false;
|
||
border-radius: 6px;
|
||
margin: 0%;
|
||
padding: 10px;
|
||
}
|
||
|
||
listview {
|
||
columns: 4;
|
||
lines: 3;
|
||
cycle: false;
|
||
dynamic: true;
|
||
layout: vertical;
|
||
}
|
||
|
||
mainbox {
|
||
children: [ inputbar, listview ];
|
||
spacing: 2%;
|
||
padding: 2% 1% 2% 1%;
|
||
}
|
||
|
||
element {
|
||
orientation: vertical;
|
||
padding: 2% 0% 2% 0%;
|
||
}
|
||
|
||
element-icon {
|
||
size: 48px;
|
||
horizontal-align: 0.5;
|
||
}
|
||
|
||
element-text {
|
||
expand: true;
|
||
horizontal-align: 0.5;
|
||
vertical-align: 0.5;
|
||
margin: 0.5% 0.5% -0.5% 0.5%;
|
||
}
|
||
|
||
element-text, element-icon {
|
||
background-color: inherit;
|
||
text-color: inherit;
|
||
}
|
||
|
||
element selected {
|
||
background-color: @button;
|
||
border-radius: 6px;
|
||
}
|
||
#+end_src
|
||
* Picom
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/picom/picom.conf :mkdirp yes
|
||
#################################
|
||
# Shadows #
|
||
#################################
|
||
|
||
|
||
# Enabled client-side shadows on windows. Note desktop windows
|
||
# (windows with '_NET_WM_WINDOW_TYPE_DESKTOP') never get shadow,
|
||
# unless explicitly requested using the wintypes option.
|
||
#
|
||
# shadow = false
|
||
shadow = true;
|
||
|
||
# The blur radius for shadows, in pixels. (defaults to 12)
|
||
# shadow-radius = 12
|
||
shadow-radius = 7;
|
||
|
||
# The opacity of shadows. (0.0 - 1.0, defaults to 0.75)
|
||
# shadow-opacity = .75
|
||
|
||
# The left offset for shadows, in pixels. (defaults to -15)
|
||
# shadow-offset-x = -15
|
||
shadow-offset-x = -7;
|
||
|
||
# The top offset for shadows, in pixels. (defaults to -15)
|
||
# shadow-offset-y = -15
|
||
shadow-offset-y = -7;
|
||
|
||
# Red color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-red = 0
|
||
|
||
# Green color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-green = 0
|
||
|
||
# Blue color value of shadow (0.0 - 1.0, defaults to 0).
|
||
# shadow-blue = 0
|
||
|
||
# Hex string color value of shadow (#000000 - #FFFFFF, defaults to #000000). This option will override options set shadow-(red/green/blue)
|
||
# shadow-color = "#000000"
|
||
|
||
# Specify a list of conditions of windows that should have no shadow.
|
||
#
|
||
# examples:
|
||
# shadow-exclude = "n:e:Notification";
|
||
#
|
||
# shadow-exclude = []
|
||
shadow-exclude = [
|
||
"name = 'Notification'",
|
||
"class_g = 'Conky'",
|
||
"class_g ?= 'Notify-osd'",
|
||
"class_g = 'Cairo-clock'",
|
||
"_GTK_FRAME_EXTENTS@:c"
|
||
];
|
||
|
||
# Specify a list of conditions of windows that should have no shadow painted over, such as a dock window.
|
||
# clip-shadow-above = []
|
||
|
||
# Specify a X geometry that describes the region in which shadow should not
|
||
# be painted in, such as a dock window region. Use
|
||
# shadow-exclude-reg = "x10+0+0"
|
||
# for example, if the 10 pixels on the bottom of the screen should not have shadows painted on.
|
||
#
|
||
# shadow-exclude-reg = ""
|
||
|
||
# Crop shadow of a window fully on a particular Xinerama screen to the screen.
|
||
# xinerama-shadow-crop = false
|
||
|
||
|
||
#################################
|
||
# Fading #
|
||
#################################
|
||
|
||
|
||
# Fade windows in/out when opening/closing and when opacity changes,
|
||
# unless no-fading-openclose is used.
|
||
# fading = false
|
||
fading = true;
|
||
|
||
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
|
||
# fade-in-step = 0.028
|
||
fade-in-step = 0.03;
|
||
|
||
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
|
||
# fade-out-step = 0.03
|
||
fade-out-step = 0.03;
|
||
|
||
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
|
||
# fade-delta = 10
|
||
|
||
# Specify a list of conditions of windows that should not be faded.
|
||
# fade-exclude = []
|
||
|
||
# Do not fade on window open/close.
|
||
# no-fading-openclose = false
|
||
|
||
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
|
||
# no-fading-destroyed-argb = false
|
||
|
||
|
||
#################################
|
||
# Transparency / Opacity #
|
||
#################################
|
||
|
||
|
||
# Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0)
|
||
# inactive-opacity = 1
|
||
inactive-opacity = 0.8;
|
||
|
||
# Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default)
|
||
# frame-opacity = 1.0
|
||
frame-opacity = 0.7;
|
||
|
||
# Let inactive opacity set by -i override the '_NET_WM_OPACITY' values of windows.
|
||
# inactive-opacity-override = true
|
||
inactive-opacity-override = false;
|
||
|
||
# Default opacity for active windows. (0.0 - 1.0, defaults to 1.0)
|
||
# active-opacity = 1.0
|
||
|
||
# Dim inactive windows. (0.0 - 1.0, defaults to 0.0)
|
||
# inactive-dim = 0.0
|
||
|
||
# Specify a list of conditions of windows that should never be considered focused.
|
||
# focus-exclude = []
|
||
focus-exclude = [ "class_g = 'Cairo-clock'" ];
|
||
|
||
# Use fixed inactive dim value, instead of adjusting according to window opacity.
|
||
# inactive-dim-fixed = 1.0
|
||
|
||
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
|
||
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
|
||
# Note we don't make any guarantee about possible conflicts with other
|
||
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
|
||
# example:
|
||
# opacity-rule = [ "80:class_g = 'URxvt'" ];
|
||
#
|
||
# opacity-rule = []
|
||
|
||
|
||
#################################
|
||
# Corners #
|
||
#################################
|
||
|
||
# Sets the radius of rounded window corners. When > 0, the compositor will
|
||
# round the corners of windows. Does not interact well with
|
||
# `transparent-clipping`.
|
||
corner-radius = 0
|
||
|
||
# Exclude conditions for rounded corners.
|
||
rounded-corners-exclude = [
|
||
"window_type = 'dock'",
|
||
"window_type = 'desktop'"
|
||
];
|
||
|
||
|
||
#################################
|
||
# Background-Blurring #
|
||
#################################
|
||
|
||
|
||
# Parameters for background blurring, see the *BLUR* section for more information.
|
||
# blur-method =
|
||
# blur-size = 12
|
||
#
|
||
# blur-deviation = false
|
||
#
|
||
# blur-strength = 5
|
||
|
||
# Blur background of semi-transparent / ARGB windows.
|
||
# Bad in performance, with driver-dependent behavior.
|
||
# The name of the switch may change without prior notifications.
|
||
#
|
||
# blur-background = false
|
||
|
||
# Blur background of windows when the window frame is not opaque.
|
||
# Implies:
|
||
# blur-background
|
||
# Bad in performance, with driver-dependent behavior. The name may change.
|
||
#
|
||
# blur-background-frame = false
|
||
|
||
|
||
# Use fixed blur strength rather than adjusting according to window opacity.
|
||
# blur-background-fixed = false
|
||
|
||
|
||
# Specify the blur convolution kernel, with the following format:
|
||
# example:
|
||
# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1";
|
||
#
|
||
# blur-kern = ""
|
||
blur-kern = "3x3box";
|
||
|
||
|
||
# Exclude conditions for background blur.
|
||
# blur-background-exclude = []
|
||
blur-background-exclude = [
|
||
"window_type = 'dock'",
|
||
"window_type = 'desktop'",
|
||
"_GTK_FRAME_EXTENTS@:c"
|
||
];
|
||
|
||
#################################
|
||
# General Settings #
|
||
#################################
|
||
|
||
# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers.
|
||
# daemon = false
|
||
|
||
# Specify the backend to use: `xrender`, `glx`, or `xr_glx_hybrid`.
|
||
# `xrender` is the default one.
|
||
#
|
||
# backend = "glx"
|
||
backend = "xrender";
|
||
|
||
# Enable/disable VSync.
|
||
# vsync = false
|
||
vsync = true;
|
||
|
||
# Enable remote control via D-Bus. See the *D-BUS API* section below for more details.
|
||
# dbus = false
|
||
|
||
# Try to detect WM windows (a non-override-redirect window with no
|
||
# child that has 'WM_STATE') and mark them as active.
|
||
#
|
||
# mark-wmwin-focused = false
|
||
mark-wmwin-focused = true;
|
||
|
||
# Mark override-redirect windows that doesn't have a child window with 'WM_STATE' focused.
|
||
# mark-ovredir-focused = false
|
||
mark-ovredir-focused = true;
|
||
|
||
# Try to detect windows with rounded corners and don't consider them
|
||
# shaped windows. The accuracy is not very high, unfortunately.
|
||
#
|
||
# detect-rounded-corners = false
|
||
detect-rounded-corners = true;
|
||
|
||
# Detect '_NET_WM_OPACITY' on client windows, useful for window managers
|
||
# not passing '_NET_WM_OPACITY' of client windows to frame windows.
|
||
#
|
||
# detect-client-opacity = false
|
||
detect-client-opacity = true;
|
||
|
||
# Specify refresh rate of the screen. If not specified or 0, picom will
|
||
# try detecting this with X RandR extension.
|
||
#
|
||
# refresh-rate = 60
|
||
refresh-rate = 0;
|
||
|
||
# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window,
|
||
# rather than listening to 'FocusIn'/'FocusOut' event. Might have more accuracy,
|
||
# provided that the WM supports it.
|
||
#
|
||
# use-ewmh-active-win = false
|
||
|
||
# Unredirect all windows if a full-screen opaque window is detected,
|
||
# to maximize performance for full-screen windows. Known to cause flickering
|
||
# when redirecting/unredirecting windows.
|
||
#
|
||
# unredir-if-possible = false
|
||
|
||
# Delay before unredirecting the window, in milliseconds. Defaults to 0.
|
||
# unredir-if-possible-delay = 0
|
||
|
||
# Conditions of windows that shouldn't be considered full-screen for unredirecting screen.
|
||
# unredir-if-possible-exclude = []
|
||
|
||
# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows
|
||
# in the same group focused at the same time.
|
||
#
|
||
# detect-transient = false
|
||
detect-transient = true;
|
||
|
||
# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same
|
||
# group focused at the same time. This usually means windows from the same application
|
||
# will be considered focused or unfocused at the same time.
|
||
# 'WM_TRANSIENT_FOR' has higher priority if detect-transient is enabled, too.
|
||
#
|
||
# detect-client-leader = false
|
||
|
||
# Resize damaged region by a specific number of pixels.
|
||
# A positive value enlarges it while a negative one shrinks it.
|
||
# If the value is positive, those additional pixels will not be actually painted
|
||
# to screen, only used in blur calculation, and such. (Due to technical limitations,
|
||
# with use-damage, those pixels will still be incorrectly painted to screen.)
|
||
# Primarily used to fix the line corruption issues of blur,
|
||
# in which case you should use the blur radius value here
|
||
# (e.g. with a 3x3 kernel, you should use `--resize-damage 1`,
|
||
# with a 5x5 one you use `--resize-damage 2`, and so on).
|
||
# May or may not work with *--glx-no-stencil*. Shrinking doesn't function correctly.
|
||
#
|
||
# resize-damage = 1
|
||
|
||
# Specify a list of conditions of windows that should be painted with inverted color.
|
||
# Resource-hogging, and is not well tested.
|
||
#
|
||
# invert-color-include = []
|
||
|
||
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
|
||
# Might cause incorrect opacity when rendering transparent content (but never
|
||
# practically happened) and may not work with blur-background.
|
||
# My tests show a 15% performance boost. Recommended.
|
||
#
|
||
# glx-no-stencil = false
|
||
|
||
# GLX backend: Avoid rebinding pixmap on window damage.
|
||
# Probably could improve performance on rapid window content changes,
|
||
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
|
||
# Recommended if it works.
|
||
#
|
||
# glx-no-rebind-pixmap = false
|
||
|
||
# Disable the use of damage information.
|
||
# This cause the whole screen to be redrawn everytime, instead of the part of the screen
|
||
# has actually changed. Potentially degrades the performance, but might fix some artifacts.
|
||
# The opposing option is use-damage
|
||
#
|
||
# no-use-damage = false
|
||
use-damage = true;
|
||
|
||
# Use X Sync fence to sync clients' draw calls, to make sure all draw
|
||
# calls are finished before picom starts drawing. Needed on nvidia-drivers
|
||
# with GLX backend for some users.
|
||
#
|
||
# xrender-sync-fence = false
|
||
|
||
# GLX backend: Use specified GLSL fragment shader for rendering window contents.
|
||
# See `compton-default-fshader-win.glsl` and `compton-fake-transparency-fshader-win.glsl`
|
||
# in the source tree for examples.
|
||
#
|
||
# glx-fshader-win = ""
|
||
|
||
# Force all windows to be painted with blending. Useful if you
|
||
# have a glx-fshader-win that could turn opaque pixels transparent.
|
||
#
|
||
# force-win-blend = false
|
||
|
||
# Do not use EWMH to detect fullscreen windows.
|
||
# Reverts to checking if a window is fullscreen based only on its size and coordinates.
|
||
#
|
||
# no-ewmh-fullscreen = false
|
||
|
||
# Dimming bright windows so their brightness doesn't exceed this set value.
|
||
# Brightness of a window is estimated by averaging all pixels in the window,
|
||
# so this could comes with a performance hit.
|
||
# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. (default: 1.0)
|
||
#
|
||
# max-brightness = 1.0
|
||
|
||
# Make transparent windows clip other windows like non-transparent windows do,
|
||
# instead of blending on top of them.
|
||
#
|
||
# transparent-clipping = false
|
||
|
||
# Set the log level. Possible values are:
|
||
# "trace", "debug", "info", "warn", "error"
|
||
# in increasing level of importance. Case doesn't matter.
|
||
# If using the "TRACE" log level, it's better to log into a file
|
||
# using *--log-file*, since it can generate a huge stream of logs.
|
||
#
|
||
# log-level = "debug"
|
||
log-level = "warn";
|
||
|
||
# Set the log file.
|
||
# If *--log-file* is never specified, logs will be written to stderr.
|
||
# Otherwise, logs will to written to the given file, though some of the early
|
||
# logs might still be written to the stderr.
|
||
# When setting this option from the config file, it is recommended to use an absolute path.
|
||
#
|
||
# log-file = "/path/to/your/log/file"
|
||
|
||
# Show all X errors (for debugging)
|
||
# show-all-xerrors = false
|
||
|
||
# Write process ID to a file.
|
||
# write-pid-path = "/path/to/your/log/file"
|
||
|
||
# Window type settings
|
||
#
|
||
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
|
||
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
|
||
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
|
||
# "tooltip", "notification", "combo", and "dnd".
|
||
#
|
||
# Following per window-type options are available: ::
|
||
#
|
||
# fade, shadow:::
|
||
# Controls window-type-specific shadow and fade settings.
|
||
#
|
||
# opacity:::
|
||
# Controls default opacity of the window type.
|
||
#
|
||
# focus:::
|
||
# Controls whether the window of this type is to be always considered focused.
|
||
# (By default, all window types except "normal" and "dialog" has this on.)
|
||
#
|
||
# full-shadow:::
|
||
# Controls whether shadow is drawn under the parts of the window that you
|
||
# normally won't be able to see. Useful when the window has parts of it
|
||
# transparent, and you want shadows in those areas.
|
||
#
|
||
# clip-shadow-above:::
|
||
# Controls wether shadows that would have been drawn above the window should
|
||
# be clipped. Useful for dock windows that should have no shadow painted on top.
|
||
#
|
||
# redir-ignore:::
|
||
# Controls whether this type of windows should cause screen to become
|
||
# redirected again after been unredirected. If you have unredir-if-possible
|
||
# set, and doesn't want certain window to cause unnecessary screen redirection,
|
||
# you can set this to `true`.
|
||
#
|
||
wintypes:
|
||
{
|
||
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
|
||
dock = { shadow = false; clip-shadow-above = true; }
|
||
dnd = { shadow = false; }
|
||
popup_menu = { opacity = 0.8; }
|
||
dropdown_menu = { opacity = 0.8; }
|
||
};
|
||
#+end_src
|
||
* Zsh
|
||
Aside from using e-shell for quick command line usage, I mainly use vterm with Zsh. It's a bit of a complicated setup but allows for the maximum number of files possible to live in .config instead of littering my home directory.
|
||
** zshrc
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/zsh/zshrc :mkdirp yes
|
||
# Sometimes SSH'ing with Emacs is ungraceful.
|
||
# To remedy this I disable the zsh line editor.
|
||
[[ $TERM == "dumb" ]] && unsetopt zle && PS1='$ ' && return
|
||
|
||
|
||
#### ~~~~ General ~~~~ #####
|
||
export ZSH="$XDG_CONFIG_HOME/oh-my-zsh"
|
||
HISTFILE=$XDG_CONFIG_HOME/zsh/.history
|
||
ZSH_THEME="mrtazz"
|
||
DISABLE_AUTO_UPDATE="true"
|
||
ENABLE_CORRECTION="true"
|
||
plugins=(git)
|
||
source $ZSH/oh-my-zsh.sh # This has to stay below plugins.
|
||
|
||
#### ~~~~ Autostart ~~~~ #####
|
||
pfetch
|
||
|
||
#### ~~~~ Path Additions ~~~~ #####
|
||
export PATH=/home/opal/scripts:$PATH # Scripts
|
||
|
||
#### ~~~~ Locale ~~~~ #####
|
||
export LANG=en_US.UTF-8
|
||
|
||
|
||
#### ~~~~ Import ~~~~ #####
|
||
ALIAS_LOCATION="$XDG_CONFIG_HOME/zsh/zsh_aliases"
|
||
FUNCTION_LOCATION="$XDG_CONFIG_HOME/zsh/zsh_functions"
|
||
source $ALIAS_LOCATION
|
||
source $FUNCTION_LOCATION
|
||
#+end_src
|
||
** zsh_aliases
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/zsh/zsh_aliases
|
||
# ~ Guix #
|
||
alias install="guix install"
|
||
alias remove="guix remove"
|
||
alias search="guix search"
|
||
alias pull="guix pull"
|
||
alias upgrade="guix package -u"
|
||
alias hreconfig="guix home reconfigure ~/dotfiles/guix/home/guix-home.scm"
|
||
|
||
# ~ Commands ~ #
|
||
alias ip="ip -c"
|
||
alias rm="rm -i"
|
||
alias ols="ls-with-file-mode-bits.sh"
|
||
|
||
# ~ Derp ~ #
|
||
alias unmount="umount"
|
||
alias please="sudo"
|
||
alias yeet="rm -rf"
|
||
alias :q='echo This aint a file, dingus.'
|
||
alias :wq='echo This aint a file, dingus.'
|
||
|
||
# ~ Source Zsh Configuration ~ #
|
||
alias zshrcsource="source ~/dotfiles/guix/home/files/zsh/zshrc"
|
||
#+end_src
|
||
** zsh_functions
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/zsh/zsh_functions
|
||
# ~ Move files to trash folder instead ~ #
|
||
del () { mv "$@" $HOME/.local/share/trash/files/.; }
|
||
|
||
# Make directory and CD into it.
|
||
mk () { mkdir -p -- "$1" && cd -P -- "$1" }
|
||
#+end_src
|
||
** zprofile
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/zsh/zprofile :mkdirp yes
|
||
HOME_ENVIRONMENT=$HOME/.guix-home
|
||
. $HOME_ENVIRONMENT/setup-environment
|
||
$HOME_ENVIRONMENT/on-first-login
|
||
# Each new shell auto-imports all environment variables.
|
||
# Hence exporting needs to be done only once.
|
||
# Also, all non-login shells are descendants of a login shell.
|
||
# Ergo, exports need to be done in the login shell only.
|
||
# Hence, we put exports in .zprofile
|
||
|
||
# Only vars needed by external commands should be exported.
|
||
# Note that you can export vars w/out assigning a value to them.
|
||
export XDG_CONFIG_HOME=~/.config
|
||
export XDG_CACHE_HOME=~/.cache
|
||
export XDG_DATA_HOME=~/.local/share
|
||
export XDG_STATE_HOME=~/.config/zsh
|
||
export EDITOR=nvim
|
||
export VISUAL=nvim
|
||
GUIX_PROFILE="$HOME/.config/guix/current" . "$GUIX_PROFILE/etc/profile"
|
||
xmodmap ~/.config/xmodmap/xmodmap
|
||
#+end_src
|
||
** zshenv
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/zsh/zshenv :mkdirp yes
|
||
if [[ -z "$XDG_CONFIG_HOME" ]]
|
||
then
|
||
export XDG_CONFIG_HOME="$HOME/.config"
|
||
fi
|
||
|
||
if [[ -d "$XDG_CONFIG_HOME/zsh" ]]
|
||
then
|
||
export ZDOTDIR="$XDG_CONFIG_HOME/zsh"
|
||
fi
|
||
#+end_src
|
||
|
||
#+RESULTS:
|
||
|
||
* Alacritty
|
||
#+begin_src sh :tangle ~/dotfiles/guix/home/files/alacritty/alacritty.yml :mkdirp yes
|
||
# Env
|
||
env:
|
||
TERM: xterm-256color
|
||
|
||
# Font configuration
|
||
font:
|
||
normal:
|
||
family: inconsolata
|
||
style: Regular
|
||
bold:
|
||
family: inconsolata
|
||
style: Bold
|
||
italic:
|
||
family: inconsolata
|
||
style: Italic
|
||
bold_italic:
|
||
family: inconsolata
|
||
style: Bold Italic
|
||
size: 12
|
||
#+end_src
|
||
|
||
* Dunst
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/dunst/dunstrc :mkdirp yes
|
||
[global]
|
||
monitor = 0
|
||
follow = keyboard
|
||
geometry = "250x50-24+24"
|
||
indicate_hidden = yes
|
||
shrink = no
|
||
separator_height = 0
|
||
padding = 16
|
||
horizontal_padding = 24
|
||
frame_width = 2
|
||
sort = no
|
||
idle_threshold = 120
|
||
font = Noto Sans 8
|
||
line_height = 4
|
||
markup = full
|
||
format = "<b>%s</b>\n%b"
|
||
alignment = left
|
||
show_age_threshold = 60
|
||
word_wrap = yes
|
||
ignore_newline = no
|
||
stack_duplicates = false
|
||
hide_duplicate_count = yes
|
||
show_indicators = no
|
||
icon_position = off
|
||
sticky_history = yes
|
||
history_length = 20
|
||
browser = /usr/bin/icecat -new-tab
|
||
always_run_script = true
|
||
title = Dunst
|
||
class = Dunst
|
||
|
||
[shortcuts]
|
||
close = ctrl+space
|
||
close_all = ctrl+shift+space
|
||
history = ctrl+grave
|
||
context = ctrl+shift+period
|
||
|
||
[urgency_low]
|
||
background = "#2f343f"
|
||
foreground = "#d8dee8"
|
||
timeout = 2
|
||
|
||
[urgency_normal]
|
||
background = "#2f343f"
|
||
foreground = "#d8dee8"
|
||
timeout = 4
|
||
|
||
[urgency_critical]
|
||
background = "#2f343f"
|
||
foreground = "#d8dee8"
|
||
frame_color = "#bf616a"
|
||
timeout = 0
|
||
#+end_src
|
||
|
||
* Redshift
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/redshift/redshift.conf :mkdirp yes
|
||
[redshift]
|
||
temp-day=5700
|
||
temp-night=3400
|
||
fade=1
|
||
location-provider=manual
|
||
adjustment-method=randr
|
||
|
||
[manual]
|
||
lat=47.6
|
||
lon=-122.3
|
||
#+end_src
|
||
|
||
* XDG User Directories
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/user-dirs.dirs :mkdirp yes
|
||
# This file is written by xdg-user-dirs-update
|
||
# If you want to change or add directories, just edit the line you're
|
||
# interested in. All local changes will be retained on the next run.
|
||
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
|
||
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
|
||
# absolute path. No other format is supported.
|
||
#
|
||
XDG_DESKTOP_DIR="$HOME"
|
||
XDG_DOWNLOAD_DIR="$HOME/downloads"
|
||
XDG_TEMPLATES_DIR="$HOME"
|
||
XDG_PUBLICSHARE_DIR="$HOME"
|
||
XDG_DOCUMENTS_DIR="$HOME/documents"
|
||
XDG_MUSIC_DIR="$HOME/music"
|
||
XDG_PICTURES_DIR="$HOME/pictures"
|
||
XDG_VIDEOS_DIR="$HOME/videos"
|
||
#+end_src
|
||
|
||
* GTK/Theme Settings
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/gtk-3.0/settings.ini :mkdirp yes
|
||
[Settings]
|
||
gtk-cursor-theme-name=
|
||
gtk-theme-name=Arc-Dark
|
||
gtk-font-name=Fira Sans Regular
|
||
gtk-icon-theme-name=Papirus
|
||
gtk-cursor-theme-size=0
|
||
gtk-toolbar-style=GTK_TOOLBAR_BOTH
|
||
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||
gtk-button-images=1
|
||
gtk-menu-images=1
|
||
gtk-enable-event-sounds=1
|
||
gtk-enable-input-feedback-sounds=1
|
||
gtk-xft-antialias=1
|
||
gtk-xft-hinting=1
|
||
gtk-xft-hintstyle=hintfull
|
||
#+end_src
|
||
|
||
* Archive
|
||
** Sway
|
||
*** General
|
||
*** Include
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
include /gnu/store/6d3q9f1bdfn4cchsziws33ixq2p4zjhw-sway-1.6.1/etc/sway/config.d/*
|
||
#+end_src
|
||
*** Mod Key
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
set $mod Mod4
|
||
#+end_src
|
||
*** Directional Keys
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
set $left h
|
||
set $down j
|
||
set $up k
|
||
set $right l
|
||
#+end_src
|
||
*** Applications
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Terminal
|
||
set $term alacritty
|
||
|
||
# Application Launcher
|
||
set $menu wofi --hide-scroll --show drun | xargs swaymsg exec
|
||
#+end_src
|
||
*** Opacity
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
set $opacity 0.92
|
||
for_window [class=".*"] opacity $opacity
|
||
for_window [app_id=".*"] opacity $opacity
|
||
#+end_src
|
||
*** Borders and Gaps
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Window Borders
|
||
default_border none
|
||
|
||
# Gaps
|
||
gaps top 0
|
||
gaps inner 10
|
||
gaps outer 10
|
||
#+end_src
|
||
*** Notifications
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Dismiss notifications
|
||
bindsym Control+space exec makoctl dismiss
|
||
bindsym --locked $mod+d exec sh -c "notify-send 'Do Not Disturb' 'Turning on Do Not Disturb Mode'; sleep 2; makoctl set-mode do-not-disturb"
|
||
#+end_src
|
||
*** Mouse Behavior
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Hide mouse cursor after inactivity
|
||
seat * hide_cursor 4000
|
||
#+end_src
|
||
*** Autostart
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Notifications
|
||
exec_always dunst
|
||
|
||
# Wlsunset (Night Light)
|
||
exec_always wlsunset -l 47.6, -122.3 -t 3500 -T 6500
|
||
#+end_src
|
||
*** Wallpaper & Monitor(s)
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Monitors
|
||
# You can get the names of your outputs by running: swaymsg -t get_outputs
|
||
# output eDP-1 pos 0 0 res 1920x1200
|
||
# output DP-5 pos 3440 0 res 3440x1440
|
||
output eDP-1 pos 0 0 res 1920x1200
|
||
output DP-5 pos 1920 0 res 3440x1440
|
||
|
||
# Wallpaper
|
||
output DP-5 bg /home/opal/dotfiles/guix/home/files/wallpapers/fog-wallpaper.jpg fill
|
||
output eDP-1 bg /home/opal/dotfiles/guix/home/files/wallpapers/fog-wallpaper.jpg fill
|
||
#+end_src
|
||
|
||
*** Idle/Exit Behavior
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
### Idle configuration
|
||
# This will lock your screen after 300 seconds of inactivity, then turn off
|
||
# your displays after another 300 seconds, and turn your screens back on when
|
||
# resumed. It will also lock your screen before your computer goes to sleep.
|
||
exec swayidle -w \
|
||
timeout 600 'swaylock -f' \
|
||
timeout 1800 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
|
||
before-sleep 'swaylock -f'
|
||
|
||
# Exit sway (logs you out of your Wayland session)
|
||
bindsym $mod+Shift+e exec swaynag -t custom -m 'Do you wish to fully reload your Sway session?' -b 'Yes' 'swaymsg exit'
|
||
# Turn the system off
|
||
bindsym $mod+Shift+p exec swaynag -t custom -m 'What action would you like to perform?' -b 'Shutdown' 'poweroff' -b 'Restart' 'poweroff --reboot'
|
||
#+end_src
|
||
|
||
*** Input
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
### Input configuration
|
||
#
|
||
# Example configuration:
|
||
#
|
||
# input "2:14:SynPS/2_Synaptics_TouchPad" {
|
||
# dwt enabled
|
||
# tap enabled
|
||
# natural_scroll enabled
|
||
# middle_emulation enabled
|
||
# }
|
||
#
|
||
# You can get the names of your inputs by running: swaymsg -t get_inputs
|
||
# Read `man 5 sway-input` for more information about this section.
|
||
input type:keyboard {
|
||
# Capslock key should work as escape key
|
||
# See /usr/share/X11/xkb/rules/xorg.lst for options
|
||
xkb_options caps:escape
|
||
|
||
repeat_delay 250
|
||
repeat_rate 45
|
||
}
|
||
#+end_src
|
||
** Keybindings
|
||
*** General
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Start a terminal
|
||
bindsym $mod+Return exec $term
|
||
|
||
# Kill focused window
|
||
bindsym $mod+Shift+q kill
|
||
|
||
# Lock SwayWM
|
||
bindsym Control+Shift+l exec swaylock
|
||
|
||
# Start your launcher
|
||
bindsym $mod+d exec $menu
|
||
|
||
# Change normal to inverse to use left mouse button for resizing and right
|
||
# mouse button for dragging.
|
||
floating_modifier $mod normal
|
||
|
||
# Reload the configuration file
|
||
bindsym $mod+Shift+c reload
|
||
|
||
# Exit sway (logs you out of your Wayland session)
|
||
bindsym $mod+Shift+x exec swaymsg -r exit
|
||
#+end_src
|
||
*** Media/Brightness
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
## Volume
|
||
bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
|
||
bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
|
||
bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||
|
||
# Media playerctl
|
||
bindsym XF86AudioNext exec playerctl next
|
||
bindsym XF86AudioPrev exec playerctl previous
|
||
bindsym XF86AudioPlay exec playerctl play-pause
|
||
|
||
# Backlight
|
||
bindsym XF86MonBrightnessUp exec light -A 10 && notify-send " Light" "Brightness: $(light)%" --hint="int:value:$(light)"
|
||
bindsym XF86MonBrightnessDown exec light -U 10 && notify-send " Light" "Brightness: $(light)%" --hint="int:value:$(light)"
|
||
#+end_src
|
||
*** Navigation & Focus
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
|
||
# Moving around:
|
||
# Move your focus around
|
||
bindsym $mod+$left focus left
|
||
bindsym $mod+$down focus down
|
||
bindsym $mod+$up focus up
|
||
bindsym $mod+$right focus right
|
||
# Or use $mod+[up|down|left|right]
|
||
bindsym $mod+Left focus left
|
||
bindsym $mod+Down focus down
|
||
bindsym $mod+Up focus up
|
||
bindsym $mod+Right focus right
|
||
|
||
# Move the focused window with the same, but add Shift
|
||
bindsym $mod+Shift+$left move left
|
||
bindsym $mod+Shift+$down move down
|
||
bindsym $mod+Shift+$up move up
|
||
bindsym $mod+Shift+$right move right
|
||
# Ditto, with arrow keys
|
||
bindsym $mod+Shift+Left move left
|
||
bindsym $mod+Shift+Down move down
|
||
bindsym $mod+Shift+Up move up
|
||
bindsym $mod+Shift+Right move right
|
||
#+end_src
|
||
*** Workspaces
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Assign workspaces to variables
|
||
set $ws1 number 1
|
||
set $ws2 number 2
|
||
set $ws3 number 3
|
||
set $ws4 number 4
|
||
set $ws5 number 5
|
||
|
||
# Switch to workspace
|
||
bindsym $mod+1 workspace $ws1
|
||
bindsym $mod+2 workspace $ws2
|
||
bindsym $mod+3 workspace $ws3
|
||
bindsym $mod+4 workspace $ws4
|
||
bindsym $mod+5 workspace $ws5
|
||
|
||
# Move focused container to workspace
|
||
bindsym $mod+Shift+1 move container to workspace $ws1
|
||
bindsym $mod+Shift+2 move container to workspace $ws2
|
||
bindsym $mod+Shift+3 move container to workspace $ws3
|
||
bindsym $mod+Shift+4 move container to workspace $ws4
|
||
bindsym $mod+Shift+5 move container to workspace $ws5
|
||
#+end_src
|
||
*** Layout
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
# Layout stuff:
|
||
#
|
||
# You can "split" the current object of your focus with
|
||
# $mod+b or $mod+v, for horizontal and vertical splits
|
||
# respectively.
|
||
bindsym $mod+b splith
|
||
bindsym $mod+v splitv
|
||
|
||
# Switch the current container between different layout styles
|
||
bindsym $mod+s layout stacking
|
||
bindsym $mod+w layout tabbed
|
||
bindsym $mod+e layout toggle split
|
||
|
||
# Make the current focus fullscreen
|
||
bindsym $mod+f fullscreen
|
||
|
||
# Toggle the current focus between tiling and floating mode
|
||
bindsym $mod+Shift+space floating toggle
|
||
|
||
# Swap focus between the tiling area and the floating area
|
||
bindsym $mod+space focus mode_toggle
|
||
|
||
# Move focus to the parent container
|
||
bindsym $mod+a focus parent
|
||
#
|
||
# Scratchpad:
|
||
#
|
||
# Sway has a "scratchpad", which is a bag of holding for windows.
|
||
# You can send windows there and get them back later.
|
||
|
||
# Move the currently focused window to the scratchpad
|
||
bindsym $mod+Shift+minus move scratchpad
|
||
|
||
# Show the next scratchpad window or hide the focused scratchpad window.
|
||
# If there are multiple scratchpad windows, this command cycles through them.
|
||
bindsym $mod+minus scratchpad show
|
||
#
|
||
# Resizing containers:
|
||
#
|
||
mode "resize" {
|
||
# left will shrink the containers width
|
||
# right will grow the containers width
|
||
# up will shrink the containers height
|
||
# down will grow the containers height
|
||
bindsym $left resize shrink width 10px
|
||
bindsym $down resize grow height 10px
|
||
bindsym $up resize shrink height 10px
|
||
bindsym $right resize grow width 10px
|
||
|
||
# Ditto, with arrow keys
|
||
bindsym Left resize shrink width 10px
|
||
bindsym Down resize grow height 10px
|
||
bindsym Up resize shrink height 10px
|
||
bindsym Right resize grow width 10px
|
||
|
||
# Return to default mode
|
||
bindsym Return mode "default"
|
||
bindsym Escape mode "default"
|
||
}
|
||
bindsym $mod+r mode "resize"
|
||
|
||
#+end_src
|
||
** GTK Theme
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
exec_always import-gsettings \
|
||
gtk-theme:gtk-theme-name \
|
||
icon-theme:gtk-icon-theme-name \
|
||
cursor-theme:gtk-cursor-theme-name
|
||
#+end_src
|
||
** Swaybar
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/sway/config :mkdirp yes
|
||
#
|
||
# Status Bar:
|
||
#
|
||
# Read `man 5 sway-bar` for more information about this section.
|
||
bar {
|
||
swaybar_command waybar
|
||
# position top
|
||
# gaps 5
|
||
|
||
# # When the status_command prints a new line to stdout, swaybar updates.
|
||
# # The default just shows the current date and time.
|
||
# status_command while date +'%Y-%m-%d %l:%M:%S %p'; do sleep 1; done
|
||
|
||
# colors {
|
||
# statusline #ffffff
|
||
# background #323232
|
||
# inactive_workspace #32323200 #32323200 #5c5c5c
|
||
# }
|
||
}
|
||
|
||
|
||
#+end_src
|
||
** Swaylock
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/swaylock/config :mkdirp yes
|
||
# Image
|
||
image=/home/opal/guix/home/files/wallpapers/fog-wallpaper.jpg
|
||
scaling=fill
|
||
|
||
# Indicator
|
||
ignore-empty-password
|
||
indicator-caps-lock
|
||
|
||
# Behavior
|
||
show-failed-attempts
|
||
#+end_src
|
||
** Waybar
|
||
** waybar/config
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/waybar/config :mkdirp yes
|
||
{
|
||
"layer": "top", // Waybar at top layer
|
||
"position": "top", // Waybar at the bottom of your screen
|
||
"height": 24, // Waybar height
|
||
// "width": 1366, // Waybar width
|
||
// Choose the order of the modules
|
||
"modules-left": ["sway/workspaces", "sway/mode", "custom/spotify"],
|
||
"modules-center": ["sway/window"],
|
||
"modules-right": ["pulseaudio", "network", "cpu", "memory", "battery", "tray", "clock"],
|
||
// "sway/workspaces": {
|
||
// "disable-scroll": true,
|
||
// "all-outputs": false,
|
||
"format": "{icon}",
|
||
"format-icons": {
|
||
// "1:web": "",
|
||
// "2:code": "",
|
||
// "3:term": "",
|
||
// "4:work": "",
|
||
// "5:music": "",
|
||
// "6:docs": "",
|
||
"urgent": "",
|
||
"focused": "",
|
||
"default": ""
|
||
}
|
||
},
|
||
"sway/mode": {
|
||
"format": "<span style=\"italic\">{}</span>"
|
||
},
|
||
"tray": {
|
||
// "icon-size": 21,
|
||
"spacing": 10
|
||
},
|
||
"clock": {
|
||
"format-alt": "{:%Y-%m-%d}"
|
||
},
|
||
"cpu": {
|
||
"format": "{usage}% "
|
||
},
|
||
"memory": {
|
||
"format": "{}% "
|
||
},
|
||
"battery": {
|
||
"bat": "BAT0",
|
||
"states": {
|
||
// "good": 95,
|
||
"warning": 30,
|
||
"critical": 15
|
||
},
|
||
"format": "{capacity}% {icon}",
|
||
// "format-good": "", // An empty format will hide the module
|
||
// "format-full": "",
|
||
"format-icons": ["", "", "", "", ""]
|
||
},
|
||
"network": {
|
||
// "interface": "wlp2s0", // (Optional) To force the use of this interface
|
||
"format-wifi": "{essid} ({signalStrength}%) ",
|
||
"format-ethernet": "{ifname}: {ipaddr}/{cidr} ",
|
||
"format-disconnected": "Disconnected ⚠"
|
||
"on-click": "alacritty -e nmtui"
|
||
},
|
||
"pulseaudio": {
|
||
//"scroll-step": 1,
|
||
"format": "{volume}% {icon}",
|
||
"format-bluetooth": "{volume}% {icon}",
|
||
"format-muted": "",
|
||
"format-icons": {
|
||
"headphones": "",
|
||
"handsfree": "",
|
||
"headset": "",
|
||
"phone": "",
|
||
"portable": "",
|
||
"car": "",
|
||
"default": ["", ""]
|
||
},
|
||
"on-click": "pavucontrol"
|
||
},
|
||
"custom/spotify": {
|
||
"format": " {}",
|
||
"max-length": 40,
|
||
"interval": 30, // Remove this if your script is endless and write in loop
|
||
"exec": "$HOME/.config/waybar/mediaplayer.sh 2> /dev/null", // Script in resources folder
|
||
"exec-if": "pgrep spotify"
|
||
}
|
||
}
|
||
#+end_src
|
||
** waybar/style.css
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/waybar/style.css :mkdirp yes
|
||
\* {
|
||
border: none;
|
||
border-radius: 0;
|
||
font-family: "Fira Sans, normal";
|
||
font-size: 13px;
|
||
min-height: 0;
|
||
}
|
||
|
||
window#waybar {
|
||
background: transparent;
|
||
color: white;
|
||
}
|
||
|
||
#window {
|
||
font-weight: bold;
|
||
font-family: "Fira Sans, normal";
|
||
}
|
||
/*
|
||
#workspaces {
|
||
padding: 0 5px;
|
||
}
|
||
*/
|
||
|
||
#workspaces button {
|
||
padding: 0 5px;
|
||
background: transparent;
|
||
color: white;
|
||
border-top: 2px solid transparent;
|
||
}
|
||
|
||
#workspaces button.focused {
|
||
color: white;
|
||
border-top: 2px solid white;
|
||
}
|
||
|
||
#mode {
|
||
background: #64727D;
|
||
border-bottom: 3px solid white;
|
||
}
|
||
|
||
#clock, #battery, #cpu, #memory, #network, #pulseaudio, #custom-spotify, #tray, #mode {
|
||
padding: 0 3px;
|
||
margin: 0 2px;
|
||
}
|
||
|
||
#clock {
|
||
font-weight: bold;
|
||
}
|
||
|
||
#battery {
|
||
}
|
||
|
||
#battery icon {
|
||
color: red;
|
||
}
|
||
|
||
#battery.charging {
|
||
}
|
||
|
||
@keyframes blink {
|
||
to {
|
||
background-color: #ffffff;
|
||
color: black;
|
||
}
|
||
}
|
||
|
||
#battery.warning:not(.charging) {
|
||
color: white;
|
||
animation-name: blink;
|
||
animation-duration: 0.5s;
|
||
animation-timing-function: linear;
|
||
animation-iteration-count: infinite;
|
||
animation-direction: alternate;
|
||
}
|
||
|
||
#cpu {
|
||
}
|
||
|
||
#memory {
|
||
}
|
||
|
||
#network {
|
||
}
|
||
|
||
#network.disconnected {
|
||
background: #f53c3c;
|
||
}
|
||
|
||
#pulseaudio {
|
||
}
|
||
|
||
#pulseaudio.muted {
|
||
}
|
||
|
||
#custom-spotify {
|
||
color: rgb(102, 220, 105);
|
||
}
|
||
|
||
#tray {
|
||
}
|
||
#+end_src
|
||
** Wofi
|
||
** wofi/config
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/wofi/config :mkdirp yes
|
||
style=/home/opal/guix/home/files/wofi/style.css
|
||
xoffset=710
|
||
yoffset=275
|
||
show=drun
|
||
width=500
|
||
height=500
|
||
always_parse_args=true
|
||
show_all=true
|
||
print_command=true
|
||
layer=overlay
|
||
insensitive=true
|
||
prompt=
|
||
#+end_src
|
||
** wofi/style.css
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/wofi/style.css :mkdirp yes
|
||
window {
|
||
margin: 0px;
|
||
border: 2px solid #414868;
|
||
border-radius: 5px;
|
||
background-color: #24283b;
|
||
font-family: monospace;
|
||
font-size: 12px;
|
||
}
|
||
|
||
#input {
|
||
margin: 5px;
|
||
border: 1px solid #24283b;
|
||
color: #c0caf5;
|
||
background-color: #24283b;
|
||
}
|
||
|
||
#input image {
|
||
color: #c0caf5;
|
||
}
|
||
|
||
#inner-box {
|
||
margin: 5px;
|
||
border: none;
|
||
background-color: #24283b;
|
||
}
|
||
|
||
#outer-box {
|
||
margin: 5px;
|
||
border: none;
|
||
background-color: #24283b;
|
||
}
|
||
|
||
#scroll {
|
||
margin: 0px;
|
||
border: none;
|
||
}
|
||
|
||
#text {
|
||
margin: 5px;
|
||
border: none;
|
||
color: #c0caf5;
|
||
}
|
||
|
||
#entry:selected {
|
||
background-color: #414868;
|
||
font-weight: normal;
|
||
}
|
||
|
||
#text:selected {
|
||
background-color: #414868;
|
||
font-weight: normal;
|
||
}
|
||
#+end_src
|
||
** Swaynag
|
||
#+begin_src shell :tangle ~/dotfiles/guix/home/files/swaynag/config :mkdirp yes
|
||
[custom]
|
||
font=mononoki Nerd Font 10
|
||
dismiss-button=Dismiss
|
||
background=0f0f0f
|
||
border=262626
|
||
border-bottom=262626
|
||
button-background=262626
|
||
text=f0f0f0
|
||
border-bottom-size=2
|
||
message-padding=5
|
||
details-border-size=2
|
||
button-border-size=0
|
||
button-gap=5
|
||
button-dismiss-gap=5
|
||
button-margin-right=5
|
||
button-padding=5
|
||
#+end_src
|