This commit is contained in:
2023-10-22 06:12:10 +02:00
commit 314ff2f75d
69 changed files with 6951 additions and 0 deletions

117
.config/eww/eww.scss Executable file
View File

@@ -0,0 +1,117 @@
/*
*
* Catppuccin Frappe palette
* Maintainer: rubyowo
*
*/
$base: #303446;
$mantle: #292c3c;
$crust: #232634;
$text: #c6d0f5;
$subtext0: #a5adce;
$subtext1: #b5bfe2;
$surface0: #414559;
$surface1: #51576d;
$surface2: #626880;
$overlay0: #737994;
$overlay1: #838ba7;
$overlay2: #949cbb;
$blue: #8caaee;
$lavender: #babbf1;
$sapphire: #85c1dc;
$sky: #99d1db;
$teal: #81c8be;
$green: #a6d189;
$yellow: #e5c890;
$peach: #ef9f76;
$maroon: #ea999c;
$red: #e78284;
$mauve: #ca9ee6;
$pink: #f4b8e4;
$flamingo: #eebebe;
$rosewater: #f2d5cf;
/*
* Author: Keule2
* Created: 23.09.2023
*/
/*****************/
/* Defaults */
/*****************/
* {
border: none;
border-radius: 5px;
font-family: "FiraCode Nerd Font Mono";
font-weight: bold;
font-size: 13px;
color: $text;
}
window {
background: transparent;
}
tooltip{
background: $surface0;
border: solid 2px $sapphire;
}
button {
padding: 2px;
margin: 4px 2px;
}
.widget {
border: solid 2px $sapphire;
background: $surface1;
padding: 0px 5px;
margin: 2px;
box-shadow: none;
}
/*****************/
/* Root */
/*****************/
.bar1, .bar2, .bar3{
background-color: rgba(65, 69, 89, 0.8);
border-top-left-radius: 0px;
border-top-right-radius: 0px;
}
.root {
margin: 2px;
padding: 2px;
}
/*****************/
/* Cutom widgets */
/*****************/
/* Player */
.Playing {
color: $sapphire;
}
/* Session */
.session {
font-size: 24px;
}
/* Workspaces */
.workspace_entry {
padding: 2px 5px;
margin: 2px;
}
.workspace_entry.current {
background: $overlay0;
}
.workspace_entry_p:hover .workspace_entry{
background: $overlay2;
}

216
.config/eww/eww.yuck Executable file
View File

@@ -0,0 +1,216 @@
;; TODO Update workspaces only when workspaces updated
;; TODO Camera access, Microphone access,.... -> indicator-mic-cam
(defwindow bar1
:monitor 0
:geometry (geometry :x "0%"
:y "0px"
:width "100%"
:height "35px"
:anchor "top center")
:stacking "fg"
:exclusive true
:focusable false
(content)
)
(defwindow bar2
:monitor 1
:geometry (geometry :x "0%"
:y "0px"
:width "100%"
:height "35px"
:anchor "top center")
:stacking "fg"
:exclusive true
:focusable false
(content)
)
(defwindow bar3
:monitor 2
:geometry (geometry :x "0%"
:y "0px"
:width "100%"
:height "35px"
:anchor "top center")
:stacking "fg"
:exclusive true
:focusable false
(content)
)
(defwidget content []
(centerbox :orientation "h" :class "root"
(box :space-evenly false :halign "start"
(workspaces)
(window_w)
)
(time :halign "center")
(box :space-evenly false :halign "end"
(systray :class "widget systray")
(player)
(cpu)
(memory)
(network)
(battery)
(audio)
(session)
)
)
)
;;PLAYER
(deflisten MUSIC :initial "" "playerctl -a metadata --follow --format '{\"text\":\"{{artist}} - {{markup_escape(title)}}\", \"state\":\"{{status}}\"}' || true")
(defwidget player []
(box :class "widget"
(eventbox
:onclick "playerctl play-pause"
:onmiddleclick "playerctl previous"
:onrightclick "playerctl next"
(label :tooltip "${MUSIC.text}" :class "${MUSIC.state}" :text "󰒮 󰐌 󰒭")
)
)
)
;;CPU
(defwidget cpu []
(box :class "widget"
(label :text "${round(EWW_CPU.avg, 0)}% ")
)
)
;;Memory
(defwidget memory []
(box :class "widget"
(label :text "${round(EWW_RAM.used_mem / (1024*1024*1024), 1)} " :tooltip "${round(EWW_RAM.used_mem_perc, 0)}%")
)
)
;;Network
(defpoll IS_WIRELESS :interval "10s" "~/.config/eww/scripts/net.sh iswlan")
(defpoll NET_INT :interval "10s" "~/.config/eww/scripts/net.sh getint")
(defpoll NET_NAME :interval "10s" "~/.config/eww/scripts/net.sh ssid")
(defwidget network []
(box :class "widget"
(eventbox :onclick "nm-connection-editor & disown"
(label :text "${round(EWW_NET[NET_INT].NET_UP / 1000, 1)}kB/s⇡ ${round(EWW_NET[NET_INT].NET_DOWN / 1000, 1)}kB/s⇣ ${IS_WIRELESS? "" : ""}" :tooltip "${NET_INT} ${IS_WIRELESS? ":${NET_NAME}" : ""}")
)
)
)
(defpoll BAT_INFO :interval "1m" "~/.config/eww/scripts/battery.sh")
(defwidget battery []
(box :class "widget" :visible "${BAT_INFO.has_battery}"
(label :text "${BAT_INFO.percentage}"
:tooltip "${BAT_INFO.time_remaining}"
)
)
)
(defwindow battery_warning
:monitor 0
:exclusive "false"
:stacking "overlay"
:geometry (geometry :anchor "center"
:width "10%"
:height "10%")
(box :class "widget" :orientation "v"
(label :text "${BAT_INFO.percentage}!"
:tooltip "${BAT_INFO.time_remaining}"
)
(button :onclick "${EWW_CMD} close battery_warning"
(label :text "")
)
)
)
;;Audio
(defpoll DEF_SINK :interval "10s" "~/.config/eww/scripts/audio.sh getdefaultsink")
(defpoll IS_MUTED_SOURCE :interval "10s" "~/.config/eww/scripts/audio.sh ismutedsource @DEFAULT_SOURCE@")
(defpoll IS_MUTED_SINK :interval "10s" "~/.config/eww/scripts/audio.sh ismutedsink @DEFAULT_SINK@")
(defpoll IS_BLUE :interval "10s" "~/.config/eww/scripts/audio.sh isblue @DEFAULT_SINK@")
(defpoll VOLUME_SOURCE :interval "10s" "~/.config/eww/scripts/audio.sh getvol @DEFAULT_SOURCE@")
(defpoll VOLUME_SINK :interval "10s" "~/.config/eww/scripts/audio.sh getvol @DEFAULT_SINK@")
(defwidget audio []
(box :class "widget"
(eventbox
:onclick "${EWW_CMD} open audio_popup"
:onmiddleclick "~/.config/eww/scripts/audio.sh mutesink @DEFAULT_SINK@"
:onrightclick "~/.config/eww/scripts/audio.sh mutesource @DEFAULT_SOURCE@"
:onscroll "~/.config/eww/scripts/audio.sh vol {}"
(label :text "${IS_MUTED_SINK? " ": "${round(VOLUME_SINK * 100, 0)}%"}${IS_BLUE? "" : ""} ${IS_MUTED_SOURCE? "" : "${round(VOLUME_SOURCE * 100, 0)}%"}"
:tooltip "${DEF_SINK}"
)
)
)
)
(defwindow audio_popup
:monitor 0
:exclusive "false"
:stacking "overlay"
:geometry (geometry :anchor "top right")
(audio_menu)
)
(defpoll audio_device :interval "10s" "~/.config/eww/scripts/audio.sh getdevices")
(defwidget audio_menu []
(eventbox :onhoverlost "${EWW_CMD} close audio_popup"
(box :class "widget" :orientation "v"
(for dev in audio_device
(button :onclick "pactl set-default-sink ${dev.id} & ${EWW_CMD} close audio_popup"
(label :text "${dev.name == DEF_SINK? "" : ""} ${dev.name}")
)
)
)
)
)
;;Session
(defwidget session []
(box :class "widget"
(eventbox :onclick "swaync-client -t -sw"
(label :class "session" :text "")
)
)
)
;; Time/Date
(defpoll TIME :interval "5s" `date +\"%H:%M\"`)
(defpoll DATE :interval "1m" `date +\"%d.%m.%Y\"`)
(defwidget time []
(box :class "widget" :space-evenly false
(eventbox :onclick "merkuro-calendar & disown"
(label :text "${TIME}  ${DATE} ")
)
)
)
;; Active Window Title
(deflisten window :initial "..." "sh ~/.config/eww/scripts/get_window_title.sh")
(defwidget window_w []
(box :class "widget" :visible {window != ""}
(label :limit-width 85 :text "${window}")
)
)
;; Workspaces
(deflisten workspaces :initial "[]" "bash ~/.config/eww/scripts/get_workspaces.sh")
(deflisten current_workspace :initial "1" "bash ~/.config/eww/scripts/get_active_workspace.sh")
(defwidget workspaces []
(box :class "widget workspaces" :space-evenly false
(for workspace in workspaces
(eventbox :onclick "hyprctl dispatch workspace ${workspace.id}" :class "workspace_entry_p"
(box :class "workspace_entry ${workspace.id == current_workspace ? "current" : ""} ${workspace.windows > 0 ? "occupied" : "empty"}"
(label :class "test" :text "${workspace.id}")
)
)
)
)
)

76
.config/eww/scripts/audio.sh Executable file
View File

@@ -0,0 +1,76 @@
#!/bin/bash
usage() {
echo "Usage:
$0 <action> <sink|source>
actions: vol"
}
if [ -z $1 ]; then
usage
exit 1
fi
if [ -z $2 ] && [ "$1" != "getdevices" ] && [ "$1" != "getdefaultsink" ]; then
usage
exit 1
fi
vol() {
if [ "$1" == "up" ]; then
vol="5%+"
else
vol="5%-"
fi
wpctl set-volume @DEFAULT_SINK@ $vol
eww update VOLUME_SINK=$(getvol @DEFAULT_SINK@)
}
getvol() {
wpctl get-volume $1 | awk '{print $2}'
}
ismutedsource() {
pactl get-source-mute $1 | awk '{print ($2 == "no"? "false" : "true")}'
}
ismutedsink() {
pactl get-sink-mute $1 | awk '{print ($2 == "no"? "false" : "true")}'
}
mutesink() {
pactl set-sink-mute $1 toggle
eww update IS_MUTED_SINK=$(ismutedsink $1)
}
mutesource() {
pactl set-source-mute $1 toggle
eww update IS_MUTED_SOURCE=$(ismutedsource $1)
}
isblue() {
wpctl inspect $1 | grep api.bluez -q -m 1 && echo true || echo false
}
if [ "$1" == "getdevices" ]; then
pactl -f json list sinks | jq -Mc '[.[] | {id: .index, name: .description, mute: .mute, default: (.state == "RUNNING")}]'
elif [ "$1" == "vol" ]; then
vol $2
elif [ "$1" == "getvol" ]; then
getvol $2
elif [ "$1" == "ismutedsource" ]; then
ismutedsource $2
elif [ "$1" == "ismutedsink" ]; then
ismutedsink $2
elif [ "$1" == "mutesink" ]; then
mutesink $2
elif [ "$1" == "mutesource" ]; then
mutesource $2
elif [ "$1" == "isblue" ]; then
isblue $2
elif [ "$1" == "getdefaultsink" ]; then
wpctl inspect @DEFAULT_SINK@ | grep 'node.description' | awk -F ' = ' '{print $2}' | sed 's/\"//g'
else
usage
fi

28
.config/eww/scripts/battery.sh Executable file
View File

@@ -0,0 +1,28 @@
#!/bin/bash
bat=$(upower -e | grep BAT)
if [ -z $bat ]; then
echo '{}' | jq -Mc ".has_battery = false"
exit 0
fi
upower=$(upower -i $bat)
get_percentage() {
echo "$1" | grep percentage | awk '{print $2}'
}
get_time_remaining() {
echo "$1" | grep "time to empty" | awk -F: '{print $2}'
}
get_icon_name() {
echo "$1" | grep icon-name | awk '{print $2}'
}
is_charging() {
echo "$1" | grep state | awk '{print $2}'
}
echo '{}' | jq -Mc ".has_battery = true | .percentage = \"$(get_percentage "$upower")\" | .time_remaining= \"$(get_time_remaining "$upower")\" | .is_charging = \"$(is_charging "$upower")\" | .icon_name = \"$(get_icon_name "$upower")\" "

View File

@@ -0,0 +1,21 @@
#! /bin/bash
function clamp {
min=$1
max=$2
val=$3
python -c "print(max($min, min($val, $max)))"
}
direction=$1
current=$2
if test "$direction" = "down"
then
target=$(clamp 1 10 $(($current+1)))
echo "jumping to $target"
hyprctl dispatch workspace $target
elif test "$direction" = "up"
then
target=$(clamp 1 10 $(($current-1)))
echo "jumping to $target"
hyprctl dispatch workspace $target
fi

View File

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

View File

@@ -0,0 +1,3 @@
#!/bin/sh
hyprctl activewindow -j | jq --raw-output .title
socat -u UNIX-CONNECT:/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | stdbuf -o0 awk -F '>>|,' '/^activewindow>>/{print $3}'

View File

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

View File

@@ -0,0 +1,20 @@
#!/bin/bash
url=$(cat ~/.config/YouTube\ Music/config.json | jq --raw-output .url)
if [ -z "$url" ]; then
exit 1
fi
id="${url##*?v=}"
id="${id%%&*}"
#https://img.youtube.com/vi/$id/[option].jpg
#0
#1
#mqdefault
#hqdefault
#sddefault
#maxresdefault
url="https://img.youtube.com/vi/$id/sddefault.jpg"
curl -o ~/.config/eww/medi_art.jpg "$url"

63
.config/eww/scripts/net.sh Executable file
View File

@@ -0,0 +1,63 @@
#!/bin/bash
usage() {
echo "Usage: $0 <func> [args]
func: islowest[INT], iswlan, ssid"
}
if [ -z $1 ]; then
usage
exit 1
fi
getlowest() {
lines=$(ip route | grep default)
# Initialize variables to store the highest metric and interface
lowest_metric=99999999999
lowest_interface=""
# Loop through the lines and compare metrics
while IFS= read -r line; do
interface=$(echo "$line" | awk '{print $5}')
metric=$(echo "$line" | awk '{for(i=1;i<=NF;i++) if($i=="metric") print $(i+1)}')
if [ "$metric" -lt "$lowest_metric" ]; then
lowest_metric="$metric"
lowest_interface="$interface"
fi
done <<< "$lines"
echo "$lowest_interface"
}
islowest() {
if [ "$(getlowest)" == "$1" ]; then
echo "true"
else
echo "false"
fi
}
iswlan(){
int=$(nmcli -t -f active,ssid,device dev wifi | grep -m 1 yes | awk -F ':' '{print $3}')
if ! [ -z $int ]; then
islowest $int
else
echo "false"
fi
}
if [ "$1" == "iswlan" ]; then
iswlan
elif [ "$1" == "islowest" ]; then
islowest $2
elif [ "$1" == "getint" ]; then
getlowest
elif [ "$1" == "ssid" ]; then
nmcli -t -f active,ssid dev wifi | grep -m 1 yes | awk -F: '{print $2}'
else
usage
fi

136
.config/fish/config.fish Executable file
View File

@@ -0,0 +1,136 @@
## Set values
# Hide welcome message
set fish_greeting
set VIRTUAL_ENV_DISABLE_PROMPT "1"
set -x MANROFFOPT "-c"
set -x MANPAGER "sh -c 'col -bx | bat -l man -p'"
## Set settings for https://github.com/franciscolourenco/done
set -U __done_min_cmd_duration 10000
set -U __done_notification_urgency_level low
## Environment setup
if test -f ~/.fish_profile
source ~/.fish_profile
end
export EDITOR=nvim
export VISUAL=nvim
## Add ~/.local/bin to PATH
if test -d ~/.local/bin
if not contains -- ~/.local/bin $PATH
set -p PATH ~/.local/bin
end
end
## Starship prompt
if type -q starship && status --is-interactive
source ("/usr/bin/starship" init fish --print-full-init | psub)
end
## Functions
# Fish command history
function history
builtin history --show-time='%F %T '
end
function ba --argument filename
cp $filename $filename.bak
end
function cp_bar
cp $argv[1] $argv[2] &
set cpid $last_pid
progress -mp $cpid
kill $cpid &> /dev/null
end
# Maven
function mvn-init -a groupId artifactId -d "Create a simple maven project"
if test -z "$groupId" -o -z "$artifactId"
echo -e "Usage: mvn-init <groupId> <artifactId>\ngroupId or artifactId missing!"
else
mvn archetype:generate -DgroupId=$groupId -DartifactId=$artifactId -DinteractiveMode=false
end
end
function mvn-run -a mainClass -d "Run your current maven project"
if test -z "$mainClass"
echo -e "Usgae: mvn-run <mainClass> [arguments]\nmainClass missing!"
else
set args ""
for arg in $argv[2..-1]
set args "$args $arg"
end
if test -z $args
mvn clean compile exec:java -Dexec.mainClass="$mainClass"
else
mvn clean compile exec:java -Dexec.mainClass="$mainClass" -Dexec.args="$args"
end
end
end
## Aliases
# Replace ls with exa
if type -q exa
alias ls='exa -al --color=always --group-directories-first --icons' # preferred listing
alias la='exa -a --color=always --group-directories-first --icons' # all files and dirs
alias ll='exa -l --color=always --group-directories-first --icons' # long format
alias lt='exa -aT --color=always --group-directories-first --icons' # tree listing
alias l.='exa -ald --color=always --group-directories-first --icons .*' # show only dotfiles
end
# Replace cat with bat
if type -q bat
alias cat='bat --style header --style snip --style changes --style header'
end
# Common use
alias ipn='ip'
alias nano=nvim
alias cls='clear'
alias please='sudo'
alias ip='ip -color'
alias mkdirs='mkdir --parents'
alias ssh="kitty +kitten ssh" #For kitty terminal or use (on client)-> sudo apt install kitty-terminfo
alias grubup="sudo update-grub"
alias fixpacman="sudo rm /var/lib/pacman/db.lck"
alias tarnow='tar -acf '
alias tarlist="tar -tvf"
alias untar='tar -xvf '
alias wget='wget -c '
alias rmpkg="sudo pacman -Rcns "
alias purgepkg="sudo pacman -Rdd "
alias psmem='ps auxf | sort -nr -k 4'
alias psmem10='ps auxf | sort -nr -k 4 | head -10'
alias ..='cd ..'
alias ...='cd ../..'
alias ....='cd ../../..'
alias grep='grep --color=auto'
alias fgrep='grep -F --color=auto'
alias egrep='grep -E --color=auto'
alias igrep='grep -i --color=auto'
alias hw='hwinfo --short' # Hardware Info
alias big="expac -H M '%m\t%n' | sort -h | nl" # Sort installed packages according to size in MB
alias gitpkg='pacman -Q | grep -i "\-git" | wc -l' # List amount of -git packages
alias cleanup='sudo pacman -Rns (pacman -Qtdq)' # Cleanup orphaned packages
alias jctl="journalctl -p 3 -xb" # Get the error messages from journalctl
alias rip="expac --timefmt='%Y-%m-%d %T' '%l\t%n %v' | sort | tail -200 | nl" # Recent installed packages
# Get fastest mirrors
alias mirror="sudo reflector -f 30 -l 30 --number 10 --verbose --save /etc/pacman.d/mirrorlist"
alias mirrord="sudo reflector --latest 50 --number 20 --sort delay --save /etc/pacman.d/mirrorlist"
alias mirrors="sudo reflector --latest 50 --number 20 --sort score --save /etc/pacman.d/mirrorlist"
alias mirrora="sudo reflector --latest 50 --number 20 --sort age --save /etc/pacman.d/mirrorlist"
## Run fastfetch if session is interactive
if status --is-interactive
if type -q fastfetch
fastfetch -l arch
else if type -q neofetch
neofetch --ascii_distro arch
end
end

7
.config/hypr/env.conf Executable file
View File

@@ -0,0 +1,7 @@
## Environment
env = XCURSOR_SIZE,24
env = XDG_SESSION_TYPE,wayland
env = WLR_NO_HARDWARE_CURSORS,1
env = QT_QPA_PLATFORMTHEME,qt5ct
#env = QT_QPA_PLATFORM,wayland
env = QT_STYLE_OVERRIDE,kvantum

105
.config/hypr/hyprland.conf Executable file
View File

@@ -0,0 +1,105 @@
## Environment
source = ~/.config/hypr/env.conf
# Nvidia
# source = ~/.config/hypr/nvidia.conf
## Keybinds
source = ~/.config/hypr/keybinds.conf
## Monitors/Workspaces
source = ~/.config/hypr/windowrule.conf
## Startup
source = ~/.config/hypr/startup.conf
## Input
input {
kb_layout = de
kb_variant =
kb_model =
kb_options =
kb_rules =
numlock_by_default = 1
follow_mouse = 1
touchpad {
natural_scroll = yes
}
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
}
## General
general {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
gaps_in = 5
gaps_out = 5
border_size = 2
col.active_border = rgba(7dc4e4ee) rgba(7dc4e4ee) 45deg
col.inactive_border = rgba(595959aa)
layout = dwindle
}
## Decoration
decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 0
blur {
enabled = true
size = 3
passes = 1
}
drop_shadow = yes
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
}
## Animations
animations {
enabled = yes
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
animation = windows, 1, 7, myBezier
animation = windowsOut, 1, 7, default, popin 80%
animation = border, 1, 10, default
animation = borderangle, 1, 8, default
animation = fade, 1, 7, default
animation = workspaces, 1, 6, default
}
## Dwindle
dwindle {
pseudotile = yes
preserve_split = yes # you probably want thisr
}
## Master
master {
new_is_master = true
}
## Gestures
gestures {
workspace_swipe = on
}
## Misc
misc {
#mouse_move_enables_dpms = true
key_press_enables_dpms = true
}
## Devices
device:roccat-roccat-kone-emp-mouse {
sensitivity = 0.5
}

8
.config/hypr/hyprshade.toml Executable file
View File

@@ -0,0 +1,8 @@
# [[shades]]
# name = "vibrance"
# default = true # shader to use during times when there is no other shader scheduled
[[shades]]
name = "blue-light-filter"
start_time = 19:00:00
end_time = 08:00:00 # optional if you have more than one shade with start_time

96
.config/hypr/keybinds.conf Executable file
View File

@@ -0,0 +1,96 @@
## Keybindings
$mainMod = SUPER
# General
bind = $mainMod, P, pseudo,
bind = $mainMod, DELETE, exit,
bind = $mainMod, C, killactive,
bind = $mainMod, M, fullscreen,
bind = $mainMod, S, togglesplit,
bind = $mainMod, F4, exec, wlogout
bind = $mainMod, F, togglefloating,
bind = $mainMod, N, exec, swaync-client -t -sw
bind = $mainMod, O, exec, ~/.config/hypr/scripts/lock.sh
bind = $mainMod, B, exec, ~/.config/hypr/scripts/game_mode.sh
bind = $mainMod, V, exec, pkill rofi || ~/.config/hypr/scripts/clipboard.sh c
bind = $mainMod, TAB, exec, pkill rofi || ~/.config/hypr/scripts/app_launcher.sh w
bind = $mainMod, COMMA, exec, pkill rofi || ~/.config/hypr/scripts/app_launcher.sh e
bindr = $mainMod, SUPER_L, exec, pkill rofi || ~/.config/hypr/scripts/app_launcher.sh d
bind = $mainMod SHIFT, S, exec, grimblast --freeze copy area
bind = $mainMod CTRL, S, exec, grimblast --freeze copysave area ~/Pictures/Screenshots/"$(date --rfc-3339=seconds)".png
# Media keys
bind = , XF86AudioNext, exec, playerctl next
bind = , XF86AudioPrev, exec, playerctl previous
bind = , XF86AudioPlay, exec, playerctl play
bind = , XF86AudioPause, exec, playerctl pause
bind = , XF86AudioMute, exec, ~/.config/eww/scripts/audio.sh mutesink @DEFAULT_SINK@
bind = , XF86AudioMicMute, exec, ~/.config/eww/scripts/audio.sh mutesource @DEFAULT_SOURCE@
binde = , XF86AudioRaiseVolume, exec, ~/.config/eww/scripts/audio.sh vol up
binde = , XF86AudioLowerVolume, exec, ~/.config/eww/scripts/audio.sh vol down
# Applications
bind = $mainMod, T, exec, kitty
bind = $mainMod, E, exec, thunar || dolphin
bind = $mainMod, G, exec, ~/.config/hypr/scripts/app_launcher.sh c
bind = CTRL SHIFT, ESCAPE, exec, gnome-system-monitor
# Move focus
bind = $mainMod, left, movefocus, l
bind = $mainMod, H, movefocus, l
bind = $mainMod, right, movefocus, r
bind = $mainMod, L, movefocus, r
bind = $mainMod, up, movefocus, u
bind = $mainMod, K, movefocus, u
bind = $mainMod, down, movefocus, d
bind = $mainMod, J, movefocus, d
# Move window
bind = $mainMod SHIFT, left, movewindow, l
bind = $mainMod SHIFT, H, movewindow, l
bind = $mainMod SHIFT, right, movewindow, r
bind = $mainMod SHIFT, L, movewindow, r
bind = $mainMod SHIFT, up, movewindow, u
bind = $mainMod SHIFT, K, movewindow, u
bind = $mainMod SHIFT, down, movewindow, d
bind = $mainMod SHIFT, J, movewindow, d
bindm = $mainMod, mouse:272, movewindow
# Resize windows
binde = $mainMod CTRL, left, resizeactive, -10 0
binde = $mainMod CTRL, h, resizeactive, -10 0
binde = $mainMod CTRL, right, resizeactive, 10 0
binde = $mainMod CTRL, l, resizeactive, 10 0
binde = $mainMod CTRL, up, resizeactive, 0 -10
binde = $mainMod CTRL, k, resizeactive, 0 -10
binde = $mainMod CTRL, down, resizeactive, 0 10
binde = $mainMod CTRL, j, resizeactive, 0 10
bindm = $mainMod, mouse:273, resizewindow
# Move active window to a workspace
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
# Switch workspaces
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
# Scroll through existing workspaces
bind = $mainMod, mouse_down, workspace, e+1
bind = $mainMod, mouse_up, workspace, e-1

7
.config/hypr/nvidia.conf Executable file
View File

@@ -0,0 +1,7 @@
## Nvidia env
env = GBM_BACKEND,nvidia-drm
env = LIBVA_DRIVER_NAME,nvidia
env = __GLX_VENDOR_LIBRARY_NAME,nvidia
env = __GL_VRR_ALLOWED,1
env = WLR_NO_HARDWARE_CURSORS,1
env = WLR_DRM_NO_ATOMIC,1

View File

@@ -0,0 +1,36 @@
#!/bin/bash
rofi_conf="~/.config/rofi/main.rasi"
# Rofi action
case $1 in
d) mode="drun" ;;
w) mode="window" ;;
f) mode="filebrowser" ;;
e) mode="emoji"
action=(-a copy)
;;
c) mode="calc"
action=(-calc-command "wl-copy {result}")
children="\"message\", "
;;
h) echo -e "$0 [action]"
echo "d : drun mode"
echo "w : window mode"
echo "f : filebrowser mode"
exit 0 ;;
*) mode="drun" ;;
esac
# Get font
font=`gsettings get org.gnome.desktop.interface font-name`
fnt_override="configuration {font: \"${font//\'}\";}"
# Get icon theme
icon_override=`gsettings get org.gnome.desktop.interface icon-theme | sed "s/'//g"`
icon_override="configuration {icon-theme: \"${icon_override}\";}"
# Children
children_ovr="mainbox {children: [\"inputbar\", $children \"listbox\"];}"
# Launch rofi
rofi -show $mode ${action[0]} "${action[1]}" -theme-str "$children_ovr" -theme-str "$fnt_override" -theme-str "$icon_override" -config "$rofi_conf"

View File

@@ -0,0 +1,53 @@
#!/bin/bash
#set -e # Exit immediately if a command exits with a non-zero status. (deprecated) -> [CMD] || exit 1
if [[ $# -lt 1 ]] || [[ ! -d $1 ]]; then
echo "Usage:
$0 <dir containing images> [interval(seconds)]"
exit 1
fi
## Check running
running=$(ps -ef | grep "$0" | grep -v grep | wc -l)
if [ ${running} -gt 2 ]; then
echo "Script already running! Killing others (TODO)..."
exit 1
# CRASHES EVERYTHING \/ !!!!!!!!!!
script_pids=$(ps aux | grep -E "$script_name" | grep -v "grep" | awk -v pid="$current_pid" '$2 != pid {print $2}')
# Loop through the PIDs and kill the processes
for pid in $script_pids; do
echo "Killing process $pid"
kill "$pid"
done
fi
## Start swww
swww init &> /dev/null
## Settings for swww
export SWWW_TRANSITION_FPS=60
export SWWW_TRANSITION_STEP=2
INTERVAL=300
if [ ! -z $2 ]; then
INTERVAL=$2
fi
## Main loop
while true; do
find "$1" \
| while read -r img; do
echo "$((RANDOM % 1000)):$img"
done \
| sort -n | cut -d':' -f2- \
| while read -r img; do
img=${img/\~/$HOME}
if [ -d $img ]; then
continue
fi
swww img "$img" --transition-type wipe --resize=fit
ln -sf "$img" ~/.config/hypr/theme/current_background.jpg
sleep $INTERVAL
done
done

17
.config/hypr/scripts/bar.sh Executable file
View File

@@ -0,0 +1,17 @@
#!/bin/bash
eww open bar1
eww open bar2
eww open bar3
indicator-mic-cam & disown
## Waybar auto update (requires inotifytools)
# CONFIG_FILES="$HOME/.config/waybar/config $HOME/.config/waybar/style.css"
#
# trap "killall waybar" EXIT
#
# while true; do
# waybar &
# inotifywait -e create,modify $CONFIG_FILES
# killall waybar
# done

View File

@@ -0,0 +1,19 @@
#!/bin/bash
bat=$(upower -e | grep BAT)
if [ -z $bat ]; then
echo "No battery available!"
exit 1
fi
while true; do
per=$(upower -i $bat | grep percentage | awk '{print $2}')
per="${per%\%}"
if "$per" -lt 15 #&& ! is_charging
eww open battery_warning
fi
sleep 120
done

View File

@@ -0,0 +1,24 @@
#!/bin/bash
roconf="~/.config/rofi/clipboard.rasi"
# Read font
font=`gsettings get org.gnome.desktop.interface font-name`
fnt_override="configuration {font: \"${font//\'}\";}"
# Clipboard action
case $1 in
c) cliphist list | rofi -dmenu -theme-str "entry { placeholder: \"Copy...\";}" -theme-str "$fnt_override" -config $roconf | cliphist decode | wl-copy
;;
d) cliphist list | rofi -dmenu -theme-str "entry { placeholder: \"Delete...\";}" -theme-str "$fnt_override" -config $roconf | cliphist delete
;;
w) if [ `echo -e "Yes\nNo" | rofi -dmenu -theme-str "entry { placeholder: \"Clear Clipboard History?\";}" -theme-str "$fnt_override" -config $roconf` == "Yes" ] ; then
cliphist wipe
fi
;;
*) echo -e "$0 [action]"
echo "c : cliphist list and copy selected"
echo "d : cliphist list and delete selected"
echo "w : cliphist wipe database"
exit 1
;;
esac

View File

@@ -0,0 +1,3 @@
#!/bin/bash
eww close bar1 || eww open bar1 & disown

21
.config/hypr/scripts/idle.sh Executable file
View File

@@ -0,0 +1,21 @@
#!/bin/bash
isplayingvideo(){
if pactl list | grep -q RUNNING; then
exit 1
else
exit 0
fi
}
if ! [ -z $1 ]; then
isplayingvideo
fi
timeout_lock=900
timeout_DPMS=1080
swayidle -w \
timeout ${timeout_lock} "$0 isplayinfvideo || ~/.config/hypr/scripts/lock.sh" \
#timeout ${timeout_DPMS} 'hyprctl dispatch dpms off'
#resume 'hyprctl dispatch dpms on' # Crashes all apps -> Hyprland config set misc/mouse_move_enables_dpms=true

10
.config/hypr/scripts/lock.sh Executable file
View File

@@ -0,0 +1,10 @@
#!/bin/bash
dnd=$(swaync-client -D)
swaync-client -dn
swaylock -C ~/.config/swaylock/swaylock.conf
if [ "$dnd" == "false" ]; then
swaync-client -df
fi

22
.config/hypr/startup.conf Executable file
View File

@@ -0,0 +1,22 @@
## Programms
exec-once = discord
exec-once = youtube-music
exec-once = swaync
exec = hyprshade auto
exec-once = nm-applet
exec-once = blueman-applet
exec-once = playerctld daemon
exec-once = ~/.config/hypr/scripts/bar.sh
exec-once = ~/.config/hypr/scripts/idle.sh
exec-once = ~/.config/hypr/scripts/battery_check.sh
## Clipboard
exec-once = wl-paste --type text --watch cliphist store #Stores only text data
exec-once = wl-paste --type image --watch cliphist store #Stores only image data
## Background
exec-once = ~/.config/hypr/scripts/background.sh ~/Data/Pictures/Backgrounds/Desktop/
## Misc
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP

View File

@@ -0,0 +1 @@
link for lock and rofi

33
.config/hypr/windowrule.conf Executable file
View File

@@ -0,0 +1,33 @@
## Monitors
$monitorOne = HDMI-A-1
$monitorTwo = DP-2
$monitorThree = HDMI-A-2
monitor = $monitorOne,1920x1080@144.001007,0x0,1
monitor = $monitorTwo,2560x1440@143.912003,1920x0,1
monitor = $monitorThree,1920x1080@60.000000,4480x0,1
monitor = ,preferred,auto,1
## Window Rules - (hyprctl -j clients | grep class)
windowrule = workspace 2,^(YouTube Music)$
windowrule = workspace 4,^(explorer.exe)$
windowrule = workspace 4, ^(league of legends.exe)$
windowrule = workspace 4,^(lutris)$
windowrule = workspace 5,^(discord)$
windowrule = workspace 5,^(de.keule.client.ui.JavaFX)$
windowrule = float,^(lutris)$
windowrule = size 965 545, ^(lutris)$
windowrule = float,title:^.*culator.*$
## Workspace
workspace = 1, monitor:$monitorOne, default:true
workspace = 2, monitor:$monitorOne
workspace = 3, monitor:$monitorTwo, default:true
workspace = 4, monitor:$monitorTwo
workspace = 5, monitor:$monitorThree, default:true
workspace = 6, monitor:$monitorThree

14
.config/kdeglobals Executable file
View File

@@ -0,0 +1,14 @@
[$Version]
update_info=filepicker.upd:filepicker-remove-old-previews-entry
[General]
TerminalApplication=kitty
[KDE]
ShowDeleteCommand=true
[KShortcutsDialog Settings]
Dialog Size=600,480
[PreviewSettings]
MaximumRemoteSize=0

2472
.config/kitty/kitty.conf Executable file

File diff suppressed because it is too large Load Diff

489
.config/nvim/init.lua Executable file
View File

@@ -0,0 +1,489 @@
--- Set Leader Key (Needs to be set before the plugins are loaded/required)
vim.g.mapleader = ' '
vim.g.maplocalleader = ' '
--- Plugin Manager
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable", -- latest stable release
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)
-- Add Plugins
require("lazy").setup({
-- Theme
{
"catppuccin/nvim",
name = "catppuccin.vim",
priority = 1000,
config = function()
vim.g.catppuccin_flavor = "macchiato"
vim.cmd [[colorscheme catppuccin]]
end,
},
-- Syntax highlighting support
"elkowar/yuck.vim",
"fladson/vim-kitty",
-- Use "gc" to comment visual regions/lines
{ "numToStr/Comment.nvim", opts = {} },
-- Detect tabstop and shiftwidth automatically
"tpope/vim-sleuth",
-- Add indentation guides even on blank lines ???
{
"lukas-reineke/indent-blankline.nvim",
main = "ibl",
opts = {},
},
-- Status line
{
"nvim-lualine/lualine.nvim",
opts = {
options = {
icons_enabled = true,
theme = "palenight",
component_separators = "|",
section_separators = "",
},
},
},
-- LSP (Configuration under "lspconfig")
{
"neovim/nvim-lspconfig",
dependencies = {
-- Automatically install LSPs to stdpath for neovim
{ "williamboman/mason.nvim", config = true },
"williamboman/mason-lspconfig.nvim",
-- Useful status updates for LSP
-- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})`
{ "j-hui/fidget.nvim", tag = "legacy", opts = {} },
-- Additional lua configuration, makes nvim stuff amazing!
"folke/neodev.nvim",
},
},
-- Autocomplete
{
"hrsh7th/nvim-cmp",
dependencies = {
-- Snippet Engine & its associated nvim-cmp source
'L3MON4D3/LuaSnip',
'saadparwaiz1/cmp_luasnip',
-- Adds LSP completion capabilities
'hrsh7th/cmp-nvim-lsp',
-- Adds a number of user-friendly snippets
'rafamadriz/friendly-snippets',
},
},
-- Show available command
{
"folke/which-key.nvim",
event = "VeryLazy",
init = function()
vim.o.timeout = true
vim.o.timeoutlen = 300
end,
opts = {}
},
-- Fuzzy Finder (files, lsp, etc)
{
"nvim-telescope/telescope.nvim",
branch = "0.1.x",
dependencies = {
"nvim-lua/plenary.nvim",
{
'nvim-telescope/telescope-fzf-native.nvim',
-- NOTE: If you are having trouble with this installation,
-- refer to the README for telescope-fzf-native for more instructions.
build = 'make',
cond = function()
return vim.fn.executable 'make' == 1
end,
},
},
},
-- Highlight, edit, and navigate code
{
'nvim-treesitter/nvim-treesitter',
dependencies = {
'nvim-treesitter/nvim-treesitter-textobjects',
},
build = ':TSUpdate',
},
-- Git
"tpope/vim-fugitive",
--"tpope/vim-rhubarb",
{
"lewis6991/gitsigns.nvim",
opts = {
-- See `:help gitsigns.txt`
signs = {
add = { text = "+" },
change = { text = "~" },
delete = { text = "_" },
topdelete = { text = "" },
changedelete = { text = "~" },
},
on_attach = function(bufnr)
vim.keymap.set("n", "<leader>hp", require("gitsigns").preview_hunk, { buffer = bufnr, desc = "Preview git hunk" })
-- don't override the built-in and fugitive keymaps
local gs = package.loaded.gitsigns
vim.keymap.set({ "n", "v" }, "]c", function()
if vim.wo.diff then return "]c" end
vim.schedule(function() gs.next_hunk() end)
return "<Ignore>"
end, { expr = true, buffer = bufnr, desc = "Jump to next hunk" })
vim.keymap.set({ "n", "v" }, "[c", function()
if vim.wo.diff then return "[c" end
vim.schedule(function() gs.prev_hunk() end)
return "<Ignore>"
end, { expr = true, buffer = bufnr, desc = "Jump to previous hunk" })
end,
},
},
})
-- Tab
vim.opt.tabstop = 4
vim.opt.softtabstop = 4
vim.opt.shiftwidth = 4
vim.opt.expandtab = true
--- Show line numbers
vim.opt.number = true
--- Relative line numbers
vim.opt.relativenumber = true
--- Go to next/previous line
vim.opt.whichwrap = "<,>,[,]"
--- Enable mouse
vim.opt.mouse = "a"
--- Sync clipboard with OS
vim.opt.clipboard = "unnamedplus"
--- Enable break indent
vim.opt.breakindent = true
--- Save undo history
vim.opt.undofile = true
--- Case-insensetive search
vim.opt.ignorecase = true
vim.opt.smartcase = true
--- Keep signcolum
vim.wo.signcolumn = "yes"
--- Set completeopt to have a better completion experience
vim.opt.completeopt = "menuone,noselect"
--- [[ Basic Keymaps ]]
-- Center view when jumping have the view
vim.keymap.set("n", "<C-d>", "<C-d>zz")
vim.keymap.set("n", "<C-u>", "<C-u>zz")
-- Center view when search
vim.keymap.set("n", "n", "nzz")
vim.keymap.set("n", "N", "Nzz")
-- Keymaps for better default experience
-- See `:help vim.keymap.set()`
vim.keymap.set({ "n", "v" }, "<Space>", "<Nop>", { silent = true })
-- Remap for dealing with word wrap
vim.keymap.set("n", "k", "v:count == 0 ? 'gk' : 'k'", { expr = true, silent = true })
vim.keymap.set("n", "j", "v:count == 0 ? 'gj' : 'j'", { expr = true, silent = true })
--- [[ Highlight on yank ]]
-- See `:help vim.highlight.on_yank()`
local highlight_group = vim.api.nvim_create_augroup("YankHighlight", { clear = true })
vim.api.nvim_create_autocmd("TextYankPost", {
callback = function()
vim.highlight.on_yank()
end,
group = highlight_group,
pattern = "*",
})
--- [[ Configure Telescope ]]
-- See `:help telescope` and `:help telescope.setup()`
require("telescope").setup {
defaults = {
mappings = {
i = {
["<C-u>"] = false,
["<C-d>"] = false,
},
},
},
}
-- Enable telescope fzf native, if installed
pcall(require("telescope").load_extension, "fzf")
-- See `:help telescope.builtin`
vim.keymap.set("n", "<leader>?", require("telescope.builtin").oldfiles, { desc = "[?] Find recently opened files" })
vim.keymap.set("n", "<leader><space>", require("telescope.builtin").buffers, { desc = "[ ] Find existing buffers" })
vim.keymap.set("n", "<leader>/", function()
-- You can pass additional configuration to telescope to change theme, layout, etc.
require("telescope.builtin").current_buffer_fuzzy_find(require("telescope.themes").get_dropdown {
winblend = 10,
previewer = false,
})
end, { desc = "[/] Fuzzily search in current buffer" })
vim.keymap.set("n", "<leader>gf", require("telescope.builtin").git_files, { desc = "Search [G]it [F]iles" })
vim.keymap.set("n", "<leader>sf", require("telescope.builtin").find_files, { desc = "[S]earch [F]iles" })
vim.keymap.set("n", "<leader>sh", require("telescope.builtin").help_tags, { desc = "[S]earch [H]elp" })
vim.keymap.set("n", "<leader>sw", require("telescope.builtin").grep_string, { desc = "[S]earch current [W]ord" })
vim.keymap.set("n", "<leader>sg", require("telescope.builtin").live_grep, { desc = "[S]earch by [G]rep" })
vim.keymap.set("n", "<leader>sd", require("telescope.builtin").diagnostics, { desc = "[S]earch [D]iagnostics" })
vim.keymap.set("n", "<leader>sr", require("telescope.builtin").resume, { desc = "[S]earch [R]esume" })
--- [[ Configure Treesitter ]]
-- See `:help nvim-treesitter`
-- Defer Treesitter setup after first render to improve startup time of "nvim {filename}"
vim.defer_fn(function()
require("nvim-treesitter.configs").setup {
-- Add languages to be installed here that you want installed for treesitter
ensure_installed = { "c", "cpp", "go", "lua", "python", "rust", "tsx", "javascript", "typescript", "vimdoc", "vim" },
-- Autoinstall languages that are not installed. Defaults to false (but you can change for yourself!)
auto_install = false,
highlight = { enable = true },
indent = { enable = true },
incremental_selection = {
enable = true,
keymaps = {
init_selection = "<c-space>",
node_incremental = "<c-space>",
scope_incremental = "<c-s>",
node_decremental = "<M-space>",
},
},
textobjects = {
select = {
enable = true,
lookahead = true, -- Automatically jump forward to textobj, similar to targets.vim
keymaps = {
-- You can use the capture groups defined in textobjects.scm
["aa"] = "@parameter.outer",
["ia"] = "@parameter.inner",
["af"] = "@function.outer",
["if"] = "@function.inner",
["ac"] = "@class.outer",
["ic"] = "@class.inner",
},
},
move = {
enable = true,
set_jumps = true, -- whether to set jumps in the jumplist
goto_next_start = {
["]m"] = "@function.outer",
["]]"] = "@class.outer",
},
goto_next_end = {
["]M"] = "@function.outer",
["]["] = "@class.outer",
},
goto_previous_start = {
["[m"] = "@function.outer",
["[["] = "@class.outer",
},
goto_previous_end = {
["[M"] = "@function.outer",
["[]"] = "@class.outer",
},
},
swap = {
enable = true,
swap_next = {
["<leader>a"] = "@parameter.inner",
},
swap_previous = {
["<leader>A"] = "@parameter.inner",
},
},
},
}
end, 0)
-- Diagnostic keymaps
vim.keymap.set("n", "[d", vim.diagnostic.goto_prev, { desc = "Go to previous diagnostic message" })
vim.keymap.set("n", "]d", vim.diagnostic.goto_next, { desc = "Go to next diagnostic message" })
vim.keymap.set("n", "<leader>e", vim.diagnostic.open_float, { desc = "Open floating diagnostic message" })
vim.keymap.set("n", "<leader>q", vim.diagnostic.setloclist, { desc = "Open diagnostics list" })
--- [[ Configure LSP ]]
-- This function gets run when an LSP connects to a particular buffer.
local on_attach = function(_, bufnr)
-- Sets the mode, buffer and description for us each time.
local nmap = function(keys, func, desc)
if desc then
desc = "LSP: " .. desc
end
vim.keymap.set("n", keys, func, { buffer = bufnr, desc = desc })
end
nmap("<leader>rn", vim.lsp.buf.rename, "[R]e[n]ame")
nmap("<leader>ca", vim.lsp.buf.code_action, "[C]ode [A]ction")
nmap("gd", vim.lsp.buf.definition, "[G]oto [D]efinition")
nmap("gr", require("telescope.builtin").lsp_references, "[G]oto [R]eferences")
nmap("gI", require("telescope.builtin").lsp_implementations, "[G]oto [I]mplementation")
nmap("<leader>D", vim.lsp.buf.type_definition, "Type [D]efinition")
nmap("<leader>ds", require("telescope.builtin").lsp_document_symbols, "[D]ocument [S]ymbols")
nmap("<leader>ws", require("telescope.builtin").lsp_dynamic_workspace_symbols, "[W]orkspace [S]ymbols")
-- See `:help K` for why this keymap
nmap("K", vim.lsp.buf.hover, "Hover Documentation")
nmap("<C-k>", vim.lsp.buf.signature_help, "Signature Documentation")
-- Lesser used LSP functionality
nmap("gD", vim.lsp.buf.declaration, "[G]oto [D]eclaration")
nmap("<leader>wa", vim.lsp.buf.add_workspace_folder, "[W]orkspace [A]dd Folder")
nmap("<leader>wr", vim.lsp.buf.remove_workspace_folder, "[W]orkspace [R]emove Folder")
nmap("<leader>wl", function()
print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
end, "[W]orkspace [L]ist Folders")
-- Create a command `:Format` local to the LSP buffer
vim.api.nvim_buf_create_user_command(bufnr, "Format", function(_)
vim.lsp.buf.format()
end, { desc = "Format current buffer with LSP" })
-- Auto format on save
vim.cmd [[autocmd BufWritePre <buffer> lua vim.lsp.buf.format()]]
-- or vim.cmd [[autocmd BufWritePre * lua vim.lsp.buf.format()]]
end
-- document existing key chains
require("which-key").register({
["<leader>c"] = { name = "[C]ode", _ = "which_key_ignore" },
["<leader>d"] = { name = "[D]ocument", _ = "which_key_ignore" },
["<leader>g"] = { name = "[G]it", _ = "which_key_ignore" },
["<leader>h"] = { name = "More git", _ = "which_key_ignore" },
["<leader>r"] = { name = "[R]ename", _ = "which_key_ignore" },
["<leader>s"] = { name = "[S]earch", _ = "which_key_ignore" },
["<leader>w"] = { name = "[W]orkspace", _ = "which_key_ignore" },
})
-- Enable the following language servers
-- If you want to override the default filetypes that your language server will attach to you can
-- define the property "filetypes" to the map in question.
local servers = {
jsonls = {},
clangd = {},
html = { filetypes = { "html", "twig", "hbs" } },
cssls = {},
rust_analyzer = {},
jdtls = {},
lua_ls = {
Lua = {
workspace = { checkThirdParty = false },
telemetry = { enable = false },
},
},
}
-- Setup neovim lua configuration
require("neodev").setup()
-- nvim-cmp supports additional completion capabilities, so broadcast that to servers
local capabilities = vim.lsp.protocol.make_client_capabilities()
capabilities = require("cmp_nvim_lsp").default_capabilities(capabilities)
-- Ensure the servers above are installed
local mason_lspconfig = require "mason-lspconfig"
mason_lspconfig.setup {
ensure_installed = vim.tbl_keys(servers),
}
mason_lspconfig.setup_handlers {
function(server_name)
require("lspconfig")[server_name].setup {
capabilities = capabilities,
on_attach = on_attach,
settings = servers[server_name],
filetypes = (servers[server_name] or {}).filetypes,
}
end
}
--- [[ Configure nvim-cmp ]]
-- See `:help cmp`
local cmp = require "cmp"
local luasnip = require "luasnip"
require("luasnip.loaders.from_vscode").lazy_load()
luasnip.config.setup {}
cmp.setup {
snippet = {
expand = function(args)
luasnip.lsp_expand(args.body)
end,
},
mapping = cmp.mapping.preset.insert {
["<C-n>"] = cmp.mapping.select_next_item(),
["<C-p>"] = cmp.mapping.select_prev_item(),
["<C-d>"] = cmp.mapping.scroll_docs(-4),
["<C-f>"] = cmp.mapping.scroll_docs(4),
["<C-Space>"] = cmp.mapping.complete {},
["<CR>"] = cmp.mapping.confirm {
behavior = cmp.ConfirmBehavior.Replace,
select = true,
},
["<Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_next_item()
elseif luasnip.expand_or_locally_jumpable() then
luasnip.expand_or_jump()
else
fallback()
end
end, { "i", "s" }),
["<S-Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_prev_item()
elseif luasnip.locally_jumpable(-1) then
luasnip.jump(-1)
else
fallback()
end
end, { "i", "s" }),
},
sources = {
{ name = "nvim_lsp" },
{ name = "luasnip" },
},
}
-- The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et

View File

View File

@@ -0,0 +1,219 @@
# This file is part of ranger, the console file manager.
# License: GNU GPL version 3, see the file "AUTHORS" for details.
# This theme was greatly inspired by "RougarouTheme" for ranger
# It can be found in: `https://github.com/RougarouTheme/ranger`
from __future__ import absolute_import, division, print_function
from ranger.gui.colorscheme import ColorScheme
from ranger.gui.color import (
black,
blue,
cyan,
green,
magenta,
red,
white,
yellow,
default,
normal,
bold,
reverse,
default_colors,
)
class Dracula(ColorScheme):
progress_bar_color = 13
def verify_browser(self, context, fg, bg, attr):
if context.selected:
attr = reverse
else:
attr = normal
if context.empty or context.error:
bg = 1
fg = 0
if context.border:
fg = default
if context.document:
attr |= normal
fg = 13
if context.media:
if context.image:
attr |= normal
fg = 3
elif context.video:
fg = 1
elif context.audio:
fg = 6
else:
fg = 10
if context.container:
attr |= bold
fg = 9
if context.directory:
attr |= bold
fg = 4
elif context.executable and not any(
(context.media, context.container, context.fifo, context.socket)
):
attr |= bold
fg = 2
if context.socket:
fg = 5
attr |= bold
if context.fifo or context.device:
fg = 3
if context.device:
attr |= bold
if context.link:
fg = 6 if context.good else 13
if context.tag_marker and not context.selected:
attr |= bold
if fg in (red, magenta):
fg = 1
else:
fg = 15
if not context.selected and (context.cut or context.copied):
fg = 8
attr |= bold
if context.main_column:
if context.selected:
attr |= bold
fg = 10
if context.marked:
attr |= bold
fg = 11
if context.badinfo:
if attr & reverse:
bg = 5
else:
fg = 5
if context.inactive_pane:
fg = 6
return fg, bg, attr
def verify_titlebar(self, context, fg, bg, attr):
attr |= bold
if context.hostname:
fg = 1 if context.bad else 2
elif context.directory:
fg = 4
elif context.tab:
if context.good:
bg = 2
elif context.link:
fg = 6
return fg, bg, attr
def verify_statusbar(self, context, fg, bg, attr):
if context.permissions:
if context.good:
fg = 2
elif context.bad:
bg = 5
fg = 8
if context.marked:
attr |= bold | reverse
fg = 3
if context.frozen:
attr |= bold | reverse
fg = 6
if context.message:
if context.bad:
attr |= bold
fg = 1
if context.loaded:
bg = self.progress_bar_color
if context.vcsinfo:
fg = 4
attr &= ~bold
if context.vcscommit:
fg = 3
attr &= ~bold
if context.vcsdate:
fg = 6
attr &= ~bold
return fg, bg, attr
def verify_taskview(self, context, fg, bg, attr):
if context.title:
fg = 4
if context.selected:
attr |= reverse
if context.loaded:
if context.selected:
fg = self.progress_bar_color
else:
bg = self.progress_bar_color
return fg, bg, attr
def verify_vcsfile(self, context, fg, bg, attr):
attr &= ~bold
if context.vcsconflict:
fg = 5
elif context.vcschanged:
fg = 1
elif context.vcsunknown:
fg = 1
elif context.vcsstaged:
fg = 2
elif context.vcssync:
fg = 2
elif context.vcsignored:
fg = default
return fg, bg, attr
def verify_vcsremote(self, context, fg, bg, attr):
attr &= ~bold
if context.vcssync or context.vcsnone:
fg = 2
elif context.vcsbehind:
fg = 1
elif context.vcsahead:
fg = 6
elif context.vcsdiverged:
fg = 5
elif context.vcsunknown:
fg = 1
return fg, bg, attr
def use(self, context):
fg, bg, attr = default_colors
if context.reset:
return default_colors
elif context.in_browser:
fg, bg, attr = self.verify_browser(context, fg, bg, attr)
elif context.in_titlebar:
fg, bg, attr = self.verify_titlebar(context, fg, bg, attr)
elif context.in_statusbar:
fg, bg, attr = self.verify_statusbar(context, fg, bg, attr)
if context.text:
if context.highlight:
attr |= reverse
if context.in_taskview:
fg, bg, attr = self.verify_taskview(context, fg, bg, attr)
if context.vcsfile and not context.selected:
fg, bg, attr = self.verify_vcsfile(context, fg, bg, attr)
elif context.vcsremote and not context.selected:
fg, bg, attr = self.verify_vcsremote(context, fg, bg, attr)
return fg, bg, attr

759
.config/ranger/rc.conf Executable file
View File

@@ -0,0 +1,759 @@
# ===================================================================
# This file contains the default startup commands for ranger.
# To change them, it is recommended to create either /etc/ranger/rc.conf
# (system-wide) or ~/.config/ranger/rc.conf (per user) and add your custom
# commands there.
#
# If you copy this whole file there, you may want to set the environment
# variable RANGER_LOAD_DEFAULT_RC to FALSE to avoid loading it twice.
#
# The purpose of this file is mainly to define keybindings and settings.
# For running more complex python code, please create a plugin in "plugins/" or
# a command in "commands.py".
#
# Each line is a command that will be run before the user interface
# is initialized. As a result, you can not use commands which rely
# on the UI such as :delete or :mark.
# ===================================================================
# ===================================================================
# == Options
# ===================================================================
# Which viewmode should be used? Possible values are:
# miller: Use miller columns which show multiple levels of the hierarchy
# multipane: Midnight-commander like multipane view showing all tabs next
# to each other
set viewmode miller
#set viewmode multipane
# How many columns are there, and what are their relative widths?
set column_ratios 1,3,4
# Which files should be hidden? (regular expression)
set hidden_filter ^\.|\.(?:pyc|pyo|bak|swp)$|^lost\+found$|^__(py)?cache__$
# Show hidden files? You can toggle this by typing 'zh'
set show_hidden false
# Ask for a confirmation when running the "delete" command?
# Valid values are "always", "never", "multiple" (default)
# With "multiple", ranger will ask only if you delete multiple files at once.
set confirm_on_delete multiple
# Use non-default path for file preview script?
# ranger ships with scope.sh, a script that calls external programs (see
# README.md for dependencies) to preview images, archives, etc.
#set preview_script ~/.config/ranger/scope.sh
# Use the external preview script or display simple plain text or image previews?
set use_preview_script true
# Automatically count files in the directory, even before entering them?
set automatically_count_files true
# Open all images in this directory when running certain image viewers
# like feh or sxiv? You can still open selected files by marking them.
set open_all_images true
# Be aware of version control systems and display information.
set vcs_aware false
# State of the four backends git, hg, bzr, svn. The possible states are
# disabled, local (only show local info), enabled (show local and remote
# information).
set vcs_backend_git enabled
set vcs_backend_hg disabled
set vcs_backend_bzr disabled
set vcs_backend_svn disabled
# Truncate the long commit messages to this length when shown in the statusbar.
set vcs_msg_length 50
# Use one of the supported image preview protocols
set preview_images false
# Set the preview image method. Supported methods:
#
# * w3m (default):
# Preview images in full color with the external command "w3mimgpreview"?
# This requires the console web browser "w3m" and a supported terminal.
# It has been successfully tested with "xterm" and "urxvt" without tmux.
#
# * iterm2:
# Preview images in full color using iTerm2 image previews
# (http://iterm2.com/images.html). This requires using iTerm2 compiled
# with image preview support.
#
# This feature relies on the dimensions of the terminal's font. By default, a
# width of 8 and height of 11 are used. To use other values, set the options
# iterm2_font_width and iterm2_font_height to the desired values.
#
# * terminology:
# Previews images in full color in the terminology terminal emulator.
# Supports a wide variety of formats, even vector graphics like svg.
#
# * urxvt:
# Preview images in full color using urxvt image backgrounds. This
# requires using urxvt compiled with pixbuf support.
#
# * urxvt-full:
# The same as urxvt but utilizing not only the preview pane but the
# whole terminal window.
#
# * kitty:
# Preview images in full color using kitty image protocol.
# Requires python PIL or pillow library.
# If ranger does not share the local filesystem with kitty
# the transfer method is changed to encode the whole image;
# while slower, this allows remote previews,
# for example during an ssh session.
# Tmux is unsupported.
#
# * ueberzug:
# Preview images in full color with the external command "ueberzug".
# Images are shown by using a child window.
# Only for users who run X11 in GNU/Linux.
set preview_images_method w3m
# Delay in seconds before displaying an image with the w3m method.
# Increase it in case of experiencing display corruption.
set w3m_delay 0.02
# Manually adjust the w3mimg offset when using a terminal which needs this
set w3m_offset 0
# Default iTerm2 font size (see: preview_images_method: iterm2)
set iterm2_font_width 8
set iterm2_font_height 11
# Use a unicode "..." character to mark cut-off filenames?
set unicode_ellipsis false
# BIDI support - try to properly display file names in RTL languages (Hebrew, Arabic).
# Requires the python-bidi pip package
set bidi_support false
# Show dotfiles in the bookmark preview box?
set show_hidden_bookmarks true
# Which colorscheme to use? These colorschemes are available by default:
# default, jungle, snow, solarized
set colorscheme dracula
# Preview files on the rightmost column?
# And collapse (shrink) the last column if there is nothing to preview?
set preview_files true
set preview_directories true
set collapse_preview true
# Wrap long lines in plain text previews?
set wrap_plaintext_previews false
# Save the console history on exit?
set save_console_history true
# Draw the status bar on top of the browser window (default: bottom)
set status_bar_on_top false
# Draw a progress bar in the status bar which displays the average state of all
# currently running tasks which support progress bars?
set draw_progress_bar_in_status_bar true
# Draw borders around columns? (separators, outline, both, or none)
# Separators are vertical lines between columns.
# Outline draws a box around all the columns.
# Both combines the two.
set draw_borders none
# Display the directory name in tabs?
set dirname_in_tabs false
# Enable the mouse support?
set mouse_enabled true
# Display the file size in the main column or status bar?
set display_size_in_main_column true
set display_size_in_status_bar true
# Display the free disk space in the status bar?
set display_free_space_in_status_bar true
# Display files tags in all columns or only in main column?
set display_tags_in_all_columns true
# Set a title for the window? Updates both `WM_NAME` and `WM_ICON_NAME`
set update_title false
# Set the tmux/screen window-name to "ranger"?
set update_tmux_title true
# Shorten the title if it gets long? The number defines how many
# directories are displayed at once, 0 turns off this feature.
set shorten_title 3
# Show hostname in titlebar?
set hostname_in_titlebar true
# Abbreviate $HOME with ~ in the titlebar (first line) of ranger?
set tilde_in_titlebar false
# How many directory-changes or console-commands should be kept in history?
set max_history_size 20
set max_console_history_size 50
# Try to keep so much space between the top/bottom border when scrolling:
set scroll_offset 8
# Flush the input after each key hit? (Noticeable when ranger lags)
set flushinput true
# Padding on the right when there's no preview?
# This allows you to click into the space to run the file.
set padding_right true
# Save bookmarks (used with mX and `X) instantly?
# This helps to synchronize bookmarks between multiple ranger
# instances but leads to *slight* performance loss.
# When false, bookmarks are saved when ranger is exited.
set autosave_bookmarks true
# Save the "`" bookmark to disk. This can be used to switch to the last
# directory by typing "``".
set save_backtick_bookmark true
# You can display the "real" cumulative size of directories by using the
# command :get_cumulative_size or typing "dc". The size is expensive to
# calculate and will not be updated automatically. You can choose
# to update it automatically though by turning on this option:
set autoupdate_cumulative_size false
# Turning this on makes sense for screen readers:
set show_cursor false
# One of: size, natural, basename, atime, ctime, mtime, type, random
set sort natural
# Additional sorting options
set sort_reverse false
set sort_case_insensitive true
set sort_directories_first true
set sort_unicode false
# Enable this if key combinations with the Alt Key don't work for you.
# (Especially on xterm)
set xterm_alt_key false
# Whether to include bookmarks in cd command
set cd_bookmarks true
# Changes case sensitivity for the cd command tab completion
set cd_tab_case sensitive
# Use fuzzy tab completion with the "cd" command. For example,
# ":cd /u/lo/b<tab>" expands to ":cd /usr/local/bin".
set cd_tab_fuzzy false
# Avoid previewing files larger than this size, in bytes. Use a value of 0 to
# disable this feature.
set preview_max_size 0
# The key hint lists up to this size have their sublists expanded.
# Otherwise the submaps are replaced with "...".
set hint_collapse_threshold 10
# Add the highlighted file to the path in the titlebar
set show_selection_in_titlebar true
# The delay that ranger idly waits for user input, in milliseconds, with a
# resolution of 100ms. Lower delay reduces lag between directory updates but
# increases CPU load.
set idle_delay 2000
# When the metadata manager module looks for metadata, should it only look for
# a ".metadata.json" file in the current directory, or do a deep search and
# check all directories above the current one as well?
set metadata_deep_search false
# Clear all existing filters when leaving a directory
set clear_filters_on_dir_change false
# Disable displaying line numbers in main column.
# Possible values: false, absolute, relative.
set line_numbers false
# When line_numbers=relative show the absolute line number in the
# current line.
set relative_current_zero false
# Start line numbers from 1 instead of 0
set one_indexed false
# Save tabs on exit
set save_tabs_on_exit false
# Enable scroll wrapping - moving down while on the last item will wrap around to
# the top and vice versa.
set wrap_scroll false
# Set the global_inode_type_filter to nothing. Possible options: d, f and l for
# directories, files and symlinks respectively.
set global_inode_type_filter
# This setting allows to freeze the list of files to save I/O bandwidth. It
# should be 'false' during start-up, but you can toggle it by pressing F.
set freeze_files false
# Print file sizes in bytes instead of the default human-readable format.
set size_in_bytes false
# Warn at startup if RANGER_LEVEL env var is greater than 0, in other words
# give a warning when you nest ranger in a subshell started by ranger.
# Special value "error" makes the warning more visible.
set nested_ranger_warning true
# ===================================================================
# == Local Options
# ===================================================================
# You can set local options that only affect a single directory.
# Examples:
# setlocal path=~/downloads sort mtime
# ===================================================================
# == Command Aliases in the Console
# ===================================================================
alias e edit
alias q quit
alias q! quit!
alias qa quitall
alias qa! quitall!
alias qall quitall
alias qall! quitall!
alias setl setlocal
alias filter scout -prts
alias find scout -aets
alias mark scout -mr
alias unmark scout -Mr
alias search scout -rs
alias search_inc scout -rts
alias travel scout -aefklst
# ===================================================================
# == Define keys for the browser
# ===================================================================
# Basic
map Q quitall
map q quit
copymap q ZZ ZQ
map R reload_cwd
map F set freeze_files!
map <C-r> reset
map <C-l> redraw_window
map <C-c> abort
map <esc> change_mode normal
map ~ set viewmode!
map i display_file
map <A-j> scroll_preview 1
map <A-k> scroll_preview -1
map ? help
map W display_log
map w taskview_open
map S shell $SHELL
map : console
map ; console
map ! console shell%space
map @ console -p6 shell %%s
map # console shell -p%space
map s console shell%space
map r chain draw_possible_programs; console open_with%space
map f console find%space
map cd console cd%space
map <C-p> chain console; eval fm.ui.console.history_move(-1)
# Change the line mode
map Mf linemode filename
map Mi linemode fileinfo
map Mm linemode mtime
map Mh linemode humanreadablemtime
map Mp linemode permissions
map Ms linemode sizemtime
map MH linemode sizehumanreadablemtime
map Mt linemode metatitle
# Tagging / Marking
map t tag_toggle
map ut tag_remove
map "<any> tag_toggle tag=%any
map <Space> mark_files toggle=True
map v mark_files all=True toggle=True
map uv mark_files all=True val=False
map V toggle_visual_mode
map uV toggle_visual_mode reverse=True
# For the nostalgics: Midnight Commander bindings
map <F1> help
map <F2> rename_append
map <F3> display_file
map <F4> edit
map <F5> copy
map <F6> cut
map <F7> console mkdir%space
map <F8> console delete
#map <F8> console trash
map <F10> exit
# In case you work on a keyboard with dvorak layout
map <UP> move up=1
map <DOWN> move down=1
map <LEFT> move left=1
map <RIGHT> move right=1
map <HOME> move to=0
map <END> move to=-1
map <PAGEDOWN> move down=1 pages=True
map <PAGEUP> move up=1 pages=True
map <CR> move right=1
#map <DELETE> console delete
map <INSERT> console touch%space
# VIM-like
copymap <UP> k
copymap <DOWN> j
copymap <LEFT> h
copymap <RIGHT> l
copymap <HOME> gg
copymap <END> G
copymap <PAGEDOWN> <C-F>
copymap <PAGEUP> <C-B>
map J move down=0.5 pages=True
map K move up=0.5 pages=True
copymap J <C-D>
copymap K <C-U>
# Jumping around
map H history_go -1
map L history_go 1
map ] move_parent 1
map [ move_parent -1
map } traverse
map { traverse_backwards
map ) jump_non
map gh cd ~
map ge cd /etc
map gu cd /usr
map gd cd /dev
map gl cd -r .
map gL cd -r %f
map go cd /opt
map gv cd /var
map gm cd /media
map gi eval fm.cd('/run/media/' + os.getenv('USER'))
map gM cd /mnt
map gs cd /srv
map gp cd /tmp
map gr cd /
map gR eval fm.cd(ranger.RANGERDIR)
map g/ cd /
map g? cd /usr/share/doc/ranger
# External Programs
map E edit
map du shell -p du --max-depth=1 -h --apparent-size
map dU shell -p du --max-depth=1 -h --apparent-size | sort -rh
map yp yank path
map yd yank dir
map yn yank name
map y. yank name_without_extension
# Filesystem Operations
map = chmod
map cw console rename%space
map a rename_append
map A eval fm.open_console('rename ' + fm.thisfile.relative_path.replace("%", "%%"))
map I eval fm.open_console('rename ' + fm.thisfile.relative_path.replace("%", "%%"), position=7)
map pp paste
map po paste overwrite=True
map pP paste append=True
map pO paste overwrite=True append=True
map pl paste_symlink relative=False
map pL paste_symlink relative=True
map phl paste_hardlink
map pht paste_hardlinked_subtree
map pd console paste dest=
map p`<any> paste dest=%any_path
map p'<any> paste dest=%any_path
map dD console delete
map dT console trash
map dd cut
map ud uncut
map da cut mode=add
map dr cut mode=remove
map dt cut mode=toggle
map yy copy
map uy uncut
map ya copy mode=add
map yr copy mode=remove
map yt copy mode=toggle
# Temporary workarounds
map dgg eval fm.cut(dirarg=dict(to=0), narg=quantifier)
map dG eval fm.cut(dirarg=dict(to=-1), narg=quantifier)
map dj eval fm.cut(dirarg=dict(down=1), narg=quantifier)
map dk eval fm.cut(dirarg=dict(up=1), narg=quantifier)
map ygg eval fm.copy(dirarg=dict(to=0), narg=quantifier)
map yG eval fm.copy(dirarg=dict(to=-1), narg=quantifier)
map yj eval fm.copy(dirarg=dict(down=1), narg=quantifier)
map yk eval fm.copy(dirarg=dict(up=1), narg=quantifier)
# Searching
map / console search%space
map n search_next
map N search_next forward=False
map ct search_next order=tag
map cs search_next order=size
map ci search_next order=mimetype
map cc search_next order=ctime
map cm search_next order=mtime
map ca search_next order=atime
# Tabs
map <C-n> tab_new
map <C-w> tab_close
map <TAB> tab_move 1
map <S-TAB> tab_move -1
map <A-Right> tab_move 1
map <A-Left> tab_move -1
map gt tab_move 1
map gT tab_move -1
map gn tab_new
map gc tab_close
map uq tab_restore
map <a-1> tab_open 1
map <a-2> tab_open 2
map <a-3> tab_open 3
map <a-4> tab_open 4
map <a-5> tab_open 5
map <a-6> tab_open 6
map <a-7> tab_open 7
map <a-8> tab_open 8
map <a-9> tab_open 9
map <a-r> tab_shift 1
map <a-l> tab_shift -1
# Sorting
map or set sort_reverse!
map oz set sort=random
map os chain set sort=size; set sort_reverse=False
map ob chain set sort=basename; set sort_reverse=False
map on chain set sort=natural; set sort_reverse=False
map om chain set sort=mtime; set sort_reverse=False
map oc chain set sort=ctime; set sort_reverse=False
map oa chain set sort=atime; set sort_reverse=False
map ot chain set sort=type; set sort_reverse=False
map oe chain set sort=extension; set sort_reverse=False
map oS chain set sort=size; set sort_reverse=True
map oB chain set sort=basename; set sort_reverse=True
map oN chain set sort=natural; set sort_reverse=True
map oM chain set sort=mtime; set sort_reverse=True
map oC chain set sort=ctime; set sort_reverse=True
map oA chain set sort=atime; set sort_reverse=True
map oT chain set sort=type; set sort_reverse=True
map oE chain set sort=extension; set sort_reverse=True
map dc get_cumulative_size
# Settings
map zc set collapse_preview!
map zd set sort_directories_first!
map zh set show_hidden!
map <C-h> set show_hidden!
copymap <C-h> <backspace>
copymap <backspace> <backspace2>
map zI set flushinput!
map zi set preview_images!
map zm set mouse_enabled!
map zp set preview_files!
map zP set preview_directories!
map zs set sort_case_insensitive!
map zu set autoupdate_cumulative_size!
map zv set use_preview_script!
map zf console filter%space
copymap zf zz
# Filter stack
map .d filter_stack add type d
map .f filter_stack add type f
map .l filter_stack add type l
map .m console filter_stack add mime%space
map .n console filter_stack add name%space
map .# console filter_stack add hash%space
map ." filter_stack add duplicate
map .' filter_stack add unique
map .| filter_stack add or
map .& filter_stack add and
map .! filter_stack add not
map .r filter_stack rotate
map .c filter_stack clear
map .* filter_stack decompose
map .p filter_stack pop
map .. filter_stack show
# Bookmarks
map `<any> enter_bookmark %any
map '<any> enter_bookmark %any
map m<any> set_bookmark %any
map um<any> unset_bookmark %any
map m<bg> draw_bookmarks
copymap m<bg> um<bg> `<bg> '<bg>
# Generate all the chmod bindings with some python help:
eval for arg in "rwxXst": cmd("map +u{0} shell -f chmod u+{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map +g{0} shell -f chmod g+{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map +o{0} shell -f chmod o+{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map +a{0} shell -f chmod a+{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map +{0} shell -f chmod u+{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map -u{0} shell -f chmod u-{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map -g{0} shell -f chmod g-{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map -o{0} shell -f chmod o-{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map -a{0} shell -f chmod a-{0} %s".format(arg))
eval for arg in "rwxXst": cmd("map -{0} shell -f chmod u-{0} %s".format(arg))
# ===================================================================
# == Define keys for the console
# ===================================================================
# Note: Unmapped keys are passed directly to the console.
# Basic
cmap <tab> eval fm.ui.console.tab()
cmap <s-tab> eval fm.ui.console.tab(-1)
cmap <ESC> eval fm.ui.console.close()
cmap <CR> eval fm.ui.console.execute()
cmap <C-l> redraw_window
copycmap <ESC> <C-c>
copycmap <CR> <C-j>
# Move around
cmap <up> eval fm.ui.console.history_move(-1)
cmap <down> eval fm.ui.console.history_move(1)
cmap <left> eval fm.ui.console.move(left=1)
cmap <right> eval fm.ui.console.move(right=1)
cmap <home> eval fm.ui.console.move(right=0, absolute=True)
cmap <end> eval fm.ui.console.move(right=-1, absolute=True)
cmap <a-b> eval fm.ui.console.move_word(left=1)
cmap <a-f> eval fm.ui.console.move_word(right=1)
copycmap <a-b> <a-left>
copycmap <a-f> <a-right>
# Line Editing
cmap <backspace> eval fm.ui.console.delete(-1)
cmap <delete> eval fm.ui.console.delete(0)
cmap <C-w> eval fm.ui.console.delete_word()
cmap <A-d> eval fm.ui.console.delete_word(backward=False)
cmap <C-k> eval fm.ui.console.delete_rest(1)
cmap <C-u> eval fm.ui.console.delete_rest(-1)
cmap <C-y> eval fm.ui.console.paste()
# And of course the emacs way
copycmap <ESC> <C-g>
copycmap <up> <C-p>
copycmap <down> <C-n>
copycmap <left> <C-b>
copycmap <right> <C-f>
copycmap <home> <C-a>
copycmap <end> <C-e>
copycmap <delete> <C-d>
copycmap <backspace> <C-h>
# Note: There are multiple ways to express backspaces. <backspace> (code 263)
# and <backspace2> (code 127). To be sure, use both.
copycmap <backspace> <backspace2>
# This special expression allows typing in numerals:
cmap <allow_quantifiers> false
# ===================================================================
# == Pager Keybindings
# ===================================================================
# Movement
pmap <down> pager_move down=1
pmap <up> pager_move up=1
pmap <left> pager_move left=4
pmap <right> pager_move right=4
pmap <home> pager_move to=0
pmap <end> pager_move to=-1
pmap <pagedown> pager_move down=1.0 pages=True
pmap <pageup> pager_move up=1.0 pages=True
pmap <C-d> pager_move down=0.5 pages=True
pmap <C-u> pager_move up=0.5 pages=True
copypmap <UP> k <C-p>
copypmap <DOWN> j <C-n> <CR>
copypmap <LEFT> h
copypmap <RIGHT> l
copypmap <HOME> g
copypmap <END> G
copypmap <C-d> d
copypmap <C-u> u
copypmap <PAGEDOWN> n f <C-F> <Space>
copypmap <PAGEUP> p b <C-B>
# Basic
pmap <C-l> redraw_window
pmap <ESC> pager_close
copypmap <ESC> q Q i <F3>
pmap E edit_file
# ===================================================================
# == Taskview Keybindings
# ===================================================================
# Movement
tmap <up> taskview_move up=1
tmap <down> taskview_move down=1
tmap <home> taskview_move to=0
tmap <end> taskview_move to=-1
tmap <pagedown> taskview_move down=1.0 pages=True
tmap <pageup> taskview_move up=1.0 pages=True
tmap <C-d> taskview_move down=0.5 pages=True
tmap <C-u> taskview_move up=0.5 pages=True
copytmap <UP> k <C-p>
copytmap <DOWN> j <C-n> <CR>
copytmap <HOME> g
copytmap <END> G
copytmap <C-u> u
copytmap <PAGEDOWN> n f <C-F> <Space>
copytmap <PAGEUP> p b <C-B>
# Changing priority and deleting tasks
tmap J eval -q fm.ui.taskview.task_move(-1)
tmap K eval -q fm.ui.taskview.task_move(0)
tmap dd eval -q fm.ui.taskview.task_remove()
tmap <pagedown> eval -q fm.ui.taskview.task_move(-1)
tmap <pageup> eval -q fm.ui.taskview.task_move(0)
tmap <delete> eval -q fm.ui.taskview.task_remove()
# Basic
tmap <C-l> redraw_window
tmap <ESC> taskview_close
copytmap <ESC> q Q w <C-c>

132
.config/rofi/app_launcher.rasi Executable file
View File

@@ -0,0 +1,132 @@
// Config //
configuration {
modi: "drun,filebrowser,window,run";
show-icons: true;
display-drun: "";
display-run: "";
display-filebrowser: "";
display-window: "";
drun-display-format: "{name}";
window-format: "{w}{t}";
icon-theme: "Papirus";
}
// Theme //
@theme "~/.config/rofi/themes/theme.rasi"
// Main //
window {
height: 506px; // 16:9
width: 900px; // 16:9
transparency: "real";
fullscreen: false;
enabled: true;
cursor: "default";
spacing: 0px;
padding: 0px;
border: 2px;
border-radius: 15px;
border-color: @main-br;
background-color: transparent;
}
mainbox {
enabled: true;
spacing: 0px;
padding: 0px;
orientation: vertical;
children: [ "inputbar" , "listbox" ];
background-color: transparent;
background-image: url("~/.config/hypr/theme/current_background.jpg", width);
}
// Inputs //
inputbar {
enabled: true;
spacing: 0px;
padding: 40px;
children: [ "entry" ];
background-color: @main-bg;
}
entry {
border-radius: 30px;
enabled: true;
spacing: 0px;
padding: 20px;
text-color: @main-fg;
background-color: @main-bg;
}
// Lists //
listbox {
padding: 30px;
spacing: 0px;
orientation: horizontal;
children: [ "listview" , "mode-switcher" ];
background-color: @main-bg;
}
listview {
padding: 0px;
spacing: 10px;
enabled: true;
columns: 2;
cycle: true;
dynamic: true;
scrollbar: false;
layout: vertical;
reverse: false;
fixed-height: true;
fixed-columns: true;
cursor: "default";
background-color: transparent;
text-color: @main-fg;
}
mode-switcher {
orientation: vertical;
width: 95px;
enabled: true;
padding: 15px;
spacing: 10px;
background-color: transparent;
}
button {
cursor: pointer;
border-radius: 20px;
background-color: @main-bg;
text-color: @main-fg;
}
button selected {
background-color: @main-fg;
text-color: @main-bg;
}
// Elements //
element {
enabled: true;
spacing: 20px;
padding: 9px;
border-radius: 25px;
cursor: pointer;
background-color: transparent;
text-color: @main-fg;
}
element selected.normal {
background-color: @select-bg;
text-color: @select-fg;
}
element-icon {
size: 47px;
cursor: inherit;
background-color: transparent;
text-color: inherit;
}
element-text {
vertical-align: 0.5;
horizontal-align: 0.0;
cursor: inherit;
background-color: transparent;
text-color: inherit;
}

98
.config/rofi/clipboard.rasi Executable file
View File

@@ -0,0 +1,98 @@
// Config //
configuration {
modi: "drun";
show-icons: false;
}
// Theme //
@theme "~/.config/rofi/themes/theme.rasi"
// Main //
window {
height: 50%;
width: 20%;
location: center;
transparency: "real";
fullscreen: false;
enabled: true;
cursor: "default";
spacing: 0px;
padding: 0px;
border: 2px;
border-radius: 15px;
border-color: @main-br;
background-color: transparent;
}
mainbox {
enabled: true;
spacing: 0px;
orientation: vertical;
children: [ "inputbar" , "listbox" ];
background-color: transparent;
}
// Inputs //
inputbar {
enabled: true;
padding: 7px;
children: [ "entry" ];
background-color: @main-bg;
}
entry {
enabled: true;
padding: 40px;
text-color: @main-fg;
background-color: @main-bg;
}
// Lists //
listbox {
spacing: 0px;
padding: 6px;
children: [ "listview" ];
background-color: @main-bg;
}
listview {
enabled: true;
columns: 1;
cycle: true;
dynamic: true;
scrollbar: false;
layout: vertical;
reverse: false;
fixed-height: false;
fixed-columns: true;
cursor: "default";
background-color: transparent;
text-color: @main-fg;
}
// Elements //
element {
enabled: true;
spacing: 0px;
padding: 12px;
border-radius: 10px;
cursor: pointer;
background-color: transparent;
text-color: @main-fg;
}
@media(max-aspect-ratio: 1.8) {
element {
orientation: vertical;
}
}
element selected.normal {
background-color: @select-bg;
text-color: @select-fg;
}
element-text {
vertical-align: 0.0;
horizontal-align: 0.0;
cursor: inherit;
background-color: transparent;
text-color: inherit;
}

151
.config/rofi/main.rasi Executable file
View File

@@ -0,0 +1,151 @@
// Config //
configuration {
modi: "emoji:rofimoji,calc,drun,filebrowser,run";
show-icons: true;
display-drun: "";
display-run: "";
display-filebrowser: "";
display-window: "";
drun-display-format: "{name}";
window-format: "{w}{t}";
icon-theme: "Papirus";
}
// Theme //
@theme "~/.config/rofi/themes/theme.rasi"
// Main //
window {
height: 506px; // 16:9
width: 900px; // 16:9
location: center;
transparency: "real";
fullscreen: false;
enabled: true;
cursor: "default";
spacing: 0px;
padding: 0px;
border: 2px;
border-radius: 15px;
border-color: @main-br;
background-color: transparent;
}
mainbox {
enabled: true;
spacing: 0px;
padding: 0px;
orientation: vertical;
children: [ "inputbar", "listbox" ];
background-color: transparent;
background-image: url("~/.config/hypr/theme/current_background.jpg", width);
}
// Message //
message {
padding: 0px 55px;
background-color: @main-bg;
}
textbox {
enabled: true;
border-radius: 15px;
spacing: 0px;
padding: 20px;
text-color: @main-fg;
background-color: @main-bg;
border: 1px;
border-color: @main-br;
}
// Inputs //
inputbar {
enabled: true;
spacing: 0px;
padding: 40px;
children: [ "entry" ];
background-color: @main-bg;
}
entry {
enabled: true;
border-radius: 15px;
spacing: 0px;
padding: 20px;
text-color: @main-fg;
background-color: @main-bg;
border: 1px;
border-color: @main-br;
}
// Lists //
listbox {
padding: 30px;
spacing: 0px;
orientation: horizontal;
children: [ "listview" ];
background-color: @main-bg;
}
listview {
padding: 0px;
spacing: 10px;
enabled: true;
columns: 2;
cycle: true;
dynamic: true;
scrollbar: false;
layout: vertical;
reverse: false;
fixed-height: true;
fixed-columns: true;
cursor: "default";
background-color: transparent;
text-color: @main-fg;
}
mode-switcher {
orientation: vertical;
width: 95px;
enabled: true;
padding: 15px;
spacing: 10px;
background-color: transparent;
}
button {
cursor: pointer;
border-radius: 20px;
background-color: @main-bg;
text-color: @main-fg;
}
button selected {
background-color: @main-fg;
text-color: @main-bg;
}
// Elements //
element {
enabled: true;
spacing: 20px;
padding: 9px;
border-radius: 25px;
cursor: pointer;
background-color: transparent;
text-color: @main-fg;
}
element selected.normal {
background-color: @select-bg;
text-color: @select-fg;
}
element-icon {
size: 47px;
cursor: inherit;
background-color: transparent;
text-color: inherit;
}
element-text {
vertical-align: 0.5;
horizontal-align: 0.0;
cursor: inherit;
background-color: transparent;
text-color: inherit;
}

14
.config/rofi/themes/theme.rasi Executable file
View File

@@ -0,0 +1,14 @@
/*
* https://github.com/catppuccin/rofi/
*/
* {
main-bg: #11111bd6;
main-fg: #cdd6f4ff;
main-br: #7dc4e4ff; /*#cba6f7ff;*/
main-ex: #f5e0dcff;
select-bg: #b4befeff;
select-fg: #11111bff;
separatorcolor: transparent;
border-color: transparent;
}

3
.config/rofimoji.rc Normal file
View File

@@ -0,0 +1,3 @@
action = copy
files = [emojis, gitmoji, hebrew, fontawesome6, math]
skin-tone=ask

147
.config/starship.toml Executable file
View File

@@ -0,0 +1,147 @@
## FIRST LINE/ROW: Info & Status
# First param ─┌
[username]
format = " [╭─$user]($style)@"
show_always = true
style_root = "bold red"
style_user = "bold red"
# Second param
[hostname]
disabled = false
format = "[$hostname]($style) in "
ssh_only = false
style = "bold dimmed red"
trim_at = "-"
# Third param
[directory]
style = "purple"
truncate_to_repo = true
truncation_length = 0
truncation_symbol = "repo: "
# Fourth param
[sudo]
disabled = false
# Before all the version info (python, nodejs, php, etc.)
[git_status]
ahead = "⇡${count}"
behind = "⇣${count}"
deleted = "x"
diverged = "⇕⇡${ahead_count}⇣${behind_count}"
style = "white"
# Last param in the first line/row
[cmd_duration]
disabled = false
format = "took [$duration]($style)"
min_time = 1
## SECOND LINE/ROW: Prompt
# Somethere at the beginning
[battery]
charging_symbol = ""
disabled = true
discharging_symbol = ""
full_symbol = ""
[[battery.display]] # "bold red" style when capacity is between 0% and 10%
disabled = false
style = "bold red"
threshold = 15
[[battery.display]] # "bold yellow" style when capacity is between 10% and 30%
disabled = true
style = "bold yellow"
threshold = 50
[[battery.display]] # "bold green" style when capacity is between 10% and 30%
disabled = true
style = "bold green"
threshold = 80
# Prompt: optional param 1
[time]
disabled = true
format = " 🕙 $time($style)\n"
style = "bright-white"
time_format = "%T"
# Prompt: param 2
[character]
error_symbol = " [×](bold red)"
success_symbol = " [╰─λ](bold red)"
# SYMBOLS
[status]
disabled = false
format = '[\[$symbol$status_common_meaning$status_signal_name$status_maybe_int\]]($style)'
map_symbol = true
pipestatus = true
symbol = "🔴"
[aws]
symbol = " "
[conda]
symbol = " "
[dart]
symbol = " "
[docker_context]
symbol = " "
[elixir]
symbol = " "
[elm]
symbol = " "
[git_branch]
symbol = " "
[golang]
symbol = " "
[hg_branch]
symbol = " "
[java]
symbol = " "
[julia]
symbol = " "
[nim]
symbol = " "
[nix_shell]
symbol = " "
[nodejs]
symbol = " "
[package]
symbol = " "
[perl]
symbol = " "
[php]
symbol = " "
[python]
symbol = " "
[ruby]
symbol = " "
[rust]
symbol = " "
[swift]
symbol = "ﯣ "

9
.config/swaylock/swaylock.conf Executable file
View File

@@ -0,0 +1,9 @@
color=550000
clock
indicator
effect-scale=0.4
effect-vignette=0.2:0.5
effect-blur=4x2
timestr=%k:%M
datestr=%a %e.%m.%Y
image=~/.config/hypr/theme/current_background.jpg

91
.config/swaync/config.json Executable file
View File

@@ -0,0 +1,91 @@
{
"$schema": "/etc/xdg/swaync/configSchema.json",
"positionX": "right",
"positionY": "top",
"layer": "overlay",
"control-center-layer": "top",
"layer-shell": true,
"cssPriority": "application",
"control-center-margin-top": 0,
"control-center-margin-bottom": 0,
"control-center-margin-right": 0,
"control-center-margin-left": 0,
"notification-2fa-action": true,
"notification-inline-replies": true,
"notification-icon-size": 64,
"notification-body-image-height": 100,
"notification-body-image-width": 200,
"timeout": 10,
"timeout-low": 5,
"timeout-critical": 0,
"fit-to-screen": true,
"control-center-width": 500,
"control-center-height": 600,
"notification-window-width": 500,
"keyboard-shortcuts": true,
"image-visibility": "when-available",
"transition-time": 200,
"hide-on-clear": true,
"hide-on-action": true,
"script-fail-notify": true,
"scripts-example": {
"example-script": {
"exec": "echo 'Custom config?'",
"urgency": "Normal"
}
},
"widgets": [
"buttons-grid",
"inhibitors",
"title",
"dnd",
"notifications"
],
"widget-config": {
"inhibitors": {
"text": "Inhibitors",
"button-text": "Clear All",
"clear-all-button": true
},
"title": {
"text": "Notifications",
"clear-all-button": true,
"button-text": "Clear All"
},
"dnd": {
"text": "Do Not Disturb"
},
"label": {
"max-lines": 5,
"text": "Label Text"
},
"mpris": {
"image-size": 96,
"image-radius": 12
},
"buttons-grid": {
"actions": [
{
"label": "󰐥",
"command": "systemctl poweroff"
},
{
"label": "󰜉",
"command": "systemctl reboot"
},
{
"label": "󰏥",
"command": "systemctl suspend"
},
{
"label": "󰌾",
"command": "~/.config/hypr/scripts/lock.sh"
},
{
"label": "󰍃",
"command": "hyprctl dispatch exit 0"
}
]
}
}
}

294
.config/swaync/style.css Executable file
View File

@@ -0,0 +1,294 @@
* {
all: unset;
font-size: 14px;
font-family: "FiraCode Nerd Font";
transition: 200ms;
}
.blank-window {
background: alpha(black, 0.25);
}
.widget-buttons-grid {
font-size: x-large;
padding: 8px;
margin: 20px 0px;
border-radius: 12px;
background: #363a4f;
}
.widget-buttons-grid>flowbox>flowboxchild>button {
margin: 3px;
background: #343b58;
border-radius: 12px;
color: #cad3f5;
}
.widget-buttons-grid>flowbox>flowboxchild>button:hover {
/* background: @noti-bg-hover; */
color: #8aadf4;
}
.floating-notifications.background .notification-row .notification-background {
box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.8), inset 0 0 0 1px #363a4f;
border-radius: 12.6px;
margin: 18px;
background-color: #24273a;
color: #cad3f5;
padding: 0;
}
.floating-notifications.background .notification-row .notification-background .notification {
padding: 7px;
border-radius: 12.6px;
}
.floating-notifications.background .notification-row .notification-background .notification.critical {
box-shadow: inset 0 0 7px 0 #ed8796;
}
.floating-notifications.background .notification-row .notification-background .notification .notification-content {
margin: 7px;
}
.floating-notifications.background .notification-row .notification-background .notification .notification-content .summary {
color: #cad3f5;
}
.floating-notifications.background .notification-row .notification-background .notification .notification-content .time {
color: #a5adcb;
}
.floating-notifications.background .notification-row .notification-background .notification .notification-content .body {
color: #cad3f5;
}
.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * {
min-height: 3.4em;
}
.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action {
border-radius: 7px;
color: #cad3f5;
background-color: #363a4f;
box-shadow: inset 0 0 0 1px #494d64;
margin: 7px;
}
.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action:hover {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #363a4f;
color: #cad3f5;
}
.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action:active {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #7dc4e4;
color: #cad3f5;
}
.floating-notifications.background .notification-row .notification-background .close-button {
margin: 7px;
padding: 2px;
border-radius: 6.3px;
color: #24273a;
background-color: #ed8796;
}
.floating-notifications.background .notification-row .notification-background .close-button:hover {
background-color: #ee99a0;
color: #24273a;
}
.floating-notifications.background .notification-row .notification-background .close-button:active {
background-color: #ed8796;
color: #24273a;
}
.control-center {
box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.8), inset 0 0 0 1px #363a4f;
border-radius: 12.6px;
margin: 18px;
background-color: #24273a;
color: #cad3f5;
padding: 14px;
}
.control-center .widget-title {
color: #cad3f5;
font-size: 1.3em;
}
.control-center .widget-title button {
border-radius: 7px;
color: #cad3f5;
background-color: #363a4f;
box-shadow: inset 0 0 0 1px #494d64;
padding: 8px;
}
.control-center .widget-title button:hover {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #5b6078;
color: #cad3f5;
}
.control-center .widget-title button:active {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #7dc4e4;
color: #24273a;
}
.control-center .notification-row .notification-background {
border-radius: 7px;
color: #cad3f5;
background-color: #363a4f;
box-shadow: inset 0 0 0 1px #494d64;
margin-top: 14px;
}
.control-center .notification-row .notification-background .notification {
padding: 7px;
border-radius: 7px;
}
.control-center .notification-row .notification-background .notification.critical {
box-shadow: inset 0 0 7px 0 #ed8796;
}
.control-center .notification-row .notification-background .notification .notification-content {
margin: 7px;
}
.control-center .notification-row .notification-background .notification .notification-content .summary {
color: #cad3f5;
}
.control-center .notification-row .notification-background .notification .notification-content .time {
color: #a5adcb;
}
.control-center .notification-row .notification-background .notification .notification-content .body {
color: #cad3f5;
}
.control-center .notification-row .notification-background .notification > *:last-child > * {
min-height: 3.4em;
}
.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action {
border-radius: 7px;
color: #cad3f5;
background-color: #181926;
box-shadow: inset 0 0 0 1px #494d64;
margin: 7px;
}
.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action:hover {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #363a4f;
color: #cad3f5;
}
.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action:active {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #7dc4e4;
color: #cad3f5;
}
.control-center .notification-row .notification-background .close-button {
margin: 7px;
padding: 2px;
border-radius: 6.3px;
color: #24273a;
background-color: #ee99a0;
}
.control-center .notification-row .notification-background .close-button:hover {
background-color: #ed8796;
color: #24273a;
}
.control-center .notification-row .notification-background .close-button:active {
background-color: #ed8796;
color: #24273a;
}
.control-center .notification-row .notification-background:hover {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #8087a2;
color: #cad3f5;
}
.control-center .notification-row .notification-background:active {
box-shadow: inset 0 0 0 1px #494d64;
background-color: #7dc4e4;
color: #cad3f5;
}
progressbar,
progress,
trough {
border-radius: 12.6px;
}
progressbar {
box-shadow: inset 0 0 0 1px #494d64;
}
.notification.critical progress {
background-color: #ed8796;
}
.notification.low progress,
.notification.normal progress {
background-color: #8aadf4;
}
trough {
background-color: #363a4f;
}
.control-center trough {
background-color: #494d64;
}
.control-center-dnd {
margin-top: 5px;
border-radius: 8px;
background: #363a4f;
border: 1px solid #494d64;
box-shadow: none;
}
.control-center-dnd:checked {
background: #363a4f;
}
.control-center-dnd slider {
background: #494d64;
border-radius: 8px;
}
.widget-dnd {
margin: 0px;
font-size: 1.1rem;
}
.widget-dnd > switch {
font-size: initial;
border-radius: 8px;
background: #363a4f;
border: 1px solid #494d64;
box-shadow: none;
}
.widget-dnd > switch:checked {
background: #363a4f;
}
.widget-dnd > switch slider {
background: #494d64;
border-radius: 8px;
border: 1px solid #6e738d;
}

15
.config/user-dirs.dirs Executable file
View File

@@ -0,0 +1,15 @@
# 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/Desktop"
XDG_DOWNLOAD_DIR="$HOME/Data/Downloads"
XDG_TEMPLATES_DIR="$HOME/Templates"
XDG_PUBLICSHARE_DIR="$HOME/Public"
XDG_DOCUMENTS_DIR="$HOME/Data/Documents"
XDG_MUSIC_DIR="$HOME/Data/Music"
XDG_PICTURES_DIR="$HOME/Data/Pictures"
XDG_VIDEOS_DIR="$HOME/Data/Videos"

37
.config/waybar/colors.css Executable file
View File

@@ -0,0 +1,37 @@
/*
*
* Catppuccin Frappe palette
* Maintainer: rubyowo
*
*/
@define-color base #303446;
@define-color mantle #292c3c;
@define-color crust #232634;
@define-color text #c6d0f5;
@define-color subtext0 #a5adce;
@define-color subtext1 #b5bfe2;
@define-color surface0 #414559;
@define-color surface1 #51576d;
@define-color surface2 #626880;
@define-color overlay0 #737994;
@define-color overlay1 #838ba7;
@define-color overlay2 #949cbb;
@define-color blue #8caaee;
@define-color lavender #babbf1;
@define-color sapphire #85c1dc;
@define-color sky #99d1db;
@define-color teal #81c8be;
@define-color green #a6d189;
@define-color yellow #e5c890;
@define-color peach #ef9f76;
@define-color maroon #ea999c;
@define-color red #e78284;
@define-color mauve #ca9ee6;
@define-color pink #f4b8e4;
@define-color flamingo #eebebe;
@define-color rosewater #f2d5cf;

152
.config/waybar/config Executable file
View File

@@ -0,0 +1,152 @@
{
"layer": "top",
"position": "top",
"height": 40,
"modules-left": [
"hyprland/workspaces",
"hyprland/window",
],
"modules-center": [
"clock",
],
"modules-right": [
"tray",
"custom/playerctl",
"cpu",
"memory",
"network",
"pulseaudio",
"battery",
"custom/power",
],
"hyprland/workspaces": {
"disable-scroll": true,
"all-outputs": true,
"on-click": "activate",
"format": "{icon}",
"format-icons": {
"1": "1",
"2": "2",
"3": "3",
"4": "4",
"5": "5",
"6": "6",
"7": "7",
"8": "8",
"9": "9",
"10": "10"
}
},
"hyprland/window": {
"format": "{}"
},
"clock": {
"format": "{: %H:%M %p  %h %d %Y}",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
"on-click": "merkuro-calendar"
},
"tray": {
"icon-size": 15,
"spacing": 10
},
"custom/playerctl": {
"format": "{icon}",
"return-type": "json",
"max-length": 64,
"exec": "playerctl -a metadata --format '{\"text\": \"{{artist}} - {{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F",
"on-click-middle": "playerctl play-pause",
"on-click": "playerctl previous",
"on-click-right": "playerctl next",
"format-icons": {
"Playing": "<span foreground='#E5B9C6'>󰒮 󰐌 󰒭</span>",
"Paused": "<span foreground='#928374'>󰒮 󰏥 󰒭</span>"
},
},
"cpu": {
"interval": 10,
"format": "{usage}% ",
"format-alt": "{avg_frequency} GHz ",
"on-double-click": "gnome-system-monitor"
},
"memory": {
"interval": 30,
"format": "{used:0.1f}G ",
"format-alt": "{used:0.1f}G/{total:0.1f}G ",
"tooltip-format": "{}%",
"on-double-click": "gnome-system-monitor"
},
"network": {
"interval": 10,
"format-wifi": "{essid} ",
"format-ethernet": "{bandwidthUpBytes}⇡ {bandwidthDownBytes}⇣{essid} ",
"format-linked": "{ifname} (No IP) ",
"format-disconnected": "󰖪 Disconnected",
"tooltip-format-wifi": "Signal Strenght: {signalStrength}% | Down Speed: {bandwidthDownBits}, Up Speed: {bandwidthUpBits}",
},
"pulseaudio": {
"format": "{volume}% {icon} {format_source}",
"format-bluetooth": "{volume}%{icon} {format_source}",
"format-bluetooth-muted": " {icon} {format_source}",
"format-muted": "\udb81\udf5f {format_source}",
"format-source": "{volume}% ",
"format-source-muted": "",
"format-icons": {
"headphone": "",
"hands-free": "",
"headset": "",
"phone": "",
"portable": "",
"car": "",
"default": [
"",
"",
""
]
},
"on-click-right": "pactl set-source-mute @DEFAULT_SOURCE@ toggle",
"on-click-middle": "pactl set-sink-mute @DEFAULT_SINK@ toggle",
"on-double-click": "pavucontrol"
},
"custom/power": {
"format": "󰐥",
"on-click": "wlogout"
},
//Laptop
"backlight":{
"device": "intel_backlight",
"format": "{icon} {percent}%",
"format-icons": ["","",""],
"on-scroll-up": "brightnessctl set 1%+",
"on-scroll-down": "brightnessctl set 1%-",
"min-length": 6
},
"battery": {
"states": {
"good": 95,
"warning": 30,
"critical": 20
},
"format": "{icon} {capacity}%",
"format-charging": " {capacity}%",
"format-plugged": " {capacity}%",
"format-alt": "{time} {icon}",
"format-icons": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " "]
},
"custom/wl-gammarelay-temperature": {
"format": " {}",
"exec": "wl-gammarelay-rs watch {t}",
"on-scroll-up": "~/.config/hypr/scripts/brightness.sh temperature-up 100",
"on-scroll-down": "~/.config/hypr/scripts/brightness.sh temperature-down 100"
},
"custom/wl-gammarelay-brightness": {
"format": " {}",
"exec": "wl-gammarelay-rs watch {bp}",
"on-scroll-up": "~/.config/hypr/scripts/brightness.sh brightness-up 0.05",
"on-scroll-down": "~/.config/hypr/scripts/brightness.sh brightness-down 0.05"
}
}

45
.config/waybar/style.css Executable file
View File

@@ -0,0 +1,45 @@
@import "colors.css";
* {
border: none;
border-radius: 5px;
font-family: monospace;
font-weight: bold;
font-size: 14px;
min-height: 0px;
color: @text;
}
#waybar {
background: @surface0;
}
#clock, #battery, #pulseaudio, #network, #tray, #cpu, #memory, #backlight, #workspaces, #window, #custom-playerctl, #custom-language, #custom-spotify, #custom-updates, #custom-caffeine, #custom-wl-gammarelay-brightness, #custom-wl-gammarelay-temperature, #custom-menu, #custom-power {
background: @surface1;
margin: 7px 0px 7px 5px;
padding: 0px 10px;
}
#custom-power {
font-weight: normal;
font-size: 18px;
margin-right: 5px;
}
#workspaces button {
padding: 2px;
margin: 3px;
}
#workspaces button.active {
background: @overlay0;
}
#workspaces button:hover {
background: @overlay2;
}
tooltip {
background: @surface0;
border: solid 2px @surface1;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

BIN
.config/wlogout/imgs/lock.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
.config/wlogout/imgs/logout.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
.config/wlogout/imgs/power.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

BIN
.config/wlogout/imgs/restart.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

BIN
.config/wlogout/imgs/sleep.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

36
.config/wlogout/layout Executable file
View File

@@ -0,0 +1,36 @@
{
"label" : "lock",
"action" : "~/.config/hypr/scripts/lock.sh",
"text" : "Lock",
"keybind" : "l"
}
{
"label" : "reboot",
"action" : "systemctl reboot",
"text" : "Reboot",
"keybind" : "r"
}
{
"label" : "shutdown",
"action" : "systemctl poweroff",
"text" : "Shutdown",
"keybind" : "s"
}
{
"label" : "logout",
"action" : "hyprctl dispatch exit 0",
"text" : "Logout",
"keybind" : "e"
}
{
"label" : "suspend",
"action" : "systemctl suspend",
"text" : "Suspend",
"keybind" : "u"
}
{
"label" : "suspend",
"action" : "systemctl hibernate",
"text" : "Hibernate",
"keybind" : "h"
}

61
.config/wlogout/style.css Executable file
View File

@@ -0,0 +1,61 @@
window {
font-family: monospace;
font-size: 14pt;
color: #cdd6f4; /* text */
background-color: rgba(30, 30, 46, 0.5);
}
button {
background-repeat: no-repeat;
background-position: center;
background-size: 25%;
border: none;
background-color: rgba(30, 30, 46, 0);
margin: 5px;
transition: box-shadow 0.2s ease-in-out, background-color 0.2s ease-in-out;
}
button:hover {
background-color: rgba(49, 50, 68, 0.1);
}
button:focus {
background-color: #cba6f7;
color: #1e1e2e;
border: none;
}
#lock {
background-image: image(url("./imgs/lock.png"));
}
#lock:focus {
background-image: image(url("./imgs/lock-hover.png"));
}
#logout {
background-image: image(url("./imgs/logout.png"));
}
#logout:focus {
background-image: image(url("./imgs/logout-hover.png"));
}
#suspend {
background-image: image(url("./imgs/sleep.png"));
}
#suspend:focus {
background-image: image(url("./imgs/sleep-hover.png"));
}
#shutdown {
background-image: image(url("./imgs/power.png"));
}
#shutdown:focus {
background-image: image(url("./imgs/power-hover.png"));
}
#reboot {
background-image: image(url("./imgs/restart.png"));
}
#reboot:focus {
background-image: image(url("./imgs/restart-hover.png"));
}