Laptop files

This commit is contained in:
Aidan Sharpe 2024-08-26 11:05:11 -04:00
commit 9d5276524f
41 changed files with 981 additions and 0 deletions

BIN
eww/.cache.sqlite Normal file

Binary file not shown.

0
eww/= Normal file
View File

289
eww/eww.scss Normal file
View File

@ -0,0 +1,289 @@
/* --------------------------------------- Kanagawa Colors ------------------------------------*/
$wave_blue1: #2d4f67;
$autumn_red: #c34043;
$peach_red: #ff5d62;
$autumn_green: #66946a;
$carp_yellow: #e6c384;
$crystal_blue: #7e9cd8;
$oni_violet: #957fb8;
$fuji_white: #dcd7ba;
$old_white: #c8c093;
$sumi_ink0: #16161d;
$sumi_ink1: #1F1F28;
$sumi_ink4: #54546d;
$winter_blue: #252535;
* {
all: unset;
font-family: "Arimo Nerd Font";
font-weight: 400;
font-size: 16px;
}
/* --------------------------------------- Common Styles -------------------------------------- */
/* Style for module */
.module {
background: $winter_blue;
border-radius: 10px;
margin-right: 8px;
padding: 2px 15px;
}
.main_menu {
background: $winter_blue;
border-radius: 15px;
border: 2px solid $fuji_white;
}
.menu_item {
min-height: 50px;
font-size: 30px;
border-radius: 15px;
}
/* Remove the `margin-right` for the last module */
.last-widget {
margin-right: 0;
}
.bar_section {
background: rgba(31, 31, 40, 0.7);
padding: 5px 10px;
border-radius: 10px;
}
.main_menu_btn {
background: transparent;
border-radius: 10px;
padding: 0px 5px;
background-color: $winter_blue;
border-color: transparent;
box-shadow: 0px 0px;
}
.main_menu_label {
background-color: transparent;
color: $fuji_white;
font-size: 25;
text-shadow: 0px 0px;
}
.datetime {
color: $crystal_blue;
}
.weather {
color: $crystal_blue;
padding: 0px 10px;
}
tooltip.background {
background-color: $sumi_ink0;
font-size: 18;
border-radius: 10px;
color: $fuji_white;
}
.active_workspace {
background: transparent;
padding: 0 8px 0px 14px;
border-radius: 7px;
margin-top: 3px;
margin-bottom: 3px;
color: $crystal_blue;
}
.inactive_workspace {
background: transparent;
padding: 0 8px 0px 14px;
margin-top: 3px;
margin-bottom: 3px;
border-radius: 7px;
color: $sumi_ink4;
}
.workspaces {
padding: 0px 10px;
border-radius: 10px;
}
.updates {
color: $carp_yellow;
}
.cpu {
color: $crystal_blue;
}
.ram {
color: $autumn_green;
}
.datetime_module {
border-radius: 10px;
padding: 0px 15px;
}
.bardate {
margin-right: 10px;
}
.system_module {
background: rgba(22, 22, 30, 0.5);
padding: 0px 10px 0px 15px;
border-radius: 10px;
}
.volume {
box-shadow: 0px 0px;
color: $crystal_blue;
}
.volbar trough highlight {
border-radius: 10px;
background-color: $crystal_blue;
border: transparent;
}
scale trough {
border-radius: 10px;
min-height: 7px;
min-width: 100px;
border: transparent;
}
.sysinfo {
color: $crystal_blue;
}
.net_status {
color: $crystal_blue;
}
.power {
background-color: transparent;
border-radius: 10px;
text-shadow: 0px 0px;
border-color: transparent;
box-shadow: 0px 0px;
font-size: 25px;
}
.shutdown {
color: $autumn_red;
}
.restart {
color: $oni_violet;
}
.logout {
color: $carp_yellow;
}
.lock {
color: $crystal_blue;
}
.sleep {
color: $fuji_white;
}
/* -------------------------------------- Desktop Widget -------------------------------------- */
.desktop {
background-color: transparent;
}
.desktop_clock {
padding: 40px 35px;
}
.greeting {
font-size: 36px;
font-style: italic;
color: $crystal_blue;
}
.desktop_time {
font-weight: 700;
font-size: 96px;
}
.desktop_time_h, .desktop_time_m {
color: $autumn_red;
}
.desktop_time_colon {
color: $fuji_white;
}
.desktop_time_p {
color: $autumn_red;
}
.desktop_date_date {
margin-left: 10px;
}
.desktop_date {
font-weight: 700;
font-size: 32px;
color: $fuji_white;
}
.desktop_mode_button {
color: $autumn_red;
font-size: 96px;
}
/* -------------------------------------Powermenu Widget---------------------------------------*/
.powermenu {
border-radius: 10px;
border: 2px solid $fuji_white;
background: $winter_blue;
}
.powermenu_button {
background: transparent;
box-shadow: 0px 0px;
border: 2px;
padding: 12px;
margin: 5px;
}
.powermenu_button:nth-child(1) {
border-radius: 10px;
background: $oni_violet;
}
.powermenu_button:nth-child(2) {
border-radius: 10px;
background: $peach_red;
}
.powermenu_button:hover {
background: transparent;
padding: 10px;
}
.powermenu_button:nth-child(1):hover {
border: 2px solid $oni_violet;
}
.powermenu_button:nth-child(2):hover {
border: 2px solid $peach_red;
}
.powermenu_label_restart {
color: $fuji_white;
font-size: 32px;
}
.powermenu_label_poweroff {
color: $fuji_white;
font-size: 32px;
}

28
eww/eww.yuck Normal file
View File

@ -0,0 +1,28 @@
(include "widgets/bar.yuck")
(include "widgets/desktop.yuck")
(defvar eww "/bin/eww")
(defwindow bar
:monitor 0
:geometry (geometry :x "0%"
:y "0.5%"
:width "99%"
:height "2%"
:anchor "top center")
:stacking "fg"
:exclusive true
(bar)
)
(defwindow desktop
:monitor 0
:geometry (geometry :x "1%"
:y "2%"
:width "15%"
:height "93%"
:anchor "center right")
:stacking "fg"
:exclusive true
(desktop)
)

BIN
eww/images/fedora_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

BIN
eww/scripts/.cache.sqlite Normal file

Binary file not shown.

10
eww/scripts/audio.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/bash
MASTER_STATE=$(amixer sget Master | grep -Po "(?<=\[)(on)|(off)(?=\])" | head -n1)
if [ $MASTER_STATE = "off" ]
then
echo 0
else
echo $(amixer sget Master | grep -Po "(?<=\[)[[:digit:]]+(?=(%\]))" | head -n1)
fi

View File

@ -0,0 +1,5 @@
#! /bin/bash
workspace=$1
echo "Switching to workspace $workspace"
hyprctl dispatch workspace $workspace

3
eww/scripts/cpu_usage.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
echo "$(top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | awk '{print 100 - $1""}')"

3
eww/scripts/flatpak_updates.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
echo "$(flatpak update | grep -P '[[:digit:]]+\.' | awk '{sum = sum + 1 } END { print sum }')"

View File

@ -0,0 +1,3 @@
#!/bin/bash
hyprctl monitors -j | jq --raw-output .[0].activeWorkspace.id
socat -u UNIX-CONNECT:/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | stdbuf -o0 awk -F '>>|,' '/^workspace>>/{print $2}'

11
eww/scripts/get_workspaces.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/bash
spaces (){
WORKSPACE_WINDOWS=$(hyprctl workspaces -j | jq 'map({key: .id | tostring, value: .windows}) | from_entries')
seq 1 10 | jq --argjson windows "${WORKSPACE_WINDOWS}" --slurp -Mc 'map(tostring) | map({id: ., windows: ($windows[.]//0)})'
}
spaces
socat -u UNIX-CONNECT:/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | while read -r line; do
spaces
done

2
eww/scripts/lock.sh Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
swaylock -c 000000

11
eww/scripts/network.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/bash
net_status () {
if (ping -c 1 google.com || ping -c 1 archlinux.org || ping -c 1 github.com) &> /dev/null; then
echo true;
else
echo false;
fi
}
net_status

3
eww/scripts/ram_usage.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
free -m | awk 'NR==2{printf "%.2f\n", $3*100/$2 }'

16
eww/scripts/rx_bandwidth.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
DEV=`nmcli d | grep -P "[^(dis)]connected [^(\(externally\))]" | grep -Po ".*?(?= )" | head -n1`
RX_BYTES=`cat /sys/class/net/$DEV/statistics/rx_bytes`
RX_KB=`expr $RX_BYTES / 1024`
RX_MB=`expr $RX_KB / 1024`
if [ $RX_MB -ge 1 ]
then
echo $RX_MB mB/s
elif [ $RX_KB >= 1 ]
then
echo $RX_KB kB/s
else
echo $RX_BYTES B/s
fi

2
eww/scripts/speakerstate.sh Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
amixer sget Master | grep -Po '(?<=\[)off(?=\])' | head -n1

17
eww/scripts/tx_bandwidth.sh Executable file
View File

@ -0,0 +1,17 @@
#!/bin/bash
DEV=`nmcli d | grep -P "[^(dis)]connected [^(\(externally\))]" | grep -Po ".*?(?= )" | head -n1`
TX_BYTES=$(cat /sys/class/net/$DEV/statistics/tx_bytes)
TX_KB=`expr $TX_BYTES / 1024`
TX_MB=`expr $TX_KB / 1024`
if [ $TX_MB -ge 1 ]
then
echo $TX_MB mB/s
elif [ $TX_KB -ge 1 ]
then
echo $TX_KB kB/s
else
echo $TX_BYTES B/s
fi

76
eww/scripts/weather.py Normal file
View File

@ -0,0 +1,76 @@
import openmeteo_requests
import requests_cache
from retry_requests import retry
import requests
import sys
conditions = {
0: "",
1: "",
2: "",
3: "",
45: "",
48: "",
51: "",
53: "",
55: "",
61: "",
63: "",
65: "",
71: "",
73: "",
75: "",
95: "",
96: "",
99: "",
}
latitude, longitude = eval(requests.get("https://ipinfo.io/loc").text)
city = requests.get("https://ipinfo.io/city").text.strip()
cache_session = requests_cache.CachedSession('.cache', expire_after=3600)
retry_session = retry(cache_session, retries=5, backoff_factor = 0.2)
openmeteo = openmeteo_requests.Client(session = retry_session)
url = "https://api.open-meteo.com/v1/forecast"
params = {
"latitude": latitude,
"longitude": longitude,
"current": ["is_day", "weather_code", "temperature_2m"],
"temperature_unit": "fahrenheit",
"wind_speed_unit": "mph",
"precipitation_unit": "inch"
}
responses = openmeteo.weather_api(url, params=params)
response = responses[0]
current = response.Current()
current_is_day = bool(current.Variables(0).Value())
current_weather_code = int(current.Variables(1).Value())
current_temperature = int(current.Variables(2).Value())
print(f"{city} {conditions[current_weather_code]} {current_temperature}°F")
#try:
#location_info = weather_json["properties"]["relativeLocation"]["properties"]
#except KeyError:
#if weather_json["status"] == 404:
#print("NOAA only supports U.S. locations")
#city = location_info["city"]
#state = location_info["state"]
#forecast_url = weather_json["properties"]["forecast"]
#forecast_json = requests.get(forecast_url).json()
#current_forecast = forecast_json["properties"]["periods"][0]
#temperature = current_forecast["temperature"]
#temperature_units = current_forecast["temperatureUnit"]
#short_forecast = current_forecast["shortForecast"]
#try:
#print(f"{city}, {state} {conditions[short_forecast]} {temperature}°{temperature_units}")
#except KeyError:
#print(f"{city}, {state} {short_forecast} {temperature}°{temperature_units}")

8
eww/scripts/workspace_class.sh Executable file
View File

@ -0,0 +1,8 @@
ACTIVE=$(hyprctl activeworkspace | grep -Po '(?<=ID )[[:digit:]]')
if [ $ACTIVE -eq $1 ]
then
echo "active_workspace"
else
echo "inactive_workspace"
fi

42
eww/scripts/workspaces.sh Executable file
View File

@ -0,0 +1,42 @@
#!/usr/bin/env bash
# Checks if a list ($1) contains an element ($2)
contains() {
for e in $1; do
[[ "$e" -eq "$2" ]] && echo 1 && return
done
echo 0
}
print_workspaces() {
local buf=""
local desktops=$(bspc query -D --names)
local focused_desktop=$(bspc query -D -d focused --names)
local occupied_desktops=$(bspc query -D -d .occupied --names)
for d in $desktops; do
if [[ "$(contains "$focused_desktop" "$d")" -eq 1 ]]; then
local ws=$d
local icon=""
local class="workspace-focused"
elif [[ "$(contains "$occupied_desktops" "$d")" -eq 1 ]]; then
local ws=$d
local icon=""
local class="workspace-occupied"
else
local ws="$d"
local icon=""
local class="workspace-empty"
fi
local buf+="(eventbox :cursor \"pointer\" (button :class \"$class\" :onclick \"bspc desktop -f $ws\" \"$icon\"))"
done
echo "(box :orientation \"h\" :class \"works\" :halign \"center\" :halign \"center\" :hexpand true :vexpand true $buf)"
}
# Listen to bspwm changes
print_workspaces
bspc subscribe desktop node_transfer | while read -r _; do
print_workspaces &
done

28
eww/widgets/bar.yuck Normal file
View File

@ -0,0 +1,28 @@
(include "widgets/date_time.yuck")
(include "widgets/nowplaying.yuck")
(include "widgets/divider.yuck")
(include "widgets/quick_power.yuck")
(include "widgets/workspaces.yuck")
(include "widgets/system_info.yuck")
(include "widgets/desktop_button.yuck")
(include "widgets/weather.yuck")
(defwidget bar []
(box :orientation "h" :class "bar" :spacing "10" :space-evenly false
(centerbox :orientation "h" :hexpand true :class "center bar_section"
(box :class "left" :halign "start"
(workspaces)
)
(box :class "center" :halign "end"
)
(box :halign "end" :space-evenly "false"
(weather)
(systeminfo)
(date_time)
)
)
(box :class "right bar_section" :halign "end" :space-evenly false
(quickpower)
)
)
)

View File

3
eww/widgets/cava.yuck Normal file
View File

@ -0,0 +1,3 @@
(defwidget cava []
)

View File

@ -0,0 +1,30 @@
(defpoll day :interval "1s" `date +\"%A\"`)
(defpoll month :interval "1s" `date +\"%b\"`)
(defpoll date :interval "1s" `date +\"%d\"`)
(defpoll h :interval "1s" `date +\"%H\"`)
(defpoll m :interval "1s" `date +\"%M\"`)
(defpoll s :interval "1s" `date +\"%S\"`)
(defvar show_date false)
(defwidget date_time []
(eventbox :onhover "${eww} update show_date=true" :onhoverlost "${eww} update show_date=false"
(box :class "datetime_module" :space-evenly "false"
(revealer :reveal show_date :transition "slideleft"
(box :class "bardate" :space-evenly "false" :orientation "h" :spacing "2"
(label :text day :class "datetime")
(label :text ", " :class "datetime")
(label :text month :class "datetime")
(label :text " ")
(label :text date :class "datetime")
)
)
(box :space-evenly "false" :orientation "h" :spacing "2"
(label :text h :class "datetime" )
(label :text ":" :class "datetime" )
(label :text m :class "datetime")
)
)
)
)

7
eww/widgets/desktop.yuck Normal file
View File

@ -0,0 +1,7 @@
(include "widgets/desktop_clock.yuck")
(defwidget desktop []
(box :class "bar_section" :orientation "v" :space-evenly "false" :spacing "3"
(desktop_clock)
)
)

View File

@ -0,0 +1,5 @@
(defwidget desktopbutton []
(eventbox :onclick "${eww} open desktop --toggle" :tooltip "Toggle Desktop Menu"
(image :path "/home/sharpe/.config/eww/images/kanagawa-button.png" :image-width 20)
)
)

View File

@ -0,0 +1,18 @@
(defpoll p :interval "1s" `date +\"%p\"`)
(defpoll I :interval "1s" `date +\"%I\"`)
(defwidget desktop_clock []
(eventbox
(box :class "desktop_clock" :space-evenly "false" :orientation "v" :spacing "3"
(box :space-evenly "false" :orientation "h" :spacing "3" :halign "center"
(label :text I :class "desktop_time desktop_time_h")
(label :text " :" :class "desktop_time desktop_time_colon")
(label :text m :class "desktop_time desktop_time_m")
(label :text " " :class "desktop_time")
(label :text p :class "desktop_time desktop_time_p"))
(box :class "desktop_date_box" :space-evenly "false" :orientation "h" :spacing "3" :halign "center"
(label :text day :class "desktop_date desktop_date_day")
(label :text ", " :class "desktop_date desktop_date_comma")
(label :text month :class "desktop_date desktop_date_month")
(label :text " " :class "desktop_date")
(label :text date :class "desktop_date desktop_date_date")))))

View File

@ -0,0 +1,7 @@
(defwidget desktop_mode []
(box
(button :class "desktop_mode_button" "󰺗")
(button :class "desktop_mode_button" "")
(button :class "desktop_mode_button" "󰼬")
)
)

5
eww/widgets/divider.yuck Normal file
View File

@ -0,0 +1,5 @@
(defwidget divider []
(box
(label :text "|")
)
)

View File

@ -0,0 +1,8 @@
(defwidget nowplaying []
(eventbox
(box :space-evenly "false"
(label :class "weather" :text "Now Playing")
)
)
)

View File

View File

@ -0,0 +1,17 @@
(defvar power_reveal false)
(defwidget quickpower []
(eventbox :onhover "${eww} update power_reveal=true" :onhoverlost "${eww} update power_reveal=false"
(box :space-evenly "false"
(revealer :reveal power_reveal :transition "slideright"
(box
;(button :class "power sleep" :onclick "systemctl suspend" :tooltip "Sleep" "󰤄 ")
(button :class "power lock" :onclick "bash ./scripts/lock.sh" :tooltip "Lock" " ")
(button :class "power logout" :onclick "hyprctl dispatch exit" :tooltip "Logout" "󰍃 ")
(button :class "power restart" :onclick "reboot" :tooltip "Restart" " ")
)
)
(button :class "power shutdown" :onclick "shutdown now" :tooltip "Shut Down" "󰐥")
)
)
)

View File

@ -0,0 +1,54 @@
(defpoll volume :interval "0.5s" `bash $HOME/.config/eww/scripts/audio.sh` )
(defpoll speaker_state :interval "1s" `bash $HOME/.config/eww/scripts/speakerstate.sh`)
(defpoll net_status :interval "60s" `bash $HOME/.config/eww/scripts/network.sh`)
(defpoll net_name :interval "60s" `nmcli | grep -Po '(?<=connected to ).*'`)
(defpoll rx_bandwidth :interval "5s" `bash $HOME/.config/eww/scripts/rx_bandwidth.sh`)
(defpoll tx_bandwidth :interval "5s" `bash $HOME/.config/eww/scripts/tx_bandwidth.sh`)
(defpoll battery :interval "10s" `cat /sys/class/power_supply/BAT0/capacity`)
(defpoll battery_status :interval "5s" `cat /sys/class/power_supply/BAT0/status`)
(defvar net_reveal false)
(defvar vol_reveal false)
(defwidget systeminfo []
(box :space-evenly "false" :class "system_module" :spacing 5
(box :space-evenly false :tooltip "${battery}%"
(label :class "sysinfo" :text {battery > 10 ? "" : ""})
(label :class "sysinfo" :text {battery > 90 ? " " : battery > 65 ? " " : battery > 40 ? " " : battery > 15 ? " " : " "})
(label :class "sysinfo" :text {battery_status == "Charging" ? "󱐋" : ""})
)
(eventbox :onhover "${eww} update vol_reveal=true" :onhoverlost "${eww} update vol_reveal=false"
(box :space-evenly "false"
(label :class "volume" :text {volume > 50 ? " " : volume > 0 ? " ": " "})
(revealer :reveal vol_reveal :transition "slideright"
(scale :class "volbar"
:value volume
:orientation "h"
:tooltip "${volume}%"
:max 100
:min 0
:onchange "amixer sset Master {}%"
)
)
)
)
(eventbox :onhover "${eww} update net_reveal=true" :onhoverlost "${eww} update net_reveal=false"
(box :space-evenly "false" :tooltip net_name
(label :class "net_status" :text { net_status ? "󰖩 " : "󰖪 " })
(revealer :reveal net_reveal :transition "slideright"
(box :space-evenly false
(label :class "net_status" :text "")
(label :class "net_status" :text tx_bandwidth)
(label :class "net_status" :text "")
(label :class "net_status" :text rx_bandwidth)
)
)
)
)
)
)

7
eww/widgets/updates.yuck Normal file
View File

@ -0,0 +1,7 @@
(defpoll update_no :interval "60s" `bash /home/sharpe/.config/eww/scripts/flatpak_updates.sh`)
(defwidget updates []
(box :class "module" :space-evenly "false" :orientation "h" :spacing "3"
(label :text " " :class "updates")
(label :text update_no :class "updates" )
(label :text "package updates" :class "updates")))

5
eww/widgets/weather.yuck Normal file
View File

@ -0,0 +1,5 @@
(defpoll weather :interval "10m" `python scripts/weather.py`)
(defwidget weather []
(label :class "weather" :text weather)
)

View File

@ -0,0 +1,26 @@
(defpoll workspace_1 :interval "0.1s" "bash scripts/workspace_class.sh 1")
(defpoll workspace_2 :interval "0.1s" "bash scripts/workspace_class.sh 2")
(defpoll workspace_3 :interval "0.1s" "bash scripts/workspace_class.sh 3")
(defpoll workspace_4 :interval "0.1s" "bash scripts/workspace_class.sh 4")
(defpoll workspace_5 :interval "0.1s" "bash scripts/workspace_class.sh 5")
(defpoll workspace_6 :interval "0.1s" "bash scripts/workspace_class.sh 6")
(defpoll workspace_7 :interval "0.1s" "bash scripts/workspace_class.sh 7")
(defpoll workspace_8 :interval "0.1s" "bash scripts/workspace_class.sh 8")
(defpoll workspace_9 :interval "0.1s" "bash scripts/workspace_class.sh 9")
( defwidget workspaces []
(eventbox
(box :space-evenly "false" :orientation "h" :spacing "0"
(button :class workspace_1 :onclick "hyprctl dispatch workspace 1" "₁")
(button :class workspace_2 :onclick "hyprctl dispatch workspace 2" "󰖟₂")
(button :class workspace_3 :onclick "hyprctl dispatch workspace 3" "󰭹₃")
(button :class workspace_4 :onclick "hyprctl dispatch workspace 4" "₄")
(button :class workspace_5 :onclick "hyprctl dispatch workspace 5" "󰊴₅")
(button :class workspace_6 :onclick "hyprctl dispatch workspace 6" "₆")
(button :class workspace_7 :onclick "hyprctl dispatch workspace 7" "₇")
(button :class workspace_8 :onclick "hyprctl dispatch workspace 8" "₈")
(button :class workspace_9 :onclick "hyprctl dispatch workspace 9" "₉")
)
)
)

214
hypr/hyprland.conf Normal file
View File

@ -0,0 +1,214 @@
# This is an example Hyprland config file.
#
# Refer to the wiki for more information.
#
# Please note not all available settings / options are set here.
# For a full list, see the wiki
#
# See https://wiki.hyprland.org/Configuring/Monitors/
monitor=eDP-1,1920x1080,auto,1
monitor=HDMI-A-1,1920x1080,auto,1
monitor=eDP-2,1920x1080,auto,1
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
# Execute your favorite apps at launch
exec-once = hyprpaper
exec-once = mako
exec-once = brave-browser
exec-once = kitty
exec-once = eww open bar
# Source a file (multi-file configs)
# source = ~/.config/hypr/myColors.conf
# Some default env vars.
#env = XCURSOR_SIZE,24
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
input {
kb_layout = us
kb_variant =
kb_model =
kb_options =
kb_rules =
follow_mouse = 1
touchpad {
natural_scroll = false
disable_while_typing = false
}
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
}
general {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
gaps_in = 5
gaps_out = 10
border_size = 0
layout = dwindle
}
decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 10
blur {
size = 5
passes = 2
}
drop_shadow = true
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
}
animations {
enabled = true
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
bezier = boing, 1, -0.5, 0, 1.1
animation = windows, 1, 7, myBezier, slide
animation = windowsOut, 1, 7, myBezier, slide
#animation = border, 1, 10, default
#animation = borderangle, 1, 8, default
#animation = fade, 1, 7, default
animation = workspaces, 1, 5, myBezier
}
dwindle {
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
pseudotile = true # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
preserve_split = true # you probably want this
}
master {
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
new_is_master = true
}
gestures {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
workspace_swipe = false
}
# Example per-device config
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
device {
name = synaptics-tm3625-010
sensitivity = 0
}
misc {
focus_on_activate = true
}
# Example windowrule v1
# windowrule = float, ^(kitty)$
# Example windowrule v2
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
$mainMod = SUPER
bind = $mainMod, d, exec, eww open desktop --toggle
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
bind = $mainMod, RETURN, exec, kitty
bind = $mainMod, Q, killactive,
bind = $mainMod, E, exec, nautilus
bind = $mainMod, V, togglefloating,
bind = $mainMod, R, exec, rofi -show drun
bind = $mainMod, P, pseudo, # dwindle
bind = $mainMod, semicolon, togglesplit, # dwindle
# Move focus with mainMod + arrow keys
bind = $mainMod, h, movefocus, l
bind = $mainMod, l, movefocus, r
bind = $mainMod, k, movefocus, u
bind = $mainMod, j, movefocus, d
# Switch workspaces with mainMod + [0-9]
bind = $mainMod, 1, workspace, 1
bind = $mainMod, 2, workspace, 2
bind = $mainMod, 3, workspace, 3
bind = $mainMod, 4, workspace, 4
bind = $mainMod, 5, workspace, 5
bind = $mainMod, 6, workspace, 6
bind = $mainMod, 7, workspace, 7
bind = $mainMod, 8, workspace, 8
bind = $mainMod, 9, workspace, 9
bind = $mainMod, 0, workspace, 10
# Move active window to a workspace with mainMod + SHIFT + [0-9]
bind = $mainMod SHIFT, 1, movetoworkspace, 1
bind = $mainMod SHIFT, 2, movetoworkspace, 2
bind = $mainMod SHIFT, 3, movetoworkspace, 3
bind = $mainMod SHIFT, 4, movetoworkspace, 4
bind = $mainMod SHIFT, 5, movetoworkspace, 5
bind = $mainMod SHIFT, 6, movetoworkspace, 6
bind = $mainMod SHIFT, 7, movetoworkspace, 7
bind = $mainMod SHIFT, 8, movetoworkspace, 8
bind = $mainMod SHIFT, 9, movetoworkspace, 9
bind = $mainMod SHIFT, 0, movetoworkspace, 10
bind = $mainMod CONTROL, 1, movetoworkspacesilent, 1
bind = $mainMod CONTROL, 2, movetoworkspacesilent, 2
bind = $mainMod CONTROL, 3, movetoworkspacesilent, 3
bind = $mainMod CONTROL, 4, movetoworkspacesilent, 4
bind = $mainMod CONTROL, 5, movetoworkspacesilent, 5
bind = $mainMod CONTROL, 6, movetoworkspacesilent, 6
bind = $mainMod CONTROL, 7, movetoworkspacesilent, 7
bind = $mainMod CONTROL, 8, movetoworkspacesilent, 8
bind = $mainMod CONTROL, 9, movetoworkspacesilent, 9
bind = $mainMod CONTROL, 0, movetoworkspacesilent, 10
bind = $mainMod, -, movetoworkspacesilent, name:minimized
bind = $mainMod, SPACE, swapnext
# Change brightness
bind = ,XF86MonBrightnessUp, exec, brightnessctl set +5%
bind = ,XF86MonBrightnessDown, exec, brightnessctl set 5%-
# Change volume
bind = ,XF86AudioRaiseVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ +10%
bind = ,XF86AudioLowerVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ -10%
bind = ,XF86AudioMute, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle
bind = ,XF86AudioMicMu, exec, pactl set-source-mute @DEFAULT_SOURCE@ toggle
bind = ,Print, exec, grim -g "$(slurp)"
bind = $mainMod, C, exec, hyprpicker -a
# Scroll through existing workspaces with mainMod + scroll
bind = $mainMod, mouse_down, workspace, e+1
bind = $mainMod, mouse_up, workspace, e-1
# Move/resize windows with mainMod + LMB/RMB and dragging
bindm = $mainMod, mouse:272, movewindow
bindm = $mainMod, mouse:273, resizewindow
# MATLAB
windowrulev2 = nofocus, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(Command HistoryWindow)$
windowrulev2 = noborder, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(Command HistoryWindow)$
windowrulev2 = opacity 1.0 override, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(Command HistoryWindow)$
windowrulev2 = nofocus, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(TabCompletionPopup)$
windowrulev2 = noborder, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(TabCompletionPopup)$
windowrulev2 = opacity 1.0 override, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(TabCompletionPopup)$
windowrulev2 = nofocus, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(FunctionHints)$
windowrulev2 = noborder, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(FunctionHints)$
windowrulev2 = opacity 1.0 override, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(FunctionHints)$
windowrulev2 = nofocus, class: ^(MATLAB [\w\d]* - academic use)$, title: ^(DefaultOverlayManager\.JWindow)$

17
hypr/hyprpaper.conf Normal file
View File

@ -0,0 +1,17 @@
preload = ~/Pictures/Wallpapers/PerfectSunrise.jpg
#20230726_190706.jpg
#BeachTahoe.jpg
#fuji.jpg
#if more than one preload is desired then continue to preload other backgrounds
#preload = /path/to/next_image.png
# .. more preloads
#set the default wallpaper(s) seen on inital workspace(s) --depending on the number of monitors used
wallpaper = ,~/Pictures/Wallpapers/PerfectSunrise.jpg
#20230726_190706.jpg
#BeachTahoe.jpg
#kanagawa-custom-border-1.png
#fuji.jpg
#if more than one monitor in use, can load a 2nd image
#wallpaper = monitor2,/path/to/next_image.png
# .. more monitors

1
nvim Submodule

@ -0,0 +1 @@
Subproject commit c287608bf4a6058e956ff941149f8cca7ae55daf