From 3c45a0af5e933a7b432a4a1022bcb5bca9bfa4f2 Mon Sep 17 00:00:00 2001 From: simon Date: Sun, 25 Oct 2026 13:43:10 -0500 Subject: full restructure based on machine --- blade/conky.conf | 88 +++++++++ blade/i3blocks.conf | 47 +++++ blade/i3config | 214 ++++++++++++++++++++++ blade/picom.conf | 36 ++++ blade/rofi-power-menu | 283 +++++++++++++++++++++++++++++ blade/sakura.conf | 79 ++++++++ blade/theme.rasi | 116 ++++++++++++ conky.conf | 88 --------- desktop/init.lua | 105 +++++++++++ desktop/swayconfig | 255 ++++++++++++++++++++++++++ desktop/waybar-wal-template.css | 329 ++++++++++++++++++++++++++++++++++ desktop/waybar_config | 220 +++++++++++++++++++++++ i3blocks.conf | 47 ----- i3config | 266 --------------------------- nvim/init.lua | 105 ----------- nvim/windows-init.lua | 105 ----------- picom.conf | 36 ---- rofi-power-menu | 283 ----------------------------- sakura.conf | 79 -------- swayconfig | 255 -------------------------- theme.rasi | 116 ------------ wal/templates/desktop-rofi-theme.rasi | 113 ++++++++++++ wal/templates/theme.rasi | 113 ------------ waybar-wal-template.css | 329 ---------------------------------- waybar_config | 220 ----------------------- windows/windows-init.lua | 105 +++++++++++ 26 files changed, 1990 insertions(+), 2042 deletions(-) create mode 100644 blade/conky.conf create mode 100644 blade/i3blocks.conf create mode 100644 blade/i3config create mode 100644 blade/picom.conf create mode 100755 blade/rofi-power-menu create mode 100644 blade/sakura.conf create mode 100644 blade/theme.rasi delete mode 100644 conky.conf create mode 100644 desktop/init.lua create mode 100644 desktop/swayconfig create mode 100644 desktop/waybar-wal-template.css create mode 100644 desktop/waybar_config delete mode 100644 i3blocks.conf delete mode 100644 i3config delete mode 100644 nvim/init.lua delete mode 100644 nvim/windows-init.lua delete mode 100644 picom.conf delete mode 100755 rofi-power-menu delete mode 100644 sakura.conf delete mode 100644 swayconfig delete mode 100644 theme.rasi create mode 100644 wal/templates/desktop-rofi-theme.rasi delete mode 100644 wal/templates/theme.rasi delete mode 100644 waybar-wal-template.css delete mode 100644 waybar_config create mode 100644 windows/windows-init.lua diff --git a/blade/conky.conf b/blade/conky.conf new file mode 100644 index 0000000..4bd061d --- /dev/null +++ b/blade/conky.conf @@ -0,0 +1,88 @@ +-- Conky, a system monitor https://github.com/brndnmtthws/conky +-- +-- This configuration file is Lua code. You can write code in here, and it will +-- execute when Conky loads. You can use it to generate your own advanced +-- configurations. +-- +-- Try this (remove the `--`): +-- +-- print("Loading Conky config") +-- +-- For more on Lua, see: +-- https://www.lua.org/pil/contents.html +-- +-- Conky Lua API: https://conky.cc/lua + +-- Configuration settings: https://conky.cc/config_settings +conky.config = { + alignment = 'bottom_left', + background = true, + border_width = 1, + cpu_avg_samples = 2, + default_color = '#9a8f95', + default_outline_color = '#9a8f95', + default_shade_color = 'white', + double_buffer = true, + draw_borders = false, + draw_graph_borders = true, + draw_outline = false, + draw_shades = false, + extra_newline = false, + font = 'Source Code Pro:size=12', + gap_x = 65, + gap_y = 65, + minimum_height = 5, + minimum_width = 5, + net_avg_samples = 2, + no_buffers = true, + out_to_console = false, + out_to_ncurses = false, + out_to_stderr = false, + out_to_wayland = false, + out_to_x = true, + own_window = true, + own_window_class = 'Conky', + own_window_type = 'normal', + own_window_transparent = no, + own_window_hints = 'undecorated,below,skip_taskbar,skip_pager', + show_graph_range = false, + show_graph_scale = false, + stippled_borders = 0, + update_interval = 1.0, + uppercase = false, + use_spacer = 'none', + use_xft = true, + own_window_colour = '#161314' +} + +-- Variables: https://conky.cc/variables +conky.text = [[ +#${color #c4c4c4}$color ${scroll 40 sup /wg/} +${color #c4c4c4}$color ${scroll 40 :) computer !!! computers are awesome! aw yeah beep beep boop} +$hr +${color #c4c4c4}Uptime:$color $uptime +# ${color #c4c4c4}Frequency (in MHz):$color $freq +# ${color #c4c4c4}Frequency (in GHz):$color $freq_g +${color #c4c4c4}CPU Usage:$color $cpu% ${cpubar 4} +${color #c4c4c4}RAM Usage:$color $memperc% ${membar 4} +# ${color #c4c4c4}RAM Usage:$color $mem/$memmax - $memperc% ${membar 4} +# ${color #c4c4c4}Swap Usage:$color $swap/$swapmax - $swapperc% ${swapbar 4} +${color #c4c4c4}Processes:$color $processes ${color #c4c4c4}Running:$color $running_processes +$hr +${color #c4c4c4}Hard Drive: + $color${fs_used /}/${fs_size /} ${fs_bar 6 /} +${color #c4c4c4}Networking: + Up:$color ${upspeed wlp2s0} ${color #c4c4c4} - Down:$color ${downspeed wlp2s0} +${color #c4c4c4}Battery: + ${battery BAT0} +$hr +${color #c4c4c4}Name PID CPU% MEM% +${color #c4c4c4} ${top name 1} ${top pid 1} ${top cpu 1} ${top mem 1} +${color #c4c4c4} ${top name 2} ${top pid 2} ${top cpu 2} ${top mem 2} +${color #c4c4c4} ${top name 3} ${top pid 3} ${top cpu 3} ${top mem 3} +${color #c4c4c4} ${top name 4} ${top pid 4} ${top cpu 4} ${top mem 4} +${color #c4c4c4} ${top name 5} ${top pid 5} ${top cpu 5} ${top mem 5} +${color #c4c4c4} ${top name 6} ${top pid 6} ${top cpu 6} ${top mem 6} +${color #c4c4c4} ${top name 7} ${top pid 7} ${top cpu 7} ${top mem 7} +${color #c4c4c4} ${top name 8} ${top pid 8} ${top cpu 8} ${top mem 8} +]] diff --git a/blade/i3blocks.conf b/blade/i3blocks.conf new file mode 100644 index 0000000..b6ec925 --- /dev/null +++ b/blade/i3blocks.conf @@ -0,0 +1,47 @@ +# i3blocks configuration file +# +# The i3blocks man page describes the usage of the binary, +# and its website describes the configuration: +# +# https://vivien.github.io/i3blocks + + +# Global properties +separator=true +separator_block_width=30 + +[weather] +command=curl -Ss 'https://wttr.in?0&T&Q' | cut -c 16- | head -2 | xargs echo +interval=1800 +# color=#c0caf5 + +[brightness] +command=echo " $(brightnessctl get | awk '{print $0 / 24000 * 100}')" +signal=11 +interval=once +# color=#c0caf5 + +[volume] +command=i3blocks_volume +# echo "vol: $(pactl get-sink-volume @DEFAULT_SINK@ | awk '{printf "%s", substr($5, 1, length($5) - 1)}')" +# command=echo "vol: $(wpctl get-volume 50 | awk '{print $2*100}')" +signal=10 +interval=once +# color=#c0caf5 + +[date] +command=date '+%a, %b %d' +interval=once +# color=#c0caf5 +# color=#c0caf5 + +[time] +command=date '+%H:%M:%S' +interval=1 +# color=#c0caf5 + +# [battery] +command=echo "$(sudo cat /sys/class/power_supply/BAT0/capacity)%" +interval=30 +color=#c0caf5 + diff --git a/blade/i3config b/blade/i3config new file mode 100644 index 0000000..40076ca --- /dev/null +++ b/blade/i3config @@ -0,0 +1,214 @@ +# i3 config file (v4) +# +# Please see https://i3wm.org/docs/userguide.html for a complete reference! +# +# This config file uses keycodes (bindsym) and was written for the QWERTY +# layout. +# +# To get a config file with the same key positions, but for your current +# layout, use the i3-config-wizard +# + +# Font for window titles. Will also be used by the bar unless a different font +# is used in the bar {} block below. +font pango:monospace 8 + +# This font is widely installed, provides lots of unicode glyphs, right-to-left +# text rendering and scalability on retina/hidpi displays (thanks to pango). +#font pango:DejaVu Sans Mono 8 + +# Start XDG autostart .desktop files using dex. See also +# https://wiki.archlinux.org/index.php/XDG_Autostart +exec --no-startup-id dex --autostart --environment i3 + +# The combination of xss-lock, nm-applet and pactl is a popular choice, so +# they are included here as an example. Modify as you see fit. + +# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the +# screen before suspend. Use loginctl lock-session to lock your screen. +exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork + +# NetworkManager is the most popular way to manage wireless networks on Linux, +# and nm-applet is a desktop environment-independent system tray GUI for it. +exec --no-startup-id nm-applet + +# Use pactl to adjust volume in PulseAudio. +set $refresh_i3status killall -SIGUSR1 i3status +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status +bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status + +# use these keys for focus, movement, and resize directions when reaching for +# the arrows is not convenient +set $up l +set $down k +set $left j +set $right semicolon + +# use Mouse+Mod1 to drag floating windows to their wanted position +floating_modifier Mod1 + +# move tiling windows via drag & drop by left-clicking into the title bar, +# or left-clicking anywhere into the window while holding the floating modifier. +tiling_drag modifier titlebar + +# start a terminal +bindsym Mod1+Return exec i3-sensible-terminal + +# kill focused window +bindsym Mod1+Shift+q kill + +# start dmenu (a program launcher) +bindsym Mod1+d exec --no-startup-id dmenu_run +# A more modern dmenu replacement is rofi: +# bindsym Mod1+d exec "rofi -modi drun,run -show drun" +# There also is i3-dmenu-desktop which only displays applications shipping a +# .desktop file. It is a wrapper around dmenu, so you need that installed. +# bindsym Mod1+d exec --no-startup-id i3-dmenu-desktop + +# change focus +bindsym Mod1+$left focus left +bindsym Mod1+$down focus down +bindsym Mod1+$up focus up +bindsym Mod1+$right focus right + +# alternatively, you can use the cursor keys: +bindsym Mod1+Left focus left +bindsym Mod1+Down focus down +bindsym Mod1+Up focus up +bindsym Mod1+Right focus right + +# move focused window +bindsym Mod1+Shift+$left move left +bindsym Mod1+Shift+$down move down +bindsym Mod1+Shift+$up move up +bindsym Mod1+Shift+$right move right + +# alternatively, you can use the cursor keys: +bindsym Mod1+Shift+Left move left +bindsym Mod1+Shift+Down move down +bindsym Mod1+Shift+Up move up +bindsym Mod1+Shift+Right move right + +# split in horizontal orientation +bindsym Mod1+h split h + +# split in vertical orientation +bindsym Mod1+v split v + +# enter fullscreen mode for the focused container +bindsym Mod1+f fullscreen toggle + +# change container layout (stacked, tabbed, toggle split) +bindsym Mod1+s layout stacking +bindsym Mod1+w layout tabbed +bindsym Mod1+e layout toggle split + +# toggle tiling / floating +bindsym Mod1+Shift+space floating toggle + +# change focus between tiling / floating windows +bindsym Mod1+space focus mode_toggle + +# focus the parent container +bindsym Mod1+a focus parent + +# focus the child container +#bindsym Mod1+d focus child + +# move the currently focused window to the scratchpad +bindsym Mod1+Shift+minus move scratchpad + +# Show the next scratchpad window or hide the focused scratchpad window. +# If there are multiple scratchpad windows, this command cycles through them. +bindsym Mod1+minus scratchpad show + +# Define names for default workspaces for which we configure key bindings later on. +# We use variables to avoid repeating the names in multiple places. +set $ws1 "1" +set $ws2 "2" +set $ws3 "3" +set $ws4 "4" +set $ws5 "5" +set $ws6 "6" +set $ws7 "7" +set $ws8 "8" +set $ws9 "9" +set $ws10 "10" + +# switch to workspace +bindsym Mod1+1 workspace number $ws1 +bindsym Mod1+2 workspace number $ws2 +bindsym Mod1+3 workspace number $ws3 +bindsym Mod1+4 workspace number $ws4 +bindsym Mod1+5 workspace number $ws5 +bindsym Mod1+6 workspace number $ws6 +bindsym Mod1+7 workspace number $ws7 +bindsym Mod1+8 workspace number $ws8 +bindsym Mod1+9 workspace number $ws9 +bindsym Mod1+0 workspace number $ws10 + +# move focused container to workspace +bindsym Mod1+Shift+1 move container to workspace number $ws1 +bindsym Mod1+Shift+2 move container to workspace number $ws2 +bindsym Mod1+Shift+3 move container to workspace number $ws3 +bindsym Mod1+Shift+4 move container to workspace number $ws4 +bindsym Mod1+Shift+5 move container to workspace number $ws5 +bindsym Mod1+Shift+6 move container to workspace number $ws6 +bindsym Mod1+Shift+7 move container to workspace number $ws7 +bindsym Mod1+Shift+8 move container to workspace number $ws8 +bindsym Mod1+Shift+9 move container to workspace number $ws9 +bindsym Mod1+Shift+0 move container to workspace number $ws10 + +# reload the configuration file +bindsym Mod1+Shift+c reload +# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) +bindsym Mod1+Shift+r restart +# exit i3 (logs you out of your X session) +bindsym Mod1+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'" + +# resize window (you can also use the mouse for that) +mode "resize" { + # These bindings trigger as soon as you enter the resize mode + + # Pressing left will shrink the window’s width. + # Pressing right will grow the window’s width. + # Pressing up will shrink the window’s height. + # Pressing down will grow the window’s height. + bindsym $left resize shrink width 10 px or 10 ppt + bindsym $down resize grow height 10 px or 10 ppt + bindsym $up resize shrink height 10 px or 10 ppt + bindsym $right resize grow width 10 px or 10 ppt + + # same bindings, but for the arrow keys + bindsym Left resize shrink width 10 px or 10 ppt + bindsym Down resize grow height 10 px or 10 ppt + bindsym Up resize shrink height 10 px or 10 ppt + bindsym Right resize grow width 10 px or 10 ppt + + # back to normal: Enter or Escape or Mod1+r + bindsym Return mode "default" + bindsym Escape mode "default" + bindsym Mod1+r mode "default" +} + +bindsym Mod1+r mode "resize" + +# Start i3bar to display a workspace bar (plus the system information i3status +# finds out, if available) +bar { + status_command i3status +} + +####################################################################### +# automatically start i3-config-wizard to offer the user to create a +# keysym-based config which used their favorite modifier (alt or windows) +# +# i3-config-wizard will not launch if there already is a config file +# in ~/.config/i3/config (or $XDG_CONFIG_HOME/i3/config if set) or +# ~/.i3/config. +# +# Please remove the following exec line: +####################################################################### +exec i3-config-wizard diff --git a/blade/picom.conf b/blade/picom.conf new file mode 100644 index 0000000..99bbf40 --- /dev/null +++ b/blade/picom.conf @@ -0,0 +1,36 @@ +# EXAMPLE CONFIG AT : /etc/xdg/picom.conf +backend = "xrender" + + +# BLURRRRR +blur: +{ + method = "box"; + size = 10; + strength = 7; + background = false; + background-fixed = true; +}; + +shadow = false; +fading = true; +fade-delta = 5; + +# ROUNDER EDGES +# corner-radius = 15; +# rounded-corners-exclude = [ +# "class_g = 'i3bar'", +# "class_g = 'i3-nagbar'" +# ]; + +# OPACITYYY +inactive-opacity = 0.8; +active-opacity = 1; +opacity-rule = [ + "60:class_g = 'Sakura' && !focused", + "80:class_g = 'Conky' && focused", + "60:class_g = 'Conky' && !focused", + "90:class_g = 'Vesktop'", + "90:class_g = 'librewolf' && !focused", + "100:class_g = 'Rofi'" + ]; diff --git a/blade/rofi-power-menu b/blade/rofi-power-menu new file mode 100755 index 0000000..196d552 --- /dev/null +++ b/blade/rofi-power-menu @@ -0,0 +1,283 @@ +#!/usr/bin/env bash + +# This script defines just a mode for rofi instead of being a self-contained +# executable that launches rofi by itself. This makes it more flexible than +# running rofi inside this script as now the user can call rofi as one pleases. +# For instance: +# +# rofi -show powermenu -modi powermenu:./rofi-power-menu +# +# See README.md for more information. + +set -e +set -u + +# All supported choices +all=(shutdown reboot suspend hibernate logout lockscreen) + +# By default, show all (i.e., just copy the array) +show=("${all[@]}") + +declare -A texts +texts[lockscreen]="lock screen" +texts[switchuser]="switch user" +texts[logout]="log out" +texts[suspend]="suspend" +texts[hibernate]="hibernate" +texts[reboot]="reboot" +texts[shutdown]="shut down" + +declare -A icons +icons[lockscreen]="\Uf033e" +icons[switchuser]="\Uf0019" +icons[logout]="\Uf0343" +icons[suspend]="\Uf04b2" +icons[hibernate]="\Uf02ca" +icons[reboot]="\Uf0709" +icons[shutdown]="\Uf0425" +icons[cancel]="\Uf0156" + +declare -A actions +actions[lockscreen]="loginctl lock-session ${XDG_SESSION_ID-}" +#actions[switchuser]="???" +#actions[logout]="loginctl terminate-session ${XDG_SESSION_ID-}" +actions[logout]="i3-msg exit" +actions[suspend]="systemctl suspend" +actions[hibernate]="systemctl hibernate" +actions[reboot]="systemctl reboot" +actions[shutdown]="systemctl poweroff" + +# By default, ask for confirmation for actions that are irreversible +confirmations=(reboot shutdown logout) + +# By default, no dry run +dryrun=false +showsymbols=true +showtext=true + +function check_valid { + option="$1" + shift 1 + for entry in "${@}" + do + if [ -z "${actions[$entry]+x}" ] + then + echo "Invalid choice in $1: $entry" >&2 + exit 1 + fi + done +} + +# Parse command-line options +parsed=$(getopt --options=h --longoptions=help,dry-run,confirm:,choices:,choose:,symbols,no-symbols,text,no-text,symbols-font: --name "$0" -- "$@") +if [ $? -ne 0 ]; then + echo 'Terminating...' >&2 + exit 1 +fi +eval set -- "$parsed" +unset parsed +while true; do + case "$1" in + "-h"|"--help") + echo "rofi-power-menu - a power menu mode for Rofi" + echo + echo "Usage: rofi-power-menu [--choices CHOICES] [--confirm CHOICES]" + echo " [--choose CHOICE] [--dry-run] [--symbols|--no-symbols]" + echo + echo "Use with Rofi in script mode. For instance, to ask for shutdown or reboot:" + echo + echo " rofi -show menu -modi \"menu:rofi-power-menu --choices=shutdown/reboot\"" + echo + echo "Available options:" + echo " --dry-run Don't perform the selected action but print it to stderr." + echo " --choices CHOICES Show only the selected choices in the given order. Use /" + echo " as the separator. Available choices are lockscreen," + echo " logout,suspend, hibernate, reboot and shutdown. By" + echo " default, all available choices are shown." + echo " --confirm CHOICES Require confirmation for the gives choices only. Use / as" + echo " the separator. Available choices are lockscreen, logout," + echo " suspend, hibernate, reboot and shutdown. By default, only" + echo " irreversible actions logout, reboot and shutdown require" + echo " confirmation." + echo " --choose CHOICE Preselect the given choice and only ask for a" + echo " confirmation (if confirmation is set to be requested). It" + echo " is strongly recommended to combine this option with" + echo " --confirm=CHOICE if the choice wouldn't require" + echo " confirmation by default. Available choices are" + echo " lockscreen, logout, suspend, hibernate, reboot and" + echo " shutdown." + echo " --[no-]symbols Show Unicode symbols or not. Requires a font with support" + echo " for the symbols. Use, for instance, fonts from the" + echo " Nerdfonts collection. By default, they are shown" + echo " --[no-]text Show text description or not." + echo " --symbols-font FONT Use the given font for symbols. By default, the symbols" + echo " use the same font as the text. That font is configured" + echo " with rofi." + echo " -h,--help Show this help text." + exit 0 + ;; + "--dry-run") + dryrun=true + shift 1 + ;; + "--confirm") + IFS='/' read -ra confirmations <<< "$2" + check_valid "$1" "${confirmations[@]}" + shift 2 + ;; + "--choices") + IFS='/' read -ra show <<< "$2" + check_valid "$1" "${show[@]}" + shift 2 + ;; + "--choose") + # Check that the choice is valid + check_valid "$1" "$2" + selectionID="$2" + shift 2 + ;; + "--symbols") + showsymbols=true + shift 1 + ;; + "--no-symbols") + showsymbols=false + shift 1 + ;; + "--text") + showtext=true + shift 1 + ;; + "--no-text") + showtext=false + shift 1 + ;; + "--symbols-font") + symbols_font="$2" + shift 2 + ;; + "--") + shift + break + ;; + *) + echo "Internal error" >&2 + exit 1 + ;; + esac +done + +if [ "$showsymbols" = "false" -a "$showtext" = "false" ] +then + echo "Invalid options: cannot have --no-symbols and --no-text enabled at the same time." >&2 + exit 1 +fi + +# Define the messages after parsing the CLI options so that it is possible to +# configure them in the future. + +function write_message { + if [ -z ${symbols_font+x} ]; + then + icon="$1" + else + icon="$1" + fi + text="$2" + if [ "$showsymbols" = "true" ] + then + if [ "$showtext" = "true" ] + then + echo -n "\u200e$icon \u2068$text\u2069" + else + echo -n "\u200e$icon" + fi + else + echo -n "$text" + fi +} + +function print_selection { + echo -e "$1" | $(read -r -d '' entry; echo "echo $entry") +} + +declare -A messages +declare -A confirmationMessages +for entry in "${all[@]}" +do + messages[$entry]=$(write_message "${icons[$entry]}" "${texts[$entry]^}") +done +for entry in "${all[@]}" +do + # Add zero-width space character (\u200b) to icon to ensure confirmation- + # and regular messages never collide. + confirmationMessages[$entry]=$(write_message "${icons[$entry]}\u200b" "Yes, ${texts[$entry]}") +done +confirmationMessages[cancel]=$(write_message "${icons[cancel]}" "No, cancel") + +if [ $# -gt 0 ] +then + # If arguments given, use those as the selection + selection="${@}" +else + # Otherwise, use the CLI passed choice if given + if [ -n "${selectionID+x}" ] + then + selection="${messages[$selectionID]}" + fi +fi + +# Don't allow custom entries +echo -e "\0no-custom\x1ftrue" +# Use markup +echo -e "\0markup-rows\x1ftrue" + +if [ -z "${selection+x}" ] +then + echo -e "\0prompt\x1fPower menu" + for entry in "${show[@]}" + do + echo -e "${messages[$entry]}\0icon\x1f${icons[$entry]}" + done +else + for entry in "${show[@]}" + do + if [ "$selection" = "$(print_selection "${messages[$entry]}")" ] + then + # Check if the selected entry is listed in confirmation requirements + for confirmation in "${confirmations[@]}" + do + if [ "$entry" = "$confirmation" ] + then + # Ask for confirmation + echo -e "\0prompt\x1fAre you sure" + echo -e "${confirmationMessages[$entry]}\0icon\x1f${icons[$entry]}" + echo -e "${confirmationMessages[cancel]}\0icon\x1f${icons[cancel]}" + exit 0 + fi + done + # If not, then no confirmation is required, so mark confirmed + selection=$(print_selection "${confirmationMessages[$entry]}") + fi + if [ "$selection" = "$(print_selection "${confirmationMessages[$entry]}")" ] + then + if [ $dryrun = true ] + then + # Tell what would have been done + echo "Selected: $entry" >&2 + else + # Perform the action + ${actions[$entry]} + fi + exit 0 + fi + if [ "$selection" = "$(print_selection "${confirmationMessages[cancel]}")" ] + then + # Do nothing + exit 0 + fi + done + # The selection didn't match anything, so raise an error + echo "Invalid selection: $selection" >&2 + exit 1 +fi diff --git a/blade/sakura.conf b/blade/sakura.conf new file mode 100644 index 0000000..8e1c8a9 --- /dev/null +++ b/blade/sakura.conf @@ -0,0 +1,79 @@ +[sakura] +colorset1_fore=rgb(229,194,190) +colorset1_back=rgb(15,36,67) +colorset1_curs=rgb(255,255,255) +colorset1_scheme=0 +colorset1_key=F1 +colorset2_fore=rgb(192,192,192) +colorset2_back=rgb(0,0,0) +colorset2_curs=rgb(255,255,255) +colorset2_scheme=1 +colorset2_key=F2 +colorset3_fore=rgb(192,192,192) +colorset3_back=rgb(0,0,0) +colorset3_curs=rgb(255,255,255) +colorset3_scheme=1 +colorset3_key=F3 +colorset4_fore=rgb(192,192,192) +colorset4_back=rgb(0,0,0) +colorset4_curs=rgb(255,255,255) +colorset4_scheme=1 +colorset4_key=F4 +colorset5_fore=rgb(192,192,192) +colorset5_back=rgb(0,0,0) +colorset5_curs=rgb(255,255,255) +colorset5_scheme=1 +colorset5_key=F5 +colorset6_fore=rgb(192,192,192) +colorset6_back=rgb(0,0,0) +colorset6_curs=rgb(255,255,255) +colorset6_scheme=1 +colorset6_key=F6 +last_colorset=1 +bold_is_bright=false +scroll_lines=4096 +font=Source Code Pro 14 +show_tab_bar=multiple +scrollbar=false +closebutton=true +new_tab_after_current=true +tabs_on_bottom=false +less_questions=false +copy_on_select=false +disable_numbered_tabswitch=false +use_fading=false +scrollable_tabs=true +urgent_bell=Yes +audible_bell=Yes +blinking_cursor=No +cursor_type=VTE_CURSOR_SHAPE_BLOCK +word_chars=-,./?%&#_~: +palette=1 +add_tab_accelerator=5 +del_tab_accelerator=5 +switch_tab_accelerator=8 +move_tab_accelerator=9 +copy_accelerator=5 +scrollbar_accelerator=5 +open_url_accelerator=5 +font_size_accelerator=4 +set_tab_name_accelerator=5 +search_accelerator=5 +add_tab_key=T +del_tab_key=W +prev_tab_key=Left +next_tab_key=Right +copy_key=C +paste_key=V +scrollbar_key=S +set_tab_name_key=N +search_key=F +increase_font_size_key=plus +decrease_font_size_key=minus +fullscreen_key=F11 +set_colorset_accelerator=5 +icon_file=terminal-tango.svg +paste_button=2 +menu_button=3 +window_columns=80 +window_rows=24 diff --git a/blade/theme.rasi b/blade/theme.rasi new file mode 100644 index 0000000..8680cbe --- /dev/null +++ b/blade/theme.rasi @@ -0,0 +1,116 @@ +* {{ + font: "IBM Plex Mono 10"; + + bg : {color0}; + scroll : {color8}; + + fg : {foreground}; + red : #f7768e; + green : #9ece6a; + blue : #7aa2f7; + magenta : #9a7ecc; + cyan : #4abaaf; + + urgent: {color9}; + + background-color: @bg; + + text-color : @fg; + + margin : 0; + padding : 0; + spacing : 0; +}} + +element-icon, element-text, scrollbar {{ + cursor: pointer; +}} + +window {{ + location : northwest; + width : 280px; + x-offset : 0px; + y-offset : 38px; + + background-color: @bg; +}} + +inputbar {{ + spacing : 8px; + padding : 4px 8px; + children : [ icon-search, entry ]; + + background-color: @bg; +}} + +icon-search, entry, element-icon, element-text {{ + vertical-align: 0.5; + background-color: @bg; + text-color: @fg; +}} + +icon-search {{ + display: none; + expand : false; + filename : "search-symbolic"; + size : 0px; +}} + +textbox {{ + padding : 4px 8px; +}} + +listview {{ + padding : 4px 0px; + lines : 5; + columns : 1; + scrollbar : false; + fixed-height : false; + dynamic : true; +}} + +element {{ + padding : 4px 8px; + spacing : 8px; + + background-color: @bg; + text-color: @fg; +}} + +element normal urgent {{ + text-color: @urgent; + background-color: @fg; +}} + +element normal active {{ +}} + +element alternate active {{ + text-color: inherit; + background-color: inherit; +}} + +element selected {{ + background-color: @fg; + text-color: @bg; +}} + +element selected urgent {{ + background-color: @urgent; +}} + +element-icon {{ + display: none; + size: 0.8em; +}} + +element-text {{ + text-color: inherit; + background-color: inherit; +}} + +scrollbar {{ + handle-width : 4px; + handle-color : @scroll; + padding : 0 4px; +}} diff --git a/conky.conf b/conky.conf deleted file mode 100644 index 4bd061d..0000000 --- a/conky.conf +++ /dev/null @@ -1,88 +0,0 @@ --- Conky, a system monitor https://github.com/brndnmtthws/conky --- --- This configuration file is Lua code. You can write code in here, and it will --- execute when Conky loads. You can use it to generate your own advanced --- configurations. --- --- Try this (remove the `--`): --- --- print("Loading Conky config") --- --- For more on Lua, see: --- https://www.lua.org/pil/contents.html --- --- Conky Lua API: https://conky.cc/lua - --- Configuration settings: https://conky.cc/config_settings -conky.config = { - alignment = 'bottom_left', - background = true, - border_width = 1, - cpu_avg_samples = 2, - default_color = '#9a8f95', - default_outline_color = '#9a8f95', - default_shade_color = 'white', - double_buffer = true, - draw_borders = false, - draw_graph_borders = true, - draw_outline = false, - draw_shades = false, - extra_newline = false, - font = 'Source Code Pro:size=12', - gap_x = 65, - gap_y = 65, - minimum_height = 5, - minimum_width = 5, - net_avg_samples = 2, - no_buffers = true, - out_to_console = false, - out_to_ncurses = false, - out_to_stderr = false, - out_to_wayland = false, - out_to_x = true, - own_window = true, - own_window_class = 'Conky', - own_window_type = 'normal', - own_window_transparent = no, - own_window_hints = 'undecorated,below,skip_taskbar,skip_pager', - show_graph_range = false, - show_graph_scale = false, - stippled_borders = 0, - update_interval = 1.0, - uppercase = false, - use_spacer = 'none', - use_xft = true, - own_window_colour = '#161314' -} - --- Variables: https://conky.cc/variables -conky.text = [[ -#${color #c4c4c4}$color ${scroll 40 sup /wg/} -${color #c4c4c4}$color ${scroll 40 :) computer !!! computers are awesome! aw yeah beep beep boop} -$hr -${color #c4c4c4}Uptime:$color $uptime -# ${color #c4c4c4}Frequency (in MHz):$color $freq -# ${color #c4c4c4}Frequency (in GHz):$color $freq_g -${color #c4c4c4}CPU Usage:$color $cpu% ${cpubar 4} -${color #c4c4c4}RAM Usage:$color $memperc% ${membar 4} -# ${color #c4c4c4}RAM Usage:$color $mem/$memmax - $memperc% ${membar 4} -# ${color #c4c4c4}Swap Usage:$color $swap/$swapmax - $swapperc% ${swapbar 4} -${color #c4c4c4}Processes:$color $processes ${color #c4c4c4}Running:$color $running_processes -$hr -${color #c4c4c4}Hard Drive: - $color${fs_used /}/${fs_size /} ${fs_bar 6 /} -${color #c4c4c4}Networking: - Up:$color ${upspeed wlp2s0} ${color #c4c4c4} - Down:$color ${downspeed wlp2s0} -${color #c4c4c4}Battery: - ${battery BAT0} -$hr -${color #c4c4c4}Name PID CPU% MEM% -${color #c4c4c4} ${top name 1} ${top pid 1} ${top cpu 1} ${top mem 1} -${color #c4c4c4} ${top name 2} ${top pid 2} ${top cpu 2} ${top mem 2} -${color #c4c4c4} ${top name 3} ${top pid 3} ${top cpu 3} ${top mem 3} -${color #c4c4c4} ${top name 4} ${top pid 4} ${top cpu 4} ${top mem 4} -${color #c4c4c4} ${top name 5} ${top pid 5} ${top cpu 5} ${top mem 5} -${color #c4c4c4} ${top name 6} ${top pid 6} ${top cpu 6} ${top mem 6} -${color #c4c4c4} ${top name 7} ${top pid 7} ${top cpu 7} ${top mem 7} -${color #c4c4c4} ${top name 8} ${top pid 8} ${top cpu 8} ${top mem 8} -]] diff --git a/desktop/init.lua b/desktop/init.lua new file mode 100644 index 0000000..d690307 --- /dev/null +++ b/desktop/init.lua @@ -0,0 +1,105 @@ +-- plugins -- +vim.pack.add({ + 'https://github.com/AlphaTechnolog/pywal.nvim', + 'https://github.com/stevearc/oil.nvim', + 'https://github.com/nvim-mini/mini.move', + 'https://github.com/nvim-mini/mini.icons', + 'https://github.com/nvim-mini/mini.surround', + 'https://github.com/ibhagwan/fzf-lua', + 'https://github.com/nvim-treesitter/nvim-treesitter', + { src = 'https://github.com/Saghen/blink.cmp', version = 'v1.10.2' }, +}) + +require("pywal").setup() +require("oil").setup() +require("mini.move").setup() +require("mini.icons").setup() +--[[ require("mini.surround").setup({ + -- Module mappings. Use `''` (empty string) to disable one. + mappings = { + add = '', -- Add surrounding in Normal and Visual modes + delete = '', -- Delete surrounding + find = '', -- Find surrounding (to the right) + find_left = '', -- Find surrounding (to the left) + highlight = '', -- Highlight surrounding + replace = '', -- Replace surrounding + + suffix_last = 'l', -- Suffix to search with "prev" method + suffix_next = 'n', -- Suffix to search with "next" method + }, +}) +--]] +require("fzf-lua").setup() +require("blink.cmp").setup() +require("nvim-treesitter").setup() + +vim.loader.enable() -- speed up launch! + + +-- treesitter - dynamically determine language +vim.api.nvim_create_autocmd("FileType", { + group = vim.api.nvim_create_augroup("tree-sitter-enable", { clear = true }), + callback = function(args) + local lang = vim.treesitter.language.get_lang(args.match) + if not lang then + return + end + if vim.treesitter.query.get(lang, "highlights") then + vim.treesitter.start(args.buf) + end + if vim.treesitter.query.get(lang, "indents") then + vim.opt_local.indentexpr = 'v:lua.require("nvim-treesitter").indentexpr()' + end + + -- from treesitter docs for folding + vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' + vim.opt.foldmethod = 'expr' + end, +}) + +-- blink completion stuff + + + +-- normal mode +vim.api.nvim_set_keymap('i','jk','',{noremap=true,silent=true}) +vim.api.nvim_set_keymap('i','kj','',{noremap=true,silent=true}) + +-- ui +vim.opt.foldlevelstart = 99 +vim.o.scrolloff = 10 +vim.o.number = true +vim.o.relativenumber = true +vim.o.showmode = false +vim.o.signcolumn = "yes" +vim.o.pumheight = 15 +vim.o.shortmess = "CFOSWaco" + +-- completion +vim.o.autocomplete = true +vim.o.completeopt = "menuone,noinsert,popup,fuzzy,nearest" +vim.o.pumheight = 15 +vim.o.pummaxwidth = 40 + +-- indents +vim.o.tabstop = 2 +vim.o.shiftwidth = 2 + +-- search +vim.o.imsearch = 0 +vim.o.hlsearch = true +vim.o.incsearch = true +vim.o.ignorecase = true +vim.o.smartcase = true + +local map = vim.keymap.set + +-- KEYMAPS - for plugins +map("n", "-", "Oil", { desc = "Open parent directory" }) + + +-- KEYMAPS - movement +map("n", "", "zz") +map("n", "", "zz") +map("n", "", "zz") +map("n", "", "zz") diff --git a/desktop/swayconfig b/desktop/swayconfig new file mode 100644 index 0000000..525848b --- /dev/null +++ b/desktop/swayconfig @@ -0,0 +1,255 @@ +# me sway config file :) + +# setup colors + pape from wal +include "/home/slime/.cache/wal/colors-sway" + +# setup display +output HDMI-A-1 mode 1920x1080@180hz + +# set wallpaper +output HDMI-A-1 bg $wallpaper stretch + +# start statusbar +exec --no-startup-id waybar -c /home/slime/.config/waybar/config -s /home/slime/.config/waybar/style.css + +# run screenshare fix scrip +exec XDG_CURRENT_DESKTOP=sway +exec --no-startup-id /home/slime/Scripts/sway_screenshare_fix + +# run systray programs +# exec --no-startup-id nm-applet + + +# set supa key +set $mod Mod4 + +# Font for window titles. Will also be used by the bar unless a different font +# is used in the bar {} block below. +font pango:Source Code Pro 16 + +# Use pactl to adjust volume in PulseAudio. +#set $refresh_i3status killall -SIGUSR1 i3status +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5% && pkill -SIGRTMIN+10 i3blocks +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5% && pkill -SIGRTMIN+10 i3blocks +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && pkill -SIGRTMIN+10 i3blocks +bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && pkill -SIGRTMIN+10 i3blocks + +# Use Mouse+$mod to drag floating windows to their wanted position +floating_modifier $mod + +# start a terminal +bindsym $mod+Return exec foot -f "IBM Plex Mono:size=12" + +# kill focused window +bindsym $mod+Shift+q kill + +# start Rofi +bindsym $mod+Space exec rofi -show run -theme '/home/slime/.config/rofi/theme.rasi' + +# change focus w/ vim keys +bindsym $mod+h focus left +bindsym $mod+j focus down +bindsym $mod+k focus up +bindsym $mod+l focus right +# or, with the cursor keys: +bindsym $mod+Left focus left +bindsym $mod+Down focus down +bindsym $mod+Up focus up +bindsym $mod+Right focus right + +# move focused window pos +bindsym $mod+Shift+h move left +bindsym $mod+Shift+j move down +bindsym $mod+Shift+k move up +bindsym $mod+Shift+l move right +# or, with the cursor keys: +bindsym $mod+Shift+Left move left +bindsym $mod+Shift+Down move down +bindsym $mod+Shift+Up move up +bindsym $mod+Shift+Right move right + +# split in horizontal orientation +# bindsym $mod+Shift+h split h + +# split in vertical orientation +# bindsym $mod+v split v + +# enter fullscreen mode for the focused container +bindsym $mod+f fullscreen toggle + +# change container layout (stacked, tabbed, toggle split) +# bindsym $mod+s layout stacking +bindsym $mod+w layout tabbed +bindsym $mod+e layout toggle split + +# toggle tiling / floating +bindsym $mod+Shift+space floating toggle + +# change focus between tiling / floating windows +bindsym $mod+t focus mode_toggle + +# focus the parent container +bindsym $mod+a focus parent + +# focus the child container +#bindsym $mod+d focus child + +# Define names for default workspaces for which we configure key bindings later on. +# We use variables to avoid repeating the names in multiple places. +set $ws1 "1:  " +set $ws2 "2:  " +set $ws3 "3:  " +set $ws4 "4:  " +set $ws5 "5" +set $ws6 "6" +set $ws7 "7" +set $ws8 "8" +set $ws9 "9" +set $ws10 "0:  " + + +# workspace $ws10 output "Screen 0" + +# switch to workspace +bindsym $mod+1 workspace number $ws1 +bindsym $mod+2 workspace number $ws2 +bindsym $mod+3 workspace number $ws3 +bindsym $mod+4 workspace number $ws4 +bindsym $mod+5 workspace number $ws5 +bindsym $mod+6 workspace number $ws6 +bindsym $mod+7 workspace number $ws7 +bindsym $mod+8 workspace number $ws8 +bindsym $mod+9 workspace number $ws9 +bindsym $mod+0 workspace number $ws10 + +# move focused container to workspace +bindsym $mod+Shift+1 move container to workspace number $ws1 +bindsym $mod+Shift+2 move container to workspace number $ws2 +bindsym $mod+Shift+3 move container to workspace number $ws3 +bindsym $mod+Shift+4 move container to workspace number $ws4 +bindsym $mod+Shift+5 move container to workspace number $ws5 +bindsym $mod+Shift+6 move container to workspace number $ws6 +bindsym $mod+Shift+7 move container to workspace number $ws7 +bindsym $mod+Shift+8 move container to workspace number $ws8 +bindsym $mod+Shift+9 move container to workspace number $ws9 +bindsym $mod+Shift+0 move container to workspace number $ws10 + +# reload the configuration file +bindsym $mod+Shift+c reload +# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) +bindsym $mod+Shift+r restart + +# TODO: bindsym $mod+Shift+e exec --no-startup-id "rofi -show powermenu -modi powermenu:~/Scripts/rofi-power-menu -theme ~/.config/rofi/theme.rasi" + +# resize window (you can also use the mouse for that) +mode "resize" { + # These bindings trigger as soon as you enter the resize mode + + # Pressing left will shrink the window’s width. + # Pressing right will grow the window’s width. + # Pressing up will shrink the window’s height. + # Pressing down will grow the window’s height. + bindsym h resize shrink width 10 px or 10 ppt + bindsym j resize grow height 10 px or 10 ppt + bindsym k resize shrink height 10 px or 10 ppt + bindsym l resize grow width 10 px or 10 ppt + + # same bindings, but for the arrow keys + bindsym Left resize shrink width 10 px or 10 ppt + bindsym Down resize grow height 10 px or 10 ppt + bindsym Up resize shrink height 10 px or 10 ppt + bindsym Right resize grow width 10 px or 10 ppt + + # back to normal: Enter or Escape or $mod+r + bindsym Return mode "default" + bindsym Escape mode "default" + bindsym $mod+r mode "default" +} + +bindsym $mod+r mode "resize" + + +###################### +# START CUSTOM STUFF # +###################### + +# Screenshot taker bind +bindsym Print exec --no-startup-id flameshot gui + +# Color variables for default sway-bar (sourced from wal in first lines) + +# class border backgr. text indicator child_border +# client.focused $background $background $foreground $background $background +# client.focused_inactive $background $background $foreground $background $background +# client.unfocused $background $background $foreground $background $background +# client.urgent $background $background $foreground $background $background +# client.placeholder $background $background $foreground $background $background +# +# client.background $background +# +# bar { +# position top +# status_command i3blocks +# strip_workspace_numbers yes +# status_padding 5 +# status_edge_padding 15 +# tray_output * +# tray_padding 2 +# separator_symbol "~" +# +# colors { +# background $background +# separator $foreground +# # border bg txt +# focused_workspace $foreground $background $foreground +# inactive_workspace $background $background $foreground +# urgent_workspace #E53935 $background $foreground +# } +# } + +# Workspace assignment +assign [class="LibreWolf"] $ws1 +assign [class="Discord"] $ws3 +assign [class="Conky"] $ws10 +assign [class="steam"] $ws4 + +for_window [class="Conky"] floating enable + +# Borders +default_border pixel 0 +default_floating_border pixel 2 + +# Gap +gaps inner 30 +gaps outer 30 + +bindsym $mod+s gaps inner current plus 5 +bindsym $mod+Shift+s gaps inner current minus 5 +bindsym $mod+z gaps outer current plus 5 +bindsym $mod+Shift+z gaps outer current minus 5 + +# Media player controls +bindsym XF86AudioPlay exec --no-startup-id playerctl play +bindsym XF86AudioPause exec --no-startup-id playerctl pause +bindsym XF86AudioNext exec --no-startup-id playerctl next +bindsym XF86AudioPrev exec --no-startup-id playerctl previous + +# Vim Keybindings ;P +input "type:keyboard" { + xkb_layout us + xkb_options caps:escape +} + + # +# Scratchpad: +# + # Sway has a "scratchpad", which is a bag of holding for windows. + # You can send windows there and get them back later. + + # Move the currently focused window to the scratchpad + bindsym $mod+Shift+minus move scratchpad + + # Show the next scratchpad window or hide the focused scratchpad window. + # If there are multiple scratchpad windows, this command cycles through them. + bindsym $mod+minus scratchpad show +# diff --git a/desktop/waybar-wal-template.css b/desktop/waybar-wal-template.css new file mode 100644 index 0000000..5968316 --- /dev/null +++ b/desktop/waybar-wal-template.css @@ -0,0 +1,329 @@ +* { + /* `otf-font-awesome` is required to be installed for icons */ + font-family: smoothansi; + font-size: 14px; +} + +window#waybar { + background-color: {background}; + border-bottom: 3px solid {color1}; + color: {foreground}; + transition-property: background-color; + transition-duration: .5s; +} + +window#waybar.hidden { + opacity: 0.2; +} + +/* +window#waybar.empty { + background-color: transparent; +} +window#waybar.solo { + background-color: #FFFFFF; +} + +window#waybar.termite { + background-color: #3F3F3F; +} + +window#waybar.chromium { + background-color: #000000; + border: none; +} +*/ + +button { + /* Use box-shadow instead of border so the text isn't offset */ + box-shadow: inset 0 -3px {color1}; + /* Avoid rounded borders under each button name */ + border: none; + border-radius: 0; +} + +/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ +button:hover { + background: inherit; + box-shadow: inset 0 -3px {foreground}; +} + +/* you can set a style on hover for any module like this */ +#pulseaudio:hover { + background-color: {color2}; +} + +#workspaces button { + padding: 0 5px; + background-color: transparent; + color: {foreground}; +} + +#workspaces button:hover { + background: rgba(0, 0, 0, 0.2); +} + +#workspaces button.focused, #workspaces button.active { + background-color: {color1}; + box-shadow: inset 0 -3px {color1}; +} + +#workspaces button.urgent { + background-color: {color13}; +} + +#mode { + background-color: {background}; + box-shadow: inset 0 -3px {color1}; +} + +#clock, +#battery, +#cpu, +#memory, +#disk, +#temperature, +#backlight, +#network, +#pulseaudio, +#wireplumber, +#custom-media, +#tray, +#mode, +#idle_inhibitor, +#scratchpad, +#power-profiles-daemon, +#mpd { + padding: 0 10px; + color: {foreground}; + + box-shadow: inset 0 -3px {color1}; +} + +#window, +#workspaces { + margin: 0 4px; +} + +/* If workspaces is the leftmost module, omit left margin */ +.modules-left > widget:first-child > #workspaces { + margin-left: 0; +} + +/* If workspaces is the rightmost module, omit right margin */ +.modules-right > widget:last-child > #workspaces { + margin-right: 0; +} + +#clock { + background-color: {background}; +} + +#battery { + background-color: {background}; + color: {foreground}; +} + +#battery.charging, #battery.plugged { + color: {foreground}; + background-color: {background}; +} + +@keyframes blink { + to { + background-color: {foreground}; + color: {background}; + } +} + +/* Using steps() instead of linear as a timing function to limit cpu usage */ +#battery.critical:not(.charging) { + background-color: #f53c3c; + color: #ffffff; + animation-name: blink; + animation-duration: 0.5s; + animation-timing-function: steps(12); + animation-iteration-count: infinite; + animation-direction: alternate; +} + +#power-profiles-daemon { + padding-right: 15px; +} + +#power-profiles-daemon.performance { + background-color: #f53c3c; + color: #ffffff; +} + +#power-profiles-daemon.balanced { + background-color: #2980b9; + color: #ffffff; +} + +#power-profiles-daemon.power-saver { + background-color: #2ecc71; + color: #000000; +} + +label:focus { + background-color: {foreground}; +} + +#cpu { + background-color: {background}; + color: {foreground}; +} + +#memory { + background-color: {background}; +} + +#disk { + background-color: {background}; +} + +#backlight { + background-color: {background}; +} + +#network { + background-color: {background}; +} + +#network.disconnected { + background-color: #f53c3c; +} + +#pulseaudio { + background-color: {background}; + color: {foreground}; +} + +#pulseaudio.muted { + background-color: {color11}; + color: {foreground}; +} + +#wireplumber { + background-color: {background}; + color: {foreground}; +} + +#wireplumber.muted { + background-color: {color11}; +} + +#custom-media { + background-color: #66cc99; + color: #2a5c45; + min-width: 100px; +} + +#custom-media.custom-spotify { + background-color: #66cc99; +} + +#custom-media.custom-vlc { + background-color: #ffa000; +} + +#temperature { + background-color: #f0932b; +} + +#temperature.critical { + background-color: #eb4d4b; +} + +#tray { + background-color: {background}; +} + +#tray > .passive { + -gtk-icon-effect: dim; +} + +#tray > .needs-attention { + -gtk-icon-effect: highlight; + background-color: {color11}; +} + +#idle_inhibitor { + background-color: #2d3436; +} + +#idle_inhibitor.activated { + background-color: #ecf0f1; + color: #2d3436; +} + +#mpd { + background-color: #66cc99; + color: #2a5c45; +} + +#mpd.disconnected { + background-color: #f53c3c; +} + +#mpd.stopped { + background-color: #90b1b1; +} + +#mpd.paused { + background-color: #51a37a; +} + +#language { + background: #00b093; + color: #740864; + padding: 0 5px; + margin: 0 5px; + min-width: 16px; +} + +#keyboard-state { + background: #97e1ad; + color: #000000; + padding: 0 0px; + margin: 0 5px; + min-width: 16px; +} + +#keyboard-state > label { + padding: 0 5px; +} + +#keyboard-state > label.locked { + background: rgba(0, 0, 0, 0.2); +} + +#scratchpad { + background: rgba(0, 0, 0, 0.2); +} + +#scratchpad.empty { + background-color: transparent; +} + +#privacy { + padding: 0; +} + +#privacy-item { + padding: 0 5px; + color: white; +} + +#privacy-item.screenshare { + background-color: #cf5700; +} + +#privacy-item.audio-in { + background-color: #1ca000; +} + +#privacy-item.audio-out { + background-color: #0069d4; +} diff --git a/desktop/waybar_config b/desktop/waybar_config new file mode 100644 index 0000000..5e2f130 --- /dev/null +++ b/desktop/waybar_config @@ -0,0 +1,220 @@ +// -*- mode: jsonc -*- +{ + // "layer": "top", // Waybar at top layer + // "position": "bottom", // Waybar position (top|bottom|left|right) + "height": 30, // Waybar height (to be removed for auto height) + "width": 1280, // Waybar width + "spacing": 4, // Gaps between modules (4px) + // Choose the order of the modules + "modules-left": [ + "sway/workspaces", + "sway/mode", + "sway/scratchpad" + // "custom/media" + ], + "modules-center": [ + "sway/window" + ], + "modules-right": [ + // "mpd", + // "idle_inhibitor", + "pulseaudio", + // "network", + // "power-profiles-daemon", + "cpu", + "memory", + // "temperature", + // "backlight", + // "keyboard-state", + // "sway/language", + // "battery", + // "battery#bat2", + "clock", + "tray"] + , + // Modules configuration + // "sway/workspaces": { + // "disable-scroll": true, + // "all-outputs": true, + // "warp-on-scroll": false, + // "format": "{name}: {icon}", + // "format-icons": { + // "1": "", + // "2": "", + // "3": "", + // "4": "", + // "5": "", + // "urgent": "", + // "focused": "", + // "default": "" + // } + // }, + "keyboard-state": { + "numlock": true, + "capslock": true, + "format": "{name} {icon}", + "format-icons": { + "locked": "", + "unlocked": "" + } + }, + "sway/mode": { + "format": "{}" + }, + "sway/scratchpad": { + "format": "{icon} {count}", + "show-empty": false, + "format-icons": ["", ""], + "tooltip": true, + "tooltip-format": "{app}: {title}" + }, + "mpd": { + "format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {album} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S}) ⸨{songPosition}|{queueLength}⸩ {volume}% ", + "format-disconnected": "Disconnected ", + "format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ", + "unknown-tag": "N/A", + "interval": 5, + "consume-icons": { + "on": " " + }, + "random-icons": { + "off": " ", + "on": " " + }, + "repeat-icons": { + "on": " " + }, + "single-icons": { + "on": "1 " + }, + "state-icons": { + "paused": "", + "playing": "" + }, + "tooltip-format": "MPD (connected)", + "tooltip-format-disconnected": "MPD (disconnected)" + }, + "idle_inhibitor": { + "format": "{icon}", + "format-icons": { + "activated": "", + "deactivated": "" + } + }, + "tray": { + // "icon-size": 21, + "spacing": 8, + // "icons": { + // "blueman": "bluetooth", + // "TelegramDesktop": "$HOME/.local/share/icons/hicolor/16x16/apps/telegram.png" + // } + }, + "clock": { + // "timezone": "America/New_York", + "format": "{:%a, %H:%M}", + "tooltip-format": "{:%Y %B}\n{calendar}", + "format-alt": "{:%Y-%m-%d}" + }, + "cpu": { + "format": "cpu: {usage}%", + "tooltip": false + }, + "memory": { + "format": "ram: {}%" + }, + "temperature": { + // "thermal-zone": 2, + // "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", + "critical-threshold": 80, + // "format-critical": "{temperatureC}°C {icon}", + "format": "{temperatureC}°C {icon}", + "format-icons": ["", "", ""] + }, + "backlight": { + // "device": "acpi_video1", + "format": "{percent}% {icon}", + "format-icons": ["", "", "", "", "", "", "", "", ""] + }, + "battery": { + "states": { + // "good": 95, + "warning": 30, + "critical": 15 + }, + "format": "{capacity}% {icon}", + "format-full": "{capacity}% {icon}", + "format-charging": "{capacity}% ", + "format-plugged": "{capacity}% ", + "format-alt": "{time} {icon}", + // "format-good": "", // An empty format will hide the module + // "format-full": "", + "format-icons": ["", "", "", "", ""] + }, + "battery#bat2": { + "bat": "BAT2" + }, + "power-profiles-daemon": { + "format": "{icon}", + "tooltip-format": "Power profile: {profile}\nDriver: {driver}", + "tooltip": true, + "format-icons": { + "default": "", + "performance": "", + "balanced": "", + "power-saver": "" + } + }, + "network": { + // "interface": "wlp2*", // (Optional) To force the use of this interface + "format-wifi": " {signalStrength}%", + "format-ethernet": "{ipaddr}/{cidr} ", + "tooltip-format": "{ifname} via {gwaddr} ", + "format-linked": "{ifname} (No IP) ", + "format-disconnected": "Disconnected ⚠", + "format-alt": "{ifname}: {ipaddr}/{cidr}" + }, + "pulseaudio": { + // "scroll-step": 1, // %, can be a float + // "format": "{volume}% {icon} {format_source}", + "format": "vol: {volume}%", + "format-bluetooth": "{volume}% {icon} {format_source}", + "format-bluetooth-muted": " {icon} {format_source}", + "format-muted": " {format_source}", + "format-source": "{volume}% ", + "format-source-muted": "", + "format-icons": { + "headphone": "", + "hands-free": "", + "headset": "", + "phone": "", + "portable": "", + "car": "", + "default": ["", "", ""] + }, + "on-click": "pavucontrol" + }, + "custom/media": { + "format": "{icon} {text}", + "return-type": "json", + "max-length": 40, + "format-icons": { + "spotify": "", + "default": "🎜" + }, + "escape": true, + "exec": "$HOME/.config/waybar/mediaplayer.py 2> /dev/null" // Script in resources folder + // "exec": "$HOME/.config/waybar/mediaplayer.py --player spotify 2> /dev/null" // Filter player based on name + }, + "custom/power": { + "format" : "⏻ ", + "tooltip": false, + "menu": "on-click", + "menu-file": "$HOME/.config/waybar/power_menu.xml", // Menu file in resources folder + "menu-actions": { + "shutdown": "shutdown", + "reboot": "reboot", + "suspend": "systemctl suspend", + "hibernate": "systemctl hibernate" + } + } +} diff --git a/i3blocks.conf b/i3blocks.conf deleted file mode 100644 index 25986a6..0000000 --- a/i3blocks.conf +++ /dev/null @@ -1,47 +0,0 @@ -# i3blocks configuration file -# -# The i3blocks man page describes the usage of the binary, -# and its website describes the configuration: -# -# https://vivien.github.io/i3blocks - - -# Global properties -separator=true -separator_block_width=30 - -[weather] -command=curl -Ss 'https://wttr.in?0&T&Q' | cut -c 16- | head -2 | xargs echo -interval=1800 -# color=#c0caf5 - -[brightness] -command=echo " $(brightnessctl get | awk '{print $0 / 24000 * 100}')" -signal=11 -interval=once -# color=#c0caf5 - -[volume] -command=i3blocks_volume -# echo "vol: $(pactl get-sink-volume @DEFAULT_SINK@ | awk '{printf "%s", substr($5, 1, length($5) - 1)}')" -# command=echo "vol: $(wpctl get-volume 50 | awk '{print $2*100}')" -signal=10 -interval=once -# color=#c0caf5 - -[date] -command=date '+%a, %b %d' -interval=once -# color=#c0caf5 -# color=#c0caf5 - -[time] -command=date '+%H:%M:%S' -interval=1 -# color=#c0caf5 - -# [battery] -# command=echo "bat: $(sudo cat /sys/class/power_supply/BAT0/capacity)%" -# interval=30 -# color=#c0caf5 - diff --git a/i3config b/i3config deleted file mode 100644 index 39e1e53..0000000 --- a/i3config +++ /dev/null @@ -1,266 +0,0 @@ -exec_always --no-startup-id xrandr --setprovideroutputsource modesetting NVIDIA-0 -exec_always --no-startup-id xrandr --auto - -# me i3 config file :) - -set $mod Mod4 - -# Font for window titles. Will also be used by the bar unless a different font -# is used in the bar {} block below. -font pango:Source Code Pro 16 - -# Use pactl to adjust volume in PulseAudio. -#set $refresh_i3status killall -SIGUSR1 i3status -bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5% && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5% && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && pkill -SIGRTMIN+10 i3blocks - -# Use Mouse+$mod to drag floating windows to their wanted position -floating_modifier $mod - -# move tiling windows via drag & drop by left-clicking into the title bar, or left-clicking anywhere into the -# window while holding the floating modifier. -tiling_drag modifier titlebar - -# start a terminal -bindsym $mod+Return exec sakura -f "Source Code Pro 10" - -# kill focused window -bindsym $mod+Shift+q kill - -# start Rofi -bindsym $mod+d exec rofi -show run -theme 'theme.rasi' - -# change focus -bindsym $mod+h focus left -bindsym $mod+j focus down -bindsym $mod+k focus up -bindsym $mod+l focus right - -# alternatively, you can use the cursor keys: -bindsym $mod+Left focus left -bindsym $mod+Down focus down -bindsym $mod+Up focus up -bindsym $mod+Right focus right - -# move focused window -bindsym $mod+Shift+h move left -bindsym $mod+Shift+j move down -bindsym $mod+Shift+k move up -bindsym $mod+Shift+l move right - -# alternatively, you can use the cursor keys: -bindsym $mod+Shift+Left move left -bindsym $mod+Shift+Down move down -bindsym $mod+Shift+Up move up -bindsym $mod+Shift+Right move right - -# split in horizontal orientation -# bindsym $mod+Shift+h split h - -# split in vertical orientation -# bindsym $mod+v split v - -# enter fullscreen mode for the focused container -bindsym $mod+f fullscreen toggle - -# change container layout (stacked, tabbed, toggle split) -# bindsym $mod+s layout stacking -bindsym $mod+w layout tabbed -bindsym $mod+e layout toggle split - -# toggle tiling / floating -bindsym $mod+Shift+space floating toggle - -# change focus between tiling / floating windows -bindsym $mod+space focus mode_toggle - -# focus the parent container -bindsym $mod+a focus parent - -# focus the child container -#bindsym $mod+d focus child - -# Define names for default workspaces for which we configure key bindings later on. -# We use variables to avoid repeating the names in multiple places. -set $ws1 "1:  " -set $ws2 "2:  " -set $ws3 "3:  " -set $ws4 "4:  " -set $ws5 "5" -set $ws6 "6" -set $ws7 "7" -set $ws8 "8" -set $ws9 "9" -set $ws10 "0:  " - - -# workspace $ws10 output "Screen 0" - -# switch to workspace -bindsym $mod+1 workspace number $ws1 -bindsym $mod+2 workspace number $ws2 -bindsym $mod+3 workspace number $ws3 -bindsym $mod+4 workspace number $ws4 -bindsym $mod+5 workspace number $ws5 -bindsym $mod+6 workspace number $ws6 -bindsym $mod+7 workspace number $ws7 -bindsym $mod+8 workspace number $ws8 -bindsym $mod+9 workspace number $ws9 -bindsym $mod+0 workspace number $ws10 - -# move focused container to workspace -bindsym $mod+Shift+1 move container to workspace number $ws1 -bindsym $mod+Shift+2 move container to workspace number $ws2 -bindsym $mod+Shift+3 move container to workspace number $ws3 -bindsym $mod+Shift+4 move container to workspace number $ws4 -bindsym $mod+Shift+5 move container to workspace number $ws5 -bindsym $mod+Shift+6 move container to workspace number $ws6 -bindsym $mod+Shift+7 move container to workspace number $ws7 -bindsym $mod+Shift+8 move container to workspace number $ws8 -bindsym $mod+Shift+9 move container to workspace number $ws9 -bindsym $mod+Shift+0 move container to workspace number $ws10 - -# reload the configuration file -bindsym $mod+Shift+c reload -# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) -bindsym $mod+Shift+r restart -# exit i3 (logs you out of your X session) -# bindsym $mod+Shift+e exec "i3-nagbar -f 'Source Code Pro 64px' -t error -m 'bye bye?' -B 'bye bye' 'i3-msg exit'" -bindsym $mod+Shift+e exec --no-startup-id "rofi -show powermenu -modi powermenu:~/Scripts/rofi-power-menu -theme ~/.config/rofi/theme.rasi" - -# resize window (you can also use the mouse for that) -mode "resize" { - # These bindings trigger as soon as you enter the resize mode - - # Pressing left will shrink the window’s width. - # Pressing right will grow the window’s width. - # Pressing up will shrink the window’s height. - # Pressing down will grow the window’s height. - bindsym h resize shrink width 10 px or 10 ppt - bindsym j resize grow height 10 px or 10 ppt - bindsym k resize shrink height 10 px or 10 ppt - bindsym l resize grow width 10 px or 10 ppt - - # same bindings, but for the arrow keys - bindsym Left resize shrink width 10 px or 10 ppt - bindsym Down resize grow height 10 px or 10 ppt - bindsym Up resize shrink height 10 px or 10 ppt - bindsym Right resize grow width 10 px or 10 ppt - - # back to normal: Enter or Escape or $mod+r - bindsym Return mode "default" - bindsym Escape mode "default" - bindsym $mod+r mode "default" -} - -bindsym $mod+r mode "resize" - - -###################### -# START CUSTOM STUFF # -###################### - -# Screenshot -bindsym $mod+Shift+x exec --no-startup-id scrot -s - -# Color variables -# Set colors from Xresources -# Change 'color7' and 'color2' to whatever colors you want i3 to use -# from the generated scheme. -# NOTE: The '#f0f0f0' in the lines below is the color i3 will use if -# it fails to get colors from Xresources. -set_from_resource $fg i3wm.foreground #f0f0f0 -set_from_resource $bg i3wm.background #f0f0f0 - -# class border backgr. text indicator child_border -client.focused $bg $bg $fg $bg $bg -client.focused_inactive $bg $bg $fg $bg $bg -client.unfocused $bg $bg $fg $bg $bg -client.urgent $bg $bg $fg $bg $bg -client.placeholder $bg $bg $fg $bg $bg - -client.background $bg - -# Pape -exec_always --no-startup-id wal -Rn -o /home/slime/.fehbg - -# i3status -bar { - position top - status_command i3blocks - strip_workspace_numbers yes - padding 5px 15px - tray_output none - separator_symbol "~" - - colors { - background $bg - separator $fg - # border bg txt - focused_workspace $fg $bg $fg - inactive_workspace $bg $bg $fg - urgent_workspace #E53935 $bg $fg - } -} - -# PROTIP: You can also dynamically set dmenu's colors this way: -# bindsym $mod+d exec dmenu_run -nb "$fg" -nf "$bg" -sb "$bg" -sf "$fg"# Compositor - -exec_always --no-startup-id picom --config /home/slime/.config/picom.conf - -# Autostart programs -# exec --no-startup-id i3-msg 'workspace number $ws10; exec --no-startup-id conky; workspace number $ws10' - -# monitor + graphics driver setup -exec --no-startup-id /home/slime/.screenlayout/first_shot.sh -exec --no-startup-id prime-offload - -exec --no-startup-id set_wallpaper snowy-steeple.jpg oymyakon_forests_hires.jpg - -# Opaqueness - bindsym $mod+p exec --no-startup-id picom-trans 100 - -# Workspace assignment -assign [class="LibreWolf"] $ws1 -assign [class="WebCord"] $ws3 -assign [class="Conky"] $ws10 -assign [class="steam"] $ws4 - -for_window [class="Conky"] floating enable - -# Borders -default_border pixel 0 -default_floating_border pixel 2 - -# Gap -gaps inner 30 -gaps outer 30 - -bindsym $mod+s gaps inner current plus 5 -bindsym $mod+Shift+s gaps inner current minus 5 -bindsym $mod+z gaps outer current plus 5 -bindsym $mod+Shift+z gaps outer current minus 5 - -# Window colors -# border background text indicator -client.focused $text-color $bg-color $text-color $bg-color -client.unfocused $inactive-win-bord $inactive-bg-color $inactive-text-color $bg-color -client.focused_inactive $inactive-bg-color $inactive-bg-color $inactive-text-color $bg-color -client.urgent $urgent-bg-color $urgent-bg-color $text-color $bg-color - -# Sreen brightness controls -bindsym XF86MonBrightnessUp exec --no-startup-id brightnessctl set +1% && pkill -SIGRTMIN+11 i3blocks -bindsym XF86MonBrightnessDown exec --no-startup-id brightnessctl set 1%- && pkill -SIGRTMIN+11 i3blocks - -# Media player controls -bindsym XF86AudioPlay exec --no-startup-id playerctl play -bindsym XF86AudioPause exec --no-startup-id playerctl pause -bindsym XF86AudioNext exec --no-startup-id playerctl next -bindsym XF86AudioPrev exec --no-startup-id playerctl previous - -# Vim Keys -exec_always --no-startup-id xmodmap -e "clear lock" #disable caps lock switch -exec_always --no-startup-id xmodmap -e "keysym Caps_Lock = Escape" #set caps_lock as escape - diff --git a/nvim/init.lua b/nvim/init.lua deleted file mode 100644 index d690307..0000000 --- a/nvim/init.lua +++ /dev/null @@ -1,105 +0,0 @@ --- plugins -- -vim.pack.add({ - 'https://github.com/AlphaTechnolog/pywal.nvim', - 'https://github.com/stevearc/oil.nvim', - 'https://github.com/nvim-mini/mini.move', - 'https://github.com/nvim-mini/mini.icons', - 'https://github.com/nvim-mini/mini.surround', - 'https://github.com/ibhagwan/fzf-lua', - 'https://github.com/nvim-treesitter/nvim-treesitter', - { src = 'https://github.com/Saghen/blink.cmp', version = 'v1.10.2' }, -}) - -require("pywal").setup() -require("oil").setup() -require("mini.move").setup() -require("mini.icons").setup() ---[[ require("mini.surround").setup({ - -- Module mappings. Use `''` (empty string) to disable one. - mappings = { - add = '', -- Add surrounding in Normal and Visual modes - delete = '', -- Delete surrounding - find = '', -- Find surrounding (to the right) - find_left = '', -- Find surrounding (to the left) - highlight = '', -- Highlight surrounding - replace = '', -- Replace surrounding - - suffix_last = 'l', -- Suffix to search with "prev" method - suffix_next = 'n', -- Suffix to search with "next" method - }, -}) ---]] -require("fzf-lua").setup() -require("blink.cmp").setup() -require("nvim-treesitter").setup() - -vim.loader.enable() -- speed up launch! - - --- treesitter - dynamically determine language -vim.api.nvim_create_autocmd("FileType", { - group = vim.api.nvim_create_augroup("tree-sitter-enable", { clear = true }), - callback = function(args) - local lang = vim.treesitter.language.get_lang(args.match) - if not lang then - return - end - if vim.treesitter.query.get(lang, "highlights") then - vim.treesitter.start(args.buf) - end - if vim.treesitter.query.get(lang, "indents") then - vim.opt_local.indentexpr = 'v:lua.require("nvim-treesitter").indentexpr()' - end - - -- from treesitter docs for folding - vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' - vim.opt.foldmethod = 'expr' - end, -}) - --- blink completion stuff - - - --- normal mode -vim.api.nvim_set_keymap('i','jk','',{noremap=true,silent=true}) -vim.api.nvim_set_keymap('i','kj','',{noremap=true,silent=true}) - --- ui -vim.opt.foldlevelstart = 99 -vim.o.scrolloff = 10 -vim.o.number = true -vim.o.relativenumber = true -vim.o.showmode = false -vim.o.signcolumn = "yes" -vim.o.pumheight = 15 -vim.o.shortmess = "CFOSWaco" - --- completion -vim.o.autocomplete = true -vim.o.completeopt = "menuone,noinsert,popup,fuzzy,nearest" -vim.o.pumheight = 15 -vim.o.pummaxwidth = 40 - --- indents -vim.o.tabstop = 2 -vim.o.shiftwidth = 2 - --- search -vim.o.imsearch = 0 -vim.o.hlsearch = true -vim.o.incsearch = true -vim.o.ignorecase = true -vim.o.smartcase = true - -local map = vim.keymap.set - --- KEYMAPS - for plugins -map("n", "-", "Oil", { desc = "Open parent directory" }) - - --- KEYMAPS - movement -map("n", "", "zz") -map("n", "", "zz") -map("n", "", "zz") -map("n", "", "zz") diff --git a/nvim/windows-init.lua b/nvim/windows-init.lua deleted file mode 100644 index 95b3b09..0000000 --- a/nvim/windows-init.lua +++ /dev/null @@ -1,105 +0,0 @@ --- WINDOWS SHELL COMPATIBILITY (needed for sf.nvim command runner) -if vim.fn.has("win32") == 1 then - vim.opt.shell = "cmd.exe" - vim.opt.shellcmdflag = "/s /c" - vim.opt.shellquote = "" - vim.opt.shellxquote = '"' -- Crucial for handling quotes and && properly in cmd -end - --- plugins -- -vim.pack.add({ - 'https://github.com/stevearc/oil.nvim', - 'https://github.com/nvim-mini/mini.move', - 'https://github.com/nvim-mini/mini.icons', - 'https://github.com/ibhagwan/fzf-lua', - 'https://github.com/xixiaofinland/sf.nvim', - 'https://github.com/nvim-treesitter/nvim-treesitter', - -- [completion] --------------------------------------------------------------- - { src = "https://github.com/Saghen/blink.cmp", version = vim.version.range('v1.10.2') }, - -}) - -require("oil").setup() -require("mini.move").setup() -require("mini.icons").setup() -require("fzf-lua").setup() -require("nvim-treesitter").setup() -require("blink.cmp").setup() -require("sf").setup({ - types_to_retrieve = { - "ApexClass", - "ApexTrigger", - "CustomPermission", - "CustomApplication", - "CustomMetadata", - "CustomSetting", - "CustomTab", - "CustomObject", - "Flow", - "FlowDefinition", - "Layout", - "LightningComponentBundle", - "PermissionSetGroup", - "PermissionSet", - "Profile", - "StaticResource", - "SharingRule" - }, -}) - -vim.loader.enable() -- speed up launch! - - --- treesitter - dynamically determine language -vim.api.nvim_create_autocmd("FileType", { - group = vim.api.nvim_create_augroup("tree-sitter-enable", { clear = true }), - callback = function(args) - local lang = vim.treesitter.language.get_lang(args.match) - if not lang then - return - end - if vim.treesitter.query.get(lang, "highlights") then - vim.treesitter.start(args.buf) - end - if vim.treesitter.query.get(lang, "indents") then - vim.opt_local.indentexpr = 'v:lua.require("nvim-treesitter").indentexpr()' - end - - -- from treesitter docs for folding - vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' - vim.opt.foldmethod = 'expr' - end, -}) - - --- normal mode -vim.api.nvim_set_keymap('i','jk','',{noremap=true,silent=true}) -vim.api.nvim_set_keymap('i','kj','',{noremap=true,silent=true}) - --- ui -vim.opt.foldlevelstart = 99 -vim.o.scrolloff = 10 -vim.o.number = true -vim.o.relativenumber = true -vim.o.showmode = false -vim.o.signcolumn = "yes" -vim.o.pumheight = 15 -vim.o.shortmess = "CFOSWaco" - --- search -vim.o.imsearch = 0 -vim.o.hlsearch = true -vim.o.incsearch = true -vim.o.ignorecase = true -vim.o.smartcase = true - -local map = vim.keymap.set - --- KEYMAPS - for plugins -map("n", "-", "Oil", { desc = "Open parent directory" }) - --- KEYMAPS - movement -map("n", "", "zz") -map("n", "", "zz") -map("n", "", "zz") -map("n", "", "zz") diff --git a/picom.conf b/picom.conf deleted file mode 100644 index 99bbf40..0000000 --- a/picom.conf +++ /dev/null @@ -1,36 +0,0 @@ -# EXAMPLE CONFIG AT : /etc/xdg/picom.conf -backend = "xrender" - - -# BLURRRRR -blur: -{ - method = "box"; - size = 10; - strength = 7; - background = false; - background-fixed = true; -}; - -shadow = false; -fading = true; -fade-delta = 5; - -# ROUNDER EDGES -# corner-radius = 15; -# rounded-corners-exclude = [ -# "class_g = 'i3bar'", -# "class_g = 'i3-nagbar'" -# ]; - -# OPACITYYY -inactive-opacity = 0.8; -active-opacity = 1; -opacity-rule = [ - "60:class_g = 'Sakura' && !focused", - "80:class_g = 'Conky' && focused", - "60:class_g = 'Conky' && !focused", - "90:class_g = 'Vesktop'", - "90:class_g = 'librewolf' && !focused", - "100:class_g = 'Rofi'" - ]; diff --git a/rofi-power-menu b/rofi-power-menu deleted file mode 100755 index 196d552..0000000 --- a/rofi-power-menu +++ /dev/null @@ -1,283 +0,0 @@ -#!/usr/bin/env bash - -# This script defines just a mode for rofi instead of being a self-contained -# executable that launches rofi by itself. This makes it more flexible than -# running rofi inside this script as now the user can call rofi as one pleases. -# For instance: -# -# rofi -show powermenu -modi powermenu:./rofi-power-menu -# -# See README.md for more information. - -set -e -set -u - -# All supported choices -all=(shutdown reboot suspend hibernate logout lockscreen) - -# By default, show all (i.e., just copy the array) -show=("${all[@]}") - -declare -A texts -texts[lockscreen]="lock screen" -texts[switchuser]="switch user" -texts[logout]="log out" -texts[suspend]="suspend" -texts[hibernate]="hibernate" -texts[reboot]="reboot" -texts[shutdown]="shut down" - -declare -A icons -icons[lockscreen]="\Uf033e" -icons[switchuser]="\Uf0019" -icons[logout]="\Uf0343" -icons[suspend]="\Uf04b2" -icons[hibernate]="\Uf02ca" -icons[reboot]="\Uf0709" -icons[shutdown]="\Uf0425" -icons[cancel]="\Uf0156" - -declare -A actions -actions[lockscreen]="loginctl lock-session ${XDG_SESSION_ID-}" -#actions[switchuser]="???" -#actions[logout]="loginctl terminate-session ${XDG_SESSION_ID-}" -actions[logout]="i3-msg exit" -actions[suspend]="systemctl suspend" -actions[hibernate]="systemctl hibernate" -actions[reboot]="systemctl reboot" -actions[shutdown]="systemctl poweroff" - -# By default, ask for confirmation for actions that are irreversible -confirmations=(reboot shutdown logout) - -# By default, no dry run -dryrun=false -showsymbols=true -showtext=true - -function check_valid { - option="$1" - shift 1 - for entry in "${@}" - do - if [ -z "${actions[$entry]+x}" ] - then - echo "Invalid choice in $1: $entry" >&2 - exit 1 - fi - done -} - -# Parse command-line options -parsed=$(getopt --options=h --longoptions=help,dry-run,confirm:,choices:,choose:,symbols,no-symbols,text,no-text,symbols-font: --name "$0" -- "$@") -if [ $? -ne 0 ]; then - echo 'Terminating...' >&2 - exit 1 -fi -eval set -- "$parsed" -unset parsed -while true; do - case "$1" in - "-h"|"--help") - echo "rofi-power-menu - a power menu mode for Rofi" - echo - echo "Usage: rofi-power-menu [--choices CHOICES] [--confirm CHOICES]" - echo " [--choose CHOICE] [--dry-run] [--symbols|--no-symbols]" - echo - echo "Use with Rofi in script mode. For instance, to ask for shutdown or reboot:" - echo - echo " rofi -show menu -modi \"menu:rofi-power-menu --choices=shutdown/reboot\"" - echo - echo "Available options:" - echo " --dry-run Don't perform the selected action but print it to stderr." - echo " --choices CHOICES Show only the selected choices in the given order. Use /" - echo " as the separator. Available choices are lockscreen," - echo " logout,suspend, hibernate, reboot and shutdown. By" - echo " default, all available choices are shown." - echo " --confirm CHOICES Require confirmation for the gives choices only. Use / as" - echo " the separator. Available choices are lockscreen, logout," - echo " suspend, hibernate, reboot and shutdown. By default, only" - echo " irreversible actions logout, reboot and shutdown require" - echo " confirmation." - echo " --choose CHOICE Preselect the given choice and only ask for a" - echo " confirmation (if confirmation is set to be requested). It" - echo " is strongly recommended to combine this option with" - echo " --confirm=CHOICE if the choice wouldn't require" - echo " confirmation by default. Available choices are" - echo " lockscreen, logout, suspend, hibernate, reboot and" - echo " shutdown." - echo " --[no-]symbols Show Unicode symbols or not. Requires a font with support" - echo " for the symbols. Use, for instance, fonts from the" - echo " Nerdfonts collection. By default, they are shown" - echo " --[no-]text Show text description or not." - echo " --symbols-font FONT Use the given font for symbols. By default, the symbols" - echo " use the same font as the text. That font is configured" - echo " with rofi." - echo " -h,--help Show this help text." - exit 0 - ;; - "--dry-run") - dryrun=true - shift 1 - ;; - "--confirm") - IFS='/' read -ra confirmations <<< "$2" - check_valid "$1" "${confirmations[@]}" - shift 2 - ;; - "--choices") - IFS='/' read -ra show <<< "$2" - check_valid "$1" "${show[@]}" - shift 2 - ;; - "--choose") - # Check that the choice is valid - check_valid "$1" "$2" - selectionID="$2" - shift 2 - ;; - "--symbols") - showsymbols=true - shift 1 - ;; - "--no-symbols") - showsymbols=false - shift 1 - ;; - "--text") - showtext=true - shift 1 - ;; - "--no-text") - showtext=false - shift 1 - ;; - "--symbols-font") - symbols_font="$2" - shift 2 - ;; - "--") - shift - break - ;; - *) - echo "Internal error" >&2 - exit 1 - ;; - esac -done - -if [ "$showsymbols" = "false" -a "$showtext" = "false" ] -then - echo "Invalid options: cannot have --no-symbols and --no-text enabled at the same time." >&2 - exit 1 -fi - -# Define the messages after parsing the CLI options so that it is possible to -# configure them in the future. - -function write_message { - if [ -z ${symbols_font+x} ]; - then - icon="$1" - else - icon="$1" - fi - text="$2" - if [ "$showsymbols" = "true" ] - then - if [ "$showtext" = "true" ] - then - echo -n "\u200e$icon \u2068$text\u2069" - else - echo -n "\u200e$icon" - fi - else - echo -n "$text" - fi -} - -function print_selection { - echo -e "$1" | $(read -r -d '' entry; echo "echo $entry") -} - -declare -A messages -declare -A confirmationMessages -for entry in "${all[@]}" -do - messages[$entry]=$(write_message "${icons[$entry]}" "${texts[$entry]^}") -done -for entry in "${all[@]}" -do - # Add zero-width space character (\u200b) to icon to ensure confirmation- - # and regular messages never collide. - confirmationMessages[$entry]=$(write_message "${icons[$entry]}\u200b" "Yes, ${texts[$entry]}") -done -confirmationMessages[cancel]=$(write_message "${icons[cancel]}" "No, cancel") - -if [ $# -gt 0 ] -then - # If arguments given, use those as the selection - selection="${@}" -else - # Otherwise, use the CLI passed choice if given - if [ -n "${selectionID+x}" ] - then - selection="${messages[$selectionID]}" - fi -fi - -# Don't allow custom entries -echo -e "\0no-custom\x1ftrue" -# Use markup -echo -e "\0markup-rows\x1ftrue" - -if [ -z "${selection+x}" ] -then - echo -e "\0prompt\x1fPower menu" - for entry in "${show[@]}" - do - echo -e "${messages[$entry]}\0icon\x1f${icons[$entry]}" - done -else - for entry in "${show[@]}" - do - if [ "$selection" = "$(print_selection "${messages[$entry]}")" ] - then - # Check if the selected entry is listed in confirmation requirements - for confirmation in "${confirmations[@]}" - do - if [ "$entry" = "$confirmation" ] - then - # Ask for confirmation - echo -e "\0prompt\x1fAre you sure" - echo -e "${confirmationMessages[$entry]}\0icon\x1f${icons[$entry]}" - echo -e "${confirmationMessages[cancel]}\0icon\x1f${icons[cancel]}" - exit 0 - fi - done - # If not, then no confirmation is required, so mark confirmed - selection=$(print_selection "${confirmationMessages[$entry]}") - fi - if [ "$selection" = "$(print_selection "${confirmationMessages[$entry]}")" ] - then - if [ $dryrun = true ] - then - # Tell what would have been done - echo "Selected: $entry" >&2 - else - # Perform the action - ${actions[$entry]} - fi - exit 0 - fi - if [ "$selection" = "$(print_selection "${confirmationMessages[cancel]}")" ] - then - # Do nothing - exit 0 - fi - done - # The selection didn't match anything, so raise an error - echo "Invalid selection: $selection" >&2 - exit 1 -fi diff --git a/sakura.conf b/sakura.conf deleted file mode 100644 index 8e1c8a9..0000000 --- a/sakura.conf +++ /dev/null @@ -1,79 +0,0 @@ -[sakura] -colorset1_fore=rgb(229,194,190) -colorset1_back=rgb(15,36,67) -colorset1_curs=rgb(255,255,255) -colorset1_scheme=0 -colorset1_key=F1 -colorset2_fore=rgb(192,192,192) -colorset2_back=rgb(0,0,0) -colorset2_curs=rgb(255,255,255) -colorset2_scheme=1 -colorset2_key=F2 -colorset3_fore=rgb(192,192,192) -colorset3_back=rgb(0,0,0) -colorset3_curs=rgb(255,255,255) -colorset3_scheme=1 -colorset3_key=F3 -colorset4_fore=rgb(192,192,192) -colorset4_back=rgb(0,0,0) -colorset4_curs=rgb(255,255,255) -colorset4_scheme=1 -colorset4_key=F4 -colorset5_fore=rgb(192,192,192) -colorset5_back=rgb(0,0,0) -colorset5_curs=rgb(255,255,255) -colorset5_scheme=1 -colorset5_key=F5 -colorset6_fore=rgb(192,192,192) -colorset6_back=rgb(0,0,0) -colorset6_curs=rgb(255,255,255) -colorset6_scheme=1 -colorset6_key=F6 -last_colorset=1 -bold_is_bright=false -scroll_lines=4096 -font=Source Code Pro 14 -show_tab_bar=multiple -scrollbar=false -closebutton=true -new_tab_after_current=true -tabs_on_bottom=false -less_questions=false -copy_on_select=false -disable_numbered_tabswitch=false -use_fading=false -scrollable_tabs=true -urgent_bell=Yes -audible_bell=Yes -blinking_cursor=No -cursor_type=VTE_CURSOR_SHAPE_BLOCK -word_chars=-,./?%&#_~: -palette=1 -add_tab_accelerator=5 -del_tab_accelerator=5 -switch_tab_accelerator=8 -move_tab_accelerator=9 -copy_accelerator=5 -scrollbar_accelerator=5 -open_url_accelerator=5 -font_size_accelerator=4 -set_tab_name_accelerator=5 -search_accelerator=5 -add_tab_key=T -del_tab_key=W -prev_tab_key=Left -next_tab_key=Right -copy_key=C -paste_key=V -scrollbar_key=S -set_tab_name_key=N -search_key=F -increase_font_size_key=plus -decrease_font_size_key=minus -fullscreen_key=F11 -set_colorset_accelerator=5 -icon_file=terminal-tango.svg -paste_button=2 -menu_button=3 -window_columns=80 -window_rows=24 diff --git a/swayconfig b/swayconfig deleted file mode 100644 index 525848b..0000000 --- a/swayconfig +++ /dev/null @@ -1,255 +0,0 @@ -# me sway config file :) - -# setup colors + pape from wal -include "/home/slime/.cache/wal/colors-sway" - -# setup display -output HDMI-A-1 mode 1920x1080@180hz - -# set wallpaper -output HDMI-A-1 bg $wallpaper stretch - -# start statusbar -exec --no-startup-id waybar -c /home/slime/.config/waybar/config -s /home/slime/.config/waybar/style.css - -# run screenshare fix scrip -exec XDG_CURRENT_DESKTOP=sway -exec --no-startup-id /home/slime/Scripts/sway_screenshare_fix - -# run systray programs -# exec --no-startup-id nm-applet - - -# set supa key -set $mod Mod4 - -# Font for window titles. Will also be used by the bar unless a different font -# is used in the bar {} block below. -font pango:Source Code Pro 16 - -# Use pactl to adjust volume in PulseAudio. -#set $refresh_i3status killall -SIGUSR1 i3status -bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5% && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5% && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && pkill -SIGRTMIN+10 i3blocks -bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && pkill -SIGRTMIN+10 i3blocks - -# Use Mouse+$mod to drag floating windows to their wanted position -floating_modifier $mod - -# start a terminal -bindsym $mod+Return exec foot -f "IBM Plex Mono:size=12" - -# kill focused window -bindsym $mod+Shift+q kill - -# start Rofi -bindsym $mod+Space exec rofi -show run -theme '/home/slime/.config/rofi/theme.rasi' - -# change focus w/ vim keys -bindsym $mod+h focus left -bindsym $mod+j focus down -bindsym $mod+k focus up -bindsym $mod+l focus right -# or, with the cursor keys: -bindsym $mod+Left focus left -bindsym $mod+Down focus down -bindsym $mod+Up focus up -bindsym $mod+Right focus right - -# move focused window pos -bindsym $mod+Shift+h move left -bindsym $mod+Shift+j move down -bindsym $mod+Shift+k move up -bindsym $mod+Shift+l move right -# or, with the cursor keys: -bindsym $mod+Shift+Left move left -bindsym $mod+Shift+Down move down -bindsym $mod+Shift+Up move up -bindsym $mod+Shift+Right move right - -# split in horizontal orientation -# bindsym $mod+Shift+h split h - -# split in vertical orientation -# bindsym $mod+v split v - -# enter fullscreen mode for the focused container -bindsym $mod+f fullscreen toggle - -# change container layout (stacked, tabbed, toggle split) -# bindsym $mod+s layout stacking -bindsym $mod+w layout tabbed -bindsym $mod+e layout toggle split - -# toggle tiling / floating -bindsym $mod+Shift+space floating toggle - -# change focus between tiling / floating windows -bindsym $mod+t focus mode_toggle - -# focus the parent container -bindsym $mod+a focus parent - -# focus the child container -#bindsym $mod+d focus child - -# Define names for default workspaces for which we configure key bindings later on. -# We use variables to avoid repeating the names in multiple places. -set $ws1 "1:  " -set $ws2 "2:  " -set $ws3 "3:  " -set $ws4 "4:  " -set $ws5 "5" -set $ws6 "6" -set $ws7 "7" -set $ws8 "8" -set $ws9 "9" -set $ws10 "0:  " - - -# workspace $ws10 output "Screen 0" - -# switch to workspace -bindsym $mod+1 workspace number $ws1 -bindsym $mod+2 workspace number $ws2 -bindsym $mod+3 workspace number $ws3 -bindsym $mod+4 workspace number $ws4 -bindsym $mod+5 workspace number $ws5 -bindsym $mod+6 workspace number $ws6 -bindsym $mod+7 workspace number $ws7 -bindsym $mod+8 workspace number $ws8 -bindsym $mod+9 workspace number $ws9 -bindsym $mod+0 workspace number $ws10 - -# move focused container to workspace -bindsym $mod+Shift+1 move container to workspace number $ws1 -bindsym $mod+Shift+2 move container to workspace number $ws2 -bindsym $mod+Shift+3 move container to workspace number $ws3 -bindsym $mod+Shift+4 move container to workspace number $ws4 -bindsym $mod+Shift+5 move container to workspace number $ws5 -bindsym $mod+Shift+6 move container to workspace number $ws6 -bindsym $mod+Shift+7 move container to workspace number $ws7 -bindsym $mod+Shift+8 move container to workspace number $ws8 -bindsym $mod+Shift+9 move container to workspace number $ws9 -bindsym $mod+Shift+0 move container to workspace number $ws10 - -# reload the configuration file -bindsym $mod+Shift+c reload -# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) -bindsym $mod+Shift+r restart - -# TODO: bindsym $mod+Shift+e exec --no-startup-id "rofi -show powermenu -modi powermenu:~/Scripts/rofi-power-menu -theme ~/.config/rofi/theme.rasi" - -# resize window (you can also use the mouse for that) -mode "resize" { - # These bindings trigger as soon as you enter the resize mode - - # Pressing left will shrink the window’s width. - # Pressing right will grow the window’s width. - # Pressing up will shrink the window’s height. - # Pressing down will grow the window’s height. - bindsym h resize shrink width 10 px or 10 ppt - bindsym j resize grow height 10 px or 10 ppt - bindsym k resize shrink height 10 px or 10 ppt - bindsym l resize grow width 10 px or 10 ppt - - # same bindings, but for the arrow keys - bindsym Left resize shrink width 10 px or 10 ppt - bindsym Down resize grow height 10 px or 10 ppt - bindsym Up resize shrink height 10 px or 10 ppt - bindsym Right resize grow width 10 px or 10 ppt - - # back to normal: Enter or Escape or $mod+r - bindsym Return mode "default" - bindsym Escape mode "default" - bindsym $mod+r mode "default" -} - -bindsym $mod+r mode "resize" - - -###################### -# START CUSTOM STUFF # -###################### - -# Screenshot taker bind -bindsym Print exec --no-startup-id flameshot gui - -# Color variables for default sway-bar (sourced from wal in first lines) - -# class border backgr. text indicator child_border -# client.focused $background $background $foreground $background $background -# client.focused_inactive $background $background $foreground $background $background -# client.unfocused $background $background $foreground $background $background -# client.urgent $background $background $foreground $background $background -# client.placeholder $background $background $foreground $background $background -# -# client.background $background -# -# bar { -# position top -# status_command i3blocks -# strip_workspace_numbers yes -# status_padding 5 -# status_edge_padding 15 -# tray_output * -# tray_padding 2 -# separator_symbol "~" -# -# colors { -# background $background -# separator $foreground -# # border bg txt -# focused_workspace $foreground $background $foreground -# inactive_workspace $background $background $foreground -# urgent_workspace #E53935 $background $foreground -# } -# } - -# Workspace assignment -assign [class="LibreWolf"] $ws1 -assign [class="Discord"] $ws3 -assign [class="Conky"] $ws10 -assign [class="steam"] $ws4 - -for_window [class="Conky"] floating enable - -# Borders -default_border pixel 0 -default_floating_border pixel 2 - -# Gap -gaps inner 30 -gaps outer 30 - -bindsym $mod+s gaps inner current plus 5 -bindsym $mod+Shift+s gaps inner current minus 5 -bindsym $mod+z gaps outer current plus 5 -bindsym $mod+Shift+z gaps outer current minus 5 - -# Media player controls -bindsym XF86AudioPlay exec --no-startup-id playerctl play -bindsym XF86AudioPause exec --no-startup-id playerctl pause -bindsym XF86AudioNext exec --no-startup-id playerctl next -bindsym XF86AudioPrev exec --no-startup-id playerctl previous - -# Vim Keybindings ;P -input "type:keyboard" { - xkb_layout us - xkb_options caps:escape -} - - # -# Scratchpad: -# - # Sway has a "scratchpad", which is a bag of holding for windows. - # You can send windows there and get them back later. - - # Move the currently focused window to the scratchpad - bindsym $mod+Shift+minus move scratchpad - - # Show the next scratchpad window or hide the focused scratchpad window. - # If there are multiple scratchpad windows, this command cycles through them. - bindsym $mod+minus scratchpad show -# diff --git a/theme.rasi b/theme.rasi deleted file mode 100644 index ae7a8e6..0000000 --- a/theme.rasi +++ /dev/null @@ -1,116 +0,0 @@ -* { - font: "IBM Plex Mono 10"; - - bg : #161314; - scroll : #705b66; - - fg : #c4c4c4; - red : #f7768e; - green : #9ece6a; - blue : #7aa2f7; - magenta : #9a7ecc; - cyan : #4abaaf; - - urgent: #7D8295; - - background-color: @bg; - - text-color : @fg; - - margin : 0; - padding : 0; - spacing : 0; -} - -element-icon, element-text, scrollbar { - cursor: pointer; -} - -window { - location : northwest; - width : 280px; - x-offset : 0px; - y-offset : 38px; - - background-color: @bg; -} - -inputbar { - spacing : 8px; - padding : 4px 8px; - children : [ icon-search, entry ]; - - background-color: @bg; -} - -icon-search, entry, element-icon, element-text { - vertical-align: 0.5; - background-color: @bg; - text-color: @fg; -} - -icon-search { - display: none; - expand : false; - filename : "search-symbolic"; - size : 0px; -} - -textbox { - padding : 4px 8px; -} - -listview { - padding : 4px 0px; - lines : 5; - columns : 1; - scrollbar : false; - fixed-height : false; - dynamic : true; -} - -element { - padding : 4px 8px; - spacing : 8px; - - background-color: @bg; - text-color: @fg; -} - -element normal urgent { - text-color: @urgent; - background-color: @fg; -} - -element normal active { -} - -element alternate active { - text-color: inherit; - background-color: inherit; -} - -element selected { - background-color: @fg; - text-color: @bg; -} - -element selected urgent { - background-color: @urgent; -} - -element-icon { - display: none; - size: 0.8em; -} - -element-text { - text-color: inherit; - background-color: inherit; -} - -scrollbar { - handle-width : 4px; - handle-color : @scroll; - padding : 0 4px; -} diff --git a/wal/templates/desktop-rofi-theme.rasi b/wal/templates/desktop-rofi-theme.rasi new file mode 100644 index 0000000..f499381 --- /dev/null +++ b/wal/templates/desktop-rofi-theme.rasi @@ -0,0 +1,113 @@ +* {{ + font: "IBM Plex Mono 10"; + + bg : {background}; + scroll : {color8}; + + fg : {foreground}; + + urgent: {color9}; + + background-color: @bg; + + text-color : @fg; + + margin : 0; + padding : 0; + spacing : 0; +}} + +element-icon, element-text, scrollbar {{ + cursor: pointer; +}} + +window {{ + location : center; + width : 280px; + x-offset : 0px; + y-offset : 38px; + + background-color: @bg; + border-color: @fg; + border: 2px; +}} + +inputbar {{ + spacing : 8px; + padding : 14px 8px; + children : [ icon-search, entry ]; + + background-color: @bg; +}} + +icon-search, entry, element-icon, element-text {{ + vertical-align: 0.5; + background-color: @bg; + text-color: @fg; +}} + +icon-search {{ + display: none; + expand : false; + filename : "search-symbolic"; + size : 0px; +}} + +textbox {{ + padding : 4px 8px; +}} + +listview {{ + padding : 4px 0px; + lines : 5; + columns : 1; + scrollbar : false; + fixed-height : false; + dynamic : true; +}} + +element {{ + padding : 4px 8px; + spacing : 8px; + + background-color: @bg; + text-color: @fg; +}} + +element normal urgent {{ + text-color: @urgent; + background-color: @fg; +}} + +element normal active {{ +}} + +element alternate active {{ + text-color: inherit; + background-color: inherit; +}} + +element selected {{ + background-color: @fg; + text-color: @bg; +}} + +element selected urgent {{ + background-color: @urgent; +}} + +element-icon {{ + display: none; + size: 0.8em; +}} + +element-text {{ + text-color: inherit; + background-color: inherit; +}} + +scrollbar {{ + handle-width : 4px; + handle-color : @scroll; + padding : 0 4px; +}} diff --git a/wal/templates/theme.rasi b/wal/templates/theme.rasi deleted file mode 100644 index f499381..0000000 --- a/wal/templates/theme.rasi +++ /dev/null @@ -1,113 +0,0 @@ -* {{ - font: "IBM Plex Mono 10"; - - bg : {background}; - scroll : {color8}; - - fg : {foreground}; - - urgent: {color9}; - - background-color: @bg; - - text-color : @fg; - - margin : 0; - padding : 0; - spacing : 0; -}} - -element-icon, element-text, scrollbar {{ - cursor: pointer; -}} - -window {{ - location : center; - width : 280px; - x-offset : 0px; - y-offset : 38px; - - background-color: @bg; - border-color: @fg; - border: 2px; -}} - -inputbar {{ - spacing : 8px; - padding : 14px 8px; - children : [ icon-search, entry ]; - - background-color: @bg; -}} - -icon-search, entry, element-icon, element-text {{ - vertical-align: 0.5; - background-color: @bg; - text-color: @fg; -}} - -icon-search {{ - display: none; - expand : false; - filename : "search-symbolic"; - size : 0px; -}} - -textbox {{ - padding : 4px 8px; -}} - -listview {{ - padding : 4px 0px; - lines : 5; - columns : 1; - scrollbar : false; - fixed-height : false; - dynamic : true; -}} - -element {{ - padding : 4px 8px; - spacing : 8px; - - background-color: @bg; - text-color: @fg; -}} - -element normal urgent {{ - text-color: @urgent; - background-color: @fg; -}} - -element normal active {{ -}} - -element alternate active {{ - text-color: inherit; - background-color: inherit; -}} - -element selected {{ - background-color: @fg; - text-color: @bg; -}} - -element selected urgent {{ - background-color: @urgent; -}} - -element-icon {{ - display: none; - size: 0.8em; -}} - -element-text {{ - text-color: inherit; - background-color: inherit; -}} - -scrollbar {{ - handle-width : 4px; - handle-color : @scroll; - padding : 0 4px; -}} diff --git a/waybar-wal-template.css b/waybar-wal-template.css deleted file mode 100644 index 5968316..0000000 --- a/waybar-wal-template.css +++ /dev/null @@ -1,329 +0,0 @@ -* { - /* `otf-font-awesome` is required to be installed for icons */ - font-family: smoothansi; - font-size: 14px; -} - -window#waybar { - background-color: {background}; - border-bottom: 3px solid {color1}; - color: {foreground}; - transition-property: background-color; - transition-duration: .5s; -} - -window#waybar.hidden { - opacity: 0.2; -} - -/* -window#waybar.empty { - background-color: transparent; -} -window#waybar.solo { - background-color: #FFFFFF; -} - -window#waybar.termite { - background-color: #3F3F3F; -} - -window#waybar.chromium { - background-color: #000000; - border: none; -} -*/ - -button { - /* Use box-shadow instead of border so the text isn't offset */ - box-shadow: inset 0 -3px {color1}; - /* Avoid rounded borders under each button name */ - border: none; - border-radius: 0; -} - -/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ -button:hover { - background: inherit; - box-shadow: inset 0 -3px {foreground}; -} - -/* you can set a style on hover for any module like this */ -#pulseaudio:hover { - background-color: {color2}; -} - -#workspaces button { - padding: 0 5px; - background-color: transparent; - color: {foreground}; -} - -#workspaces button:hover { - background: rgba(0, 0, 0, 0.2); -} - -#workspaces button.focused, #workspaces button.active { - background-color: {color1}; - box-shadow: inset 0 -3px {color1}; -} - -#workspaces button.urgent { - background-color: {color13}; -} - -#mode { - background-color: {background}; - box-shadow: inset 0 -3px {color1}; -} - -#clock, -#battery, -#cpu, -#memory, -#disk, -#temperature, -#backlight, -#network, -#pulseaudio, -#wireplumber, -#custom-media, -#tray, -#mode, -#idle_inhibitor, -#scratchpad, -#power-profiles-daemon, -#mpd { - padding: 0 10px; - color: {foreground}; - - box-shadow: inset 0 -3px {color1}; -} - -#window, -#workspaces { - margin: 0 4px; -} - -/* If workspaces is the leftmost module, omit left margin */ -.modules-left > widget:first-child > #workspaces { - margin-left: 0; -} - -/* If workspaces is the rightmost module, omit right margin */ -.modules-right > widget:last-child > #workspaces { - margin-right: 0; -} - -#clock { - background-color: {background}; -} - -#battery { - background-color: {background}; - color: {foreground}; -} - -#battery.charging, #battery.plugged { - color: {foreground}; - background-color: {background}; -} - -@keyframes blink { - to { - background-color: {foreground}; - color: {background}; - } -} - -/* Using steps() instead of linear as a timing function to limit cpu usage */ -#battery.critical:not(.charging) { - background-color: #f53c3c; - color: #ffffff; - animation-name: blink; - animation-duration: 0.5s; - animation-timing-function: steps(12); - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#power-profiles-daemon { - padding-right: 15px; -} - -#power-profiles-daemon.performance { - background-color: #f53c3c; - color: #ffffff; -} - -#power-profiles-daemon.balanced { - background-color: #2980b9; - color: #ffffff; -} - -#power-profiles-daemon.power-saver { - background-color: #2ecc71; - color: #000000; -} - -label:focus { - background-color: {foreground}; -} - -#cpu { - background-color: {background}; - color: {foreground}; -} - -#memory { - background-color: {background}; -} - -#disk { - background-color: {background}; -} - -#backlight { - background-color: {background}; -} - -#network { - background-color: {background}; -} - -#network.disconnected { - background-color: #f53c3c; -} - -#pulseaudio { - background-color: {background}; - color: {foreground}; -} - -#pulseaudio.muted { - background-color: {color11}; - color: {foreground}; -} - -#wireplumber { - background-color: {background}; - color: {foreground}; -} - -#wireplumber.muted { - background-color: {color11}; -} - -#custom-media { - background-color: #66cc99; - color: #2a5c45; - min-width: 100px; -} - -#custom-media.custom-spotify { - background-color: #66cc99; -} - -#custom-media.custom-vlc { - background-color: #ffa000; -} - -#temperature { - background-color: #f0932b; -} - -#temperature.critical { - background-color: #eb4d4b; -} - -#tray { - background-color: {background}; -} - -#tray > .passive { - -gtk-icon-effect: dim; -} - -#tray > .needs-attention { - -gtk-icon-effect: highlight; - background-color: {color11}; -} - -#idle_inhibitor { - background-color: #2d3436; -} - -#idle_inhibitor.activated { - background-color: #ecf0f1; - color: #2d3436; -} - -#mpd { - background-color: #66cc99; - color: #2a5c45; -} - -#mpd.disconnected { - background-color: #f53c3c; -} - -#mpd.stopped { - background-color: #90b1b1; -} - -#mpd.paused { - background-color: #51a37a; -} - -#language { - background: #00b093; - color: #740864; - padding: 0 5px; - margin: 0 5px; - min-width: 16px; -} - -#keyboard-state { - background: #97e1ad; - color: #000000; - padding: 0 0px; - margin: 0 5px; - min-width: 16px; -} - -#keyboard-state > label { - padding: 0 5px; -} - -#keyboard-state > label.locked { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad.empty { - background-color: transparent; -} - -#privacy { - padding: 0; -} - -#privacy-item { - padding: 0 5px; - color: white; -} - -#privacy-item.screenshare { - background-color: #cf5700; -} - -#privacy-item.audio-in { - background-color: #1ca000; -} - -#privacy-item.audio-out { - background-color: #0069d4; -} diff --git a/waybar_config b/waybar_config deleted file mode 100644 index 5e2f130..0000000 --- a/waybar_config +++ /dev/null @@ -1,220 +0,0 @@ -// -*- mode: jsonc -*- -{ - // "layer": "top", // Waybar at top layer - // "position": "bottom", // Waybar position (top|bottom|left|right) - "height": 30, // Waybar height (to be removed for auto height) - "width": 1280, // Waybar width - "spacing": 4, // Gaps between modules (4px) - // Choose the order of the modules - "modules-left": [ - "sway/workspaces", - "sway/mode", - "sway/scratchpad" - // "custom/media" - ], - "modules-center": [ - "sway/window" - ], - "modules-right": [ - // "mpd", - // "idle_inhibitor", - "pulseaudio", - // "network", - // "power-profiles-daemon", - "cpu", - "memory", - // "temperature", - // "backlight", - // "keyboard-state", - // "sway/language", - // "battery", - // "battery#bat2", - "clock", - "tray"] - , - // Modules configuration - // "sway/workspaces": { - // "disable-scroll": true, - // "all-outputs": true, - // "warp-on-scroll": false, - // "format": "{name}: {icon}", - // "format-icons": { - // "1": "", - // "2": "", - // "3": "", - // "4": "", - // "5": "", - // "urgent": "", - // "focused": "", - // "default": "" - // } - // }, - "keyboard-state": { - "numlock": true, - "capslock": true, - "format": "{name} {icon}", - "format-icons": { - "locked": "", - "unlocked": "" - } - }, - "sway/mode": { - "format": "{}" - }, - "sway/scratchpad": { - "format": "{icon} {count}", - "show-empty": false, - "format-icons": ["", ""], - "tooltip": true, - "tooltip-format": "{app}: {title}" - }, - "mpd": { - "format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {album} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S}) ⸨{songPosition}|{queueLength}⸩ {volume}% ", - "format-disconnected": "Disconnected ", - "format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ", - "unknown-tag": "N/A", - "interval": 5, - "consume-icons": { - "on": " " - }, - "random-icons": { - "off": " ", - "on": " " - }, - "repeat-icons": { - "on": " " - }, - "single-icons": { - "on": "1 " - }, - "state-icons": { - "paused": "", - "playing": "" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "", - "deactivated": "" - } - }, - "tray": { - // "icon-size": 21, - "spacing": 8, - // "icons": { - // "blueman": "bluetooth", - // "TelegramDesktop": "$HOME/.local/share/icons/hicolor/16x16/apps/telegram.png" - // } - }, - "clock": { - // "timezone": "America/New_York", - "format": "{:%a, %H:%M}", - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "cpu: {usage}%", - "tooltip": false - }, - "memory": { - "format": "ram: {}%" - }, - "temperature": { - // "thermal-zone": 2, - // "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - // "format-critical": "{temperatureC}°C {icon}", - "format": "{temperatureC}°C {icon}", - "format-icons": ["", "", ""] - }, - "backlight": { - // "device": "acpi_video1", - "format": "{percent}% {icon}", - "format-icons": ["", "", "", "", "", "", "", "", ""] - }, - "battery": { - "states": { - // "good": 95, - "warning": 30, - "critical": 15 - }, - "format": "{capacity}% {icon}", - "format-full": "{capacity}% {icon}", - "format-charging": "{capacity}% ", - "format-plugged": "{capacity}% ", - "format-alt": "{time} {icon}", - // "format-good": "", // An empty format will hide the module - // "format-full": "", - "format-icons": ["", "", "", "", ""] - }, - "battery#bat2": { - "bat": "BAT2" - }, - "power-profiles-daemon": { - "format": "{icon}", - "tooltip-format": "Power profile: {profile}\nDriver: {driver}", - "tooltip": true, - "format-icons": { - "default": "", - "performance": "", - "balanced": "", - "power-saver": "" - } - }, - "network": { - // "interface": "wlp2*", // (Optional) To force the use of this interface - "format-wifi": " {signalStrength}%", - "format-ethernet": "{ipaddr}/{cidr} ", - "tooltip-format": "{ifname} via {gwaddr} ", - "format-linked": "{ifname} (No IP) ", - "format-disconnected": "Disconnected ⚠", - "format-alt": "{ifname}: {ipaddr}/{cidr}" - }, - "pulseaudio": { - // "scroll-step": 1, // %, can be a float - // "format": "{volume}% {icon} {format_source}", - "format": "vol: {volume}%", - "format-bluetooth": "{volume}% {icon} {format_source}", - "format-bluetooth-muted": " {icon} {format_source}", - "format-muted": " {format_source}", - "format-source": "{volume}% ", - "format-source-muted": "", - "format-icons": { - "headphone": "", - "hands-free": "", - "headset": "", - "phone": "", - "portable": "", - "car": "", - "default": ["", "", ""] - }, - "on-click": "pavucontrol" - }, - "custom/media": { - "format": "{icon} {text}", - "return-type": "json", - "max-length": 40, - "format-icons": { - "spotify": "", - "default": "🎜" - }, - "escape": true, - "exec": "$HOME/.config/waybar/mediaplayer.py 2> /dev/null" // Script in resources folder - // "exec": "$HOME/.config/waybar/mediaplayer.py --player spotify 2> /dev/null" // Filter player based on name - }, - "custom/power": { - "format" : "⏻ ", - "tooltip": false, - "menu": "on-click", - "menu-file": "$HOME/.config/waybar/power_menu.xml", // Menu file in resources folder - "menu-actions": { - "shutdown": "shutdown", - "reboot": "reboot", - "suspend": "systemctl suspend", - "hibernate": "systemctl hibernate" - } - } -} diff --git a/windows/windows-init.lua b/windows/windows-init.lua new file mode 100644 index 0000000..95b3b09 --- /dev/null +++ b/windows/windows-init.lua @@ -0,0 +1,105 @@ +-- WINDOWS SHELL COMPATIBILITY (needed for sf.nvim command runner) +if vim.fn.has("win32") == 1 then + vim.opt.shell = "cmd.exe" + vim.opt.shellcmdflag = "/s /c" + vim.opt.shellquote = "" + vim.opt.shellxquote = '"' -- Crucial for handling quotes and && properly in cmd +end + +-- plugins -- +vim.pack.add({ + 'https://github.com/stevearc/oil.nvim', + 'https://github.com/nvim-mini/mini.move', + 'https://github.com/nvim-mini/mini.icons', + 'https://github.com/ibhagwan/fzf-lua', + 'https://github.com/xixiaofinland/sf.nvim', + 'https://github.com/nvim-treesitter/nvim-treesitter', + -- [completion] --------------------------------------------------------------- + { src = "https://github.com/Saghen/blink.cmp", version = vim.version.range('v1.10.2') }, + +}) + +require("oil").setup() +require("mini.move").setup() +require("mini.icons").setup() +require("fzf-lua").setup() +require("nvim-treesitter").setup() +require("blink.cmp").setup() +require("sf").setup({ + types_to_retrieve = { + "ApexClass", + "ApexTrigger", + "CustomPermission", + "CustomApplication", + "CustomMetadata", + "CustomSetting", + "CustomTab", + "CustomObject", + "Flow", + "FlowDefinition", + "Layout", + "LightningComponentBundle", + "PermissionSetGroup", + "PermissionSet", + "Profile", + "StaticResource", + "SharingRule" + }, +}) + +vim.loader.enable() -- speed up launch! + + +-- treesitter - dynamically determine language +vim.api.nvim_create_autocmd("FileType", { + group = vim.api.nvim_create_augroup("tree-sitter-enable", { clear = true }), + callback = function(args) + local lang = vim.treesitter.language.get_lang(args.match) + if not lang then + return + end + if vim.treesitter.query.get(lang, "highlights") then + vim.treesitter.start(args.buf) + end + if vim.treesitter.query.get(lang, "indents") then + vim.opt_local.indentexpr = 'v:lua.require("nvim-treesitter").indentexpr()' + end + + -- from treesitter docs for folding + vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' + vim.opt.foldmethod = 'expr' + end, +}) + + +-- normal mode +vim.api.nvim_set_keymap('i','jk','',{noremap=true,silent=true}) +vim.api.nvim_set_keymap('i','kj','',{noremap=true,silent=true}) + +-- ui +vim.opt.foldlevelstart = 99 +vim.o.scrolloff = 10 +vim.o.number = true +vim.o.relativenumber = true +vim.o.showmode = false +vim.o.signcolumn = "yes" +vim.o.pumheight = 15 +vim.o.shortmess = "CFOSWaco" + +-- search +vim.o.imsearch = 0 +vim.o.hlsearch = true +vim.o.incsearch = true +vim.o.ignorecase = true +vim.o.smartcase = true + +local map = vim.keymap.set + +-- KEYMAPS - for plugins +map("n", "-", "Oil", { desc = "Open parent directory" }) + +-- KEYMAPS - movement +map("n", "", "zz") +map("n", "", "zz") +map("n", "", "zz") +map("n", "", "zz") -- cgit v1.3.1-4-g156e