From a255db8ef33266f1edc689264f6a2cc5dacbbc0e Mon Sep 17 00:00:00 2001 From: IwanIDev Date: Wed, 25 Mar 2026 15:50:39 +0000 Subject: Add dotfiles from current setup --- .config/foot/catppuccin-mocha.ini | 34 +++++ .config/foot/foot.ini | 4 + .config/mako/config | 18 +++ .config/otter-launcher/config.toml | 127 +++++++++++++++++ .config/otter-launcher/pikachu.example | 8 ++ .config/sway/config | 252 +++++++++++++++++++++++++++++++++ .config/sway/env | 6 + .config/waybar/config.jsonc | 71 ++++++++++ .config/waybar/mocha.css | 26 ++++ .config/waybar/style.css | 102 +++++++++++++ 10 files changed, 648 insertions(+) create mode 100644 .config/foot/catppuccin-mocha.ini create mode 100644 .config/foot/foot.ini create mode 100644 .config/mako/config create mode 100644 .config/otter-launcher/config.toml create mode 100644 .config/otter-launcher/pikachu.example create mode 100644 .config/sway/config create mode 100644 .config/sway/env create mode 100644 .config/waybar/config.jsonc create mode 100644 .config/waybar/mocha.css create mode 100644 .config/waybar/style.css diff --git a/.config/foot/catppuccin-mocha.ini b/.config/foot/catppuccin-mocha.ini new file mode 100644 index 0000000..7b9f2df --- /dev/null +++ b/.config/foot/catppuccin-mocha.ini @@ -0,0 +1,34 @@ +[colors] +cursor=11111b f5e0dc +foreground=cdd6f4 +background=1e1e2e + +regular0=45475a +regular1=f38ba8 +regular2=a6e3a1 +regular3=f9e2af +regular4=89b4fa +regular5=f5c2e7 +regular6=94e2d5 +regular7=bac2de + +bright0=585b70 +bright1=f38ba8 +bright2=a6e3a1 +bright3=f9e2af +bright4=89b4fa +bright5=f5c2e7 +bright6=94e2d5 +bright7=a6adc8 + +16=fab387 +17=f5e0dc + +selection-foreground=cdd6f4 +selection-background=414356 + +search-box-no-match=11111b f38ba8 +search-box-match=cdd6f4 313244 + +jump-labels=11111b fab387 +urls=89b4fa diff --git a/.config/foot/foot.ini b/.config/foot/foot.ini new file mode 100644 index 0000000..4cbc64b --- /dev/null +++ b/.config/foot/foot.ini @@ -0,0 +1,4 @@ +[main] +include=~/.config/foot/catppuccin-mocha.ini + +font=JetBrainsMonoNL Nerd Font Mono:size=12 diff --git a/.config/mako/config b/.config/mako/config new file mode 100644 index 0000000..438e797 --- /dev/null +++ b/.config/mako/config @@ -0,0 +1,18 @@ +# General +anchor=top-right +font=FantasqueSansMono Nerd Font 12 +margin=0,20,20 +padding=10 +border-size=2 +border-radius=5 +default-timeout=10000 +group-by=summary + +#Colors +background-color=#1e1e2e +text-color=#cdd6f4 +border-color=#89b4fa +progress-color=over #313244 + +[urgency=high] +border-color=#fab387 diff --git a/.config/otter-launcher/config.toml b/.config/otter-launcher/config.toml new file mode 100644 index 0000000..1f4e9e9 --- /dev/null +++ b/.config/otter-launcher/config.toml @@ -0,0 +1,127 @@ +[general] +default_module = "app" # The module to run when no prefix is matched +empty_module = "a" # run with an empty prompt +exec_cmd = "sh -c" # The exec command of your shell, default to sh +# for example: "bach -c" for bash; "zsh -c" for zsh. This can also runs wm exec commands, like hyprctl dispatch exec +vi_mode = true # set true to use vi keybinds, false to use emacs keybinds; default to emacs +esc_to_abort = true # allow to quit with esc keypress; a useful option for vi users +cheatsheet_entry = "?" # when entered, otter-launcher will show a list of configured modules +cheatsheet_viewer = "less -R; clear" # the program that otter-launcher will pipe cheatsheet into +clear_screen_after_execution = false # useful when chafa image flash back after module execution +loop_mode = false # in loop mode, otter-launcher won't quit after running a module, useful when using scratchpad +external_editor = "" # if set, pressing ctrl+e (or pressing v in vi normal mode) will edit the input field in the specified program; default to no external editor +#callback = "" # if set, otter-launcher will run the command after a module is executed; for example, it can call swaymsg to adjust window size + +# ASCII color codes are allowed with these options. However, \x1b should be replaced with \u001B (unicode escape) because the rust toml crate cannot read \x as an escaped character... +[interface] +# use three quotes to write longer commands +header = """ + \u001B[34;1m >\u001B[0m $USER@$(echo $HOSTNAME) \u001B[31m\u001B[0m $(cat /proc/loadavg | cut -d ' ' -f 1) \u001B[33m󰍛\u001B[0m $(free -h | awk 'FNR == 2 {print $3}' | sed 's/i//') + \u001B[34;1m>\u001B[0;1m """ +# Run a shell command and make the stdout printed above the header +header_cmd = "" +header_cmd_trimmed_lines = 0 # Remove a number of lines from header_cmd output, in case of some programs printing excessive empty lines at the end of its output +header_concatenate = false # print header and header_cmd output at the same line, default to false +list_prefix = " " +selection_prefix = " \u001B[31;1m> " +place_holder = "type and search" +default_module_message = " \u001B[33msearch\u001B[0m the internet" # if set, the text will be shown when the default module is in use +empty_module_message = "" # the text to show when empty module is in use +suggestion_mode = "list" # available options: list, hint +suggestion_lines = 12 # length of the suggestion list, set to 0 to disable suggestions and tab completion +indicator_with_arg_module = "\u001B[31m^\u001B[0m " # a sign showing whether the module should run with an argument +indicator_no_arg_module = "\u001B[31m$\u001B[0m " +prefix_padding = 3 # format prefixes to have a uniformed width; prefixes will be padded with spaces to have a least specified number of chars +# below color options affect all modules; per-module coloring is allowed by using ascii color codes at each module's configurations +prefix_color = "\u001B[33m" +description_color = "\u001B[39m" +place_holder_color = "\u001B[30m" +hint_color = "\u001B[30m" # the color of hint mode suggestions +# move the whole interface rightward or upward, easier for styling with chafa image +move_right = 0 +move_up = 0 + + +[[modules]] +description = "search with brave" +prefix = "br" +cmd = "setsid -f xdg-open 'https://search.brave.com/search?q={}'" +with_argument = true +url_encode = true + +[[modules]] +description = "kill a runing app" +prefix = "k" +cmd = 'ps -u "$USER" -o comm= | sort -u | fsel --dmenu | xargs -r pkill -9' +with_argument = true +url_encode = true + +[[modules]] +description = "launch apps with fsel" +prefix = "a" +cmd = "fsel --filter-desktop=no -vv -r -d -ss \"{}\"" +with_argument = true + +[[modules]] +description = "launch apps instantly" +prefix = "app" +cmd = "fsel -vv -r -d -p {}" +with_argument = true + +[[modules]] +description = "manage clipboard with fsel" +prefix = "cl" +cmd = """ +fsel --cclip +""" + +[[modules]] +description = "find pkgs" +prefix = "pm" +cmd = "pmux -SD {}" +with_argument = true + +[[modules]] +description = "install pkgs" +prefix = "i" +cmd = "pmux -S {}" +with_argument = true + +[[modules]] +description = "power menu with fzf" +prefix = "p" +cmd = """ +function power { +if [[ -n $1 ]]; then +case $1 in +"logout") session=`loginctl session-status | head -n 1 | awk '{print $1}'`; loginctl terminate-session $session ;; +"suspend") systemctl suspend ;; +"hibernate") systemctl hibernate ;; +"reboot") systemctl reboot ;; +"shutdown") systemctl poweroff ;; +esac fi } +power $(echo -e 'reboot\nshutdown\nlogout\nsuspend\nhibernate' | fzf --reverse --no-scrollbar --padding 1,3 --prompt 'Power Menu: ' | tail -1) +""" + +[[modules]] +description = "run command in terminal" +prefix = "s" +cmd = """ +setsid -f "$(echo $TERM | sed 's/xterm-//g')" -e {} +""" +with_argument = true + +[[modules]] +description = "search archwiki" +prefix = "w" +cmd = "setsid -f xdg-open https://wiki.archlinux.org/index.php?search='{}'" +with_argument = true +url_encode = true + +[[modules]] +description = "cambridge dictionary" +prefix = "dc" +cmd = "setsid -f xdg-open 'https://dictionary.cambridge.org/dictionary/english/{}'" +with_argument = true +url_encode = true + diff --git a/.config/otter-launcher/pikachu.example b/.config/otter-launcher/pikachu.example new file mode 100644 index 0000000..404e020 --- /dev/null +++ b/.config/otter-launcher/pikachu.example @@ -0,0 +1,8 @@ +[?25l▃▚▄ ▗╴▁▁▄▄▖▖▖  +▇ ▂┈▁▌▇▆▉▄▖▁┈  + ▁▄▇▆▇▁▁┈╶▄▗▎▎▁ +▗▝▖▄▌▉▇▇▄▘▝▝▄╴▂ +▇▝▂▏▁▂▄──▘▍▇▇▇▂ +▂▅▅▅▅▇▗▗▏▂▂▁▎▝▝ +▖▝▅▄▂▂▂▂▂▂▂▂▂▅▅ +▇▅▅▂▂▖▅▅▅▅▝▖╴▂▃ [?25h diff --git a/.config/sway/config b/.config/sway/config new file mode 100644 index 0000000..cac2598 --- /dev/null +++ b/.config/sway/config @@ -0,0 +1,252 @@ +# Default config for sway +# +# Copy this to ~/.config/sway/config and edit it to your liking. +# +# Read `man 5 sway` for a complete reference. + +### Variables +# +# Logo key. Use Mod1 for Alt. +set $mod Mod4 +# Home row direction keys, like vim +set $left h +set $down j +set $up k +set $right l +# Your preferred terminal emulator +set $term foot +# Your preferred application launcher +set $menu foot --app-id otter-launcher -T foot $SHELL -i -c "otter-launcher" +for_window [app_id="otter-launcher"] floating enable + +### Output configuration +# +# Default wallpaper (more resolutions are available in /usr/share/backgrounds/sway/) +#output * bg /usr/share/backgrounds/sway/Sway_Wallpaper_Blue_1920x1080.png fill +# +# Example configuration: +# +# output HDMI-A-1 resolution 1920x1080 position 1920,0 +# +# You can get the names of your outputs by running: swaymsg -t get_outputs + +output HDMI-A-1 res 1920x1080 pos 0,0 +output eDP-1 res 1920x1080 pos 1920,0 + +### Idle configuration +# +# Example configuration: +# +# exec swayidle -w \ +# timeout 300 'swaylock -f -c 000000' \ +# timeout 600 'swaymsg "output * power off"' resume 'swaymsg "output * power on"' \ +# before-sleep 'swaylock -f -c 000000' +# +# This will lock your screen after 300 seconds of inactivity, then turn off +# your displays after another 300 seconds, and turn your screens back on when +# resumed. It will also lock your screen before your computer goes to sleep. + +### Input configuration +# +# Example configuration: +# +input type:touchpad { + dwt enabled + tap enabled + middle_emulation enabled +} + +input type:keyboard { + xkb_layout "gb" +} +# +# You can also configure each device individually. +# Read `man 5 sway-input` for more information about this section. + +### Key bindings +# +# Basics: +# + # Start a terminal + bindsym $mod+Return exec $term + + # Kill focused window + bindsym $mod+Shift+q kill + + # Start your launcher + bindsym $mod+d exec $menu + + # Drag floating windows by holding down $mod and left mouse button. + # Resize them with right mouse button + $mod. + # Despite the name, also works for non-floating windows. + # Change normal to inverse to use left mouse button for resizing and right + # mouse button for dragging. + floating_modifier $mod normal + + # Reload the configuration file + bindsym $mod+Shift+c reload + + # Exit sway (logs you out of your Wayland session) + bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit' +# +# Moving around: +# + # Move your focus around + bindsym $mod+$left focus left + bindsym $mod+$down focus down + bindsym $mod+$up focus up + bindsym $mod+$right focus right + # Or use $mod+[up|down|left|right] + bindsym $mod+Left focus left + bindsym $mod+Down focus down + bindsym $mod+Up focus up + bindsym $mod+Right focus right + + # Move the focused window with the same, but add Shift + bindsym $mod+Shift+$left move left + bindsym $mod+Shift+$down move down + bindsym $mod+Shift+$up move up + bindsym $mod+Shift+$right move right + # Ditto, with arrow keys + bindsym $mod+Shift+Left move left + bindsym $mod+Shift+Down move down + bindsym $mod+Shift+Up move up + bindsym $mod+Shift+Right move right +# +# Workspaces: +# + # Switch to workspace + bindsym $mod+1 workspace number 1 + bindsym $mod+2 workspace number 2 + bindsym $mod+3 workspace number 3 + bindsym $mod+4 workspace number 4 + bindsym $mod+5 workspace number 5 + bindsym $mod+6 workspace number 6 + bindsym $mod+7 workspace number 7 + bindsym $mod+8 workspace number 8 + bindsym $mod+9 workspace number 9 + bindsym $mod+0 workspace number 10 + # Move focused container to workspace + bindsym $mod+Shift+1 move container to workspace number 1 + bindsym $mod+Shift+2 move container to workspace number 2 + bindsym $mod+Shift+3 move container to workspace number 3 + bindsym $mod+Shift+4 move container to workspace number 4 + bindsym $mod+Shift+5 move container to workspace number 5 + bindsym $mod+Shift+6 move container to workspace number 6 + bindsym $mod+Shift+7 move container to workspace number 7 + bindsym $mod+Shift+8 move container to workspace number 8 + bindsym $mod+Shift+9 move container to workspace number 9 + bindsym $mod+Shift+0 move container to workspace number 10 + # Note: workspaces can have any name you want, not just numbers. + # We just use 1-10 as the default. +# +# Layout stuff: +# + # You can "split" the current object of your focus with + # $mod+b or $mod+v, for horizontal and vertical splits + # respectively. + bindsym $mod+b splith + bindsym $mod+v splitv + + # Switch the current container between different layout styles + bindsym $mod+s layout stacking + bindsym $mod+w layout tabbed + bindsym $mod+e layout toggle split + + # Make the current focus fullscreen + bindsym $mod+f fullscreen + + # Toggle the current focus between tiling and floating mode + bindsym $mod+Shift+space floating toggle + + # Swap focus between the tiling area and the floating area + bindsym $mod+space focus mode_toggle + + # Move focus to the parent container + bindsym $mod+a focus parent +# +# Scratchpad: +# + # Sway has a "scratchpad", which is a bag of holding for windows. + # You can send windows there and get them back later. + + # Move the currently focused window to the scratchpad + bindsym $mod+Shift+minus move scratchpad + + # Show the next scratchpad window or hide the focused scratchpad window. + # If there are multiple scratchpad windows, this command cycles through them. + bindsym $mod+minus scratchpad show +# +# Resizing containers: +# +mode "resize" { + # left will shrink the containers width + # right will grow the containers width + # up will shrink the containers height + # down will grow the containers height + bindsym $left resize shrink width 10px + bindsym $down resize grow height 10px + bindsym $up resize shrink height 10px + bindsym $right resize grow width 10px + + # Ditto, with arrow keys + bindsym Left resize shrink width 10px + bindsym Down resize grow height 10px + bindsym Up resize shrink height 10px + bindsym Right resize grow width 10px + + # Return to default mode + bindsym Return mode "default" + bindsym Escape mode "default" +} +bindsym $mod+r mode "resize" +# +# Utilities: +# + # Special keys to adjust volume via PulseAudio + bindsym --locked XF86AudioMute exec pactl set-sink-mute \@DEFAULT_SINK@ toggle + bindsym --locked XF86AudioLowerVolume exec pactl set-sink-volume \@DEFAULT_SINK@ -5% + bindsym --locked XF86AudioRaiseVolume exec pactl set-sink-volume \@DEFAULT_SINK@ +5% + bindsym --locked XF86AudioMicMute exec pactl set-source-mute \@DEFAULT_SOURCE@ toggle + # Special keys to adjust brightness via brightnessctl + bindsym --locked XF86MonBrightnessDown exec brightnessctl set 5%- + bindsym --locked XF86MonBrightnessUp exec brightnessctl set 5%+ + # Special key to take a screenshot with grim + bindsym Print exec grim + +# +# Status Bar: +# +# Read `man 5 sway-bar` for more information about this section. +bar { +# position top +# +# # When the status_command prints a new line to stdout, swaybar updates. +# # The default just shows the current date and time. +# status_command while date +'%Y-%m-%d %X'; do sleep 1; done +# +# colors { +# statusline #ffffff +# background #323232 +# inactive_workspace #32323200 #32323200 #5c5c5c +# } + swaybar_command waybar +} + +exec gentoo-pipewire-launcher restart & + +exec_always nm-applet --indicator + +exec_always --no-startup-id source ~/.config/sway/env + +exec mako + +exec_always blueman-applet + +# Start gnome-keyring +exec /usr/bin/gnome-keyring-daemon --start --components=pkcs11,secrets,ssh + +# Update DBus environment +exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY DISPLAY XAUTHORITY + +include /etc/sway/config.d/* diff --git a/.config/sway/env b/.config/sway/env new file mode 100644 index 0000000..329ffae --- /dev/null +++ b/.config/sway/env @@ -0,0 +1,6 @@ +# If no session bus is defined, launch one +if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then + eval $(dbus-launch --sh-syntax) + export DBUS_SESSION_BUS_ADDRESS + export DBUS_SESSION_BUS_PID +fi diff --git a/.config/waybar/config.jsonc b/.config/waybar/config.jsonc new file mode 100644 index 0000000..66654ce --- /dev/null +++ b/.config/waybar/config.jsonc @@ -0,0 +1,71 @@ +{ + "layer": "top", // Waybar at top layer + "position": "top", // Waybar position (top|bottom|left|right) + // "width": 1280, // Waybar width + // Choose the order of the modules + "modules-left": ["sway/workspaces"], + "modules-center": ["custom/music"], + "modules-right": ["wireplumber", "backlight", "battery", "clock", "tray", "custom/lock", "custom/power"], + "sway/workspaces": { + "disable-scroll": true, + "sort-by-name": true, + "format": " {icon} ", + "format-icons": { + "default": " ", + }, + }, + "tray": { + "icon-size": 21, + "spacing": 10 + }, + "custom/music": { + "format": " {}", + "escape": true, + "interval": 5, + "tooltip": false, + "exec": "playerctl metadata --format='{{ title }} | {{ artist }}'", + "on-click": "playerctl play-pause", + "max-length": 50 + }, + "clock": { + "timezone": "Europe/London", + "tooltip-format": "{:%Y %B}\n{calendar}", + "format-alt": " {:%d/%m/%Y}", + "format": " {:%H:%M}" + }, + "backlight": { + "device": "intel_backlight", + "format": "{icon}", + "format-icons": ["", "", "", "", "", "", "", "", ""] + }, + "battery": { + "states": { + "warning": 30, + "critical": 15 + }, + "format": "{icon} {capacity}%", + "format-charging": "󰂄 {capacity}%", + "format-plugged": "󰂄 {capacity}%", + "format-alt": "{icon} {capacity}%", + "format-icons": ["", "", "", "", ""] + }, + "wireplumber": { + // "scroll-step": 1, // %, can be a float + "format": "{icon} {volume}%", + "format-muted": "", + "format-icons": { + "default": ["", "", " "] + }, + "on-click": "pavucontrol" + }, + "custom/lock": { + "tooltip": false, + "on-click": "sh -c '(sleep 0.5s; swaylock --grace 0)' & disown", + "format": "", + }, + "custom/power": { + "tooltip": false, + "on-click": "swaymsg exit &", + "format": "⏻ " + } +} diff --git a/.config/waybar/mocha.css b/.config/waybar/mocha.css new file mode 100644 index 0000000..0eb6a82 --- /dev/null +++ b/.config/waybar/mocha.css @@ -0,0 +1,26 @@ +@define-color rosewater #f5e0dc; +@define-color flamingo #f2cdcd; +@define-color pink #f5c2e7; +@define-color mauve #cba6f7; +@define-color red #f38ba8; +@define-color maroon #eba0ac; +@define-color peach #fab387; +@define-color yellow #f9e2af; +@define-color green #a6e3a1; +@define-color teal #94e2d5; +@define-color sky #89dceb; +@define-color sapphire #74c7ec; +@define-color blue #89b4fa; +@define-color lavender #b4befe; +@define-color text #cdd6f4; +@define-color subtext1 #bac2de; +@define-color subtext0 #a6adc8; +@define-color overlay2 #9399b2; +@define-color overlay1 #7f849c; +@define-color overlay0 #6c7086; +@define-color surface2 #585b70; +@define-color surface1 #45475a; +@define-color surface0 #313244; +@define-color base #1e1e2e; +@define-color mantle #181825; +@define-color crust #11111b; diff --git a/.config/waybar/style.css b/.config/waybar/style.css new file mode 100644 index 0000000..29525ee --- /dev/null +++ b/.config/waybar/style.css @@ -0,0 +1,102 @@ +@import "mocha.css"; + +* { + font-family: FantasqueSansM Nerd Font; + font-size: 17px; + min-height: 0; +} + +#waybar { + background: transparent; + color: @text; + margin: 5px 5px; +} + +#workspaces { + border-radius: 1rem; + margin: 5px; + background-color: @surface0; + margin-left: 1rem; +} + +#workspaces button { + color: @lavender; + border-radius: 1rem; + padding: 0.4rem; +} + +#workspaces button.active { + color: @sky; + border-radius: 1rem; +} + +#workspaces button:hover { + color: @sapphire; + border-radius: 1rem; +} + +#custom-music, +#tray, +#backlight, +#clock, +#battery, +#wireplumber, +#custom-lock, +#custom-power { + background-color: @surface0; + padding: 0.5rem 1rem; + margin: 5px 0; +} + +#clock { + color: @blue; + border-radius: 0px 1rem 1rem 0px; + margin-right: 1rem; +} + +#battery { + color: @green; +} + +#battery.charging { + color: @green; +} + +#battery.warning:not(.charging) { + color: @red; +} + +#backlight { + color: @yellow; +} + +#backlight, #battery { + border-radius: 0; +} + +#wireplumber { + color: @maroon; + border-radius: 1rem 0px 0px 1rem; + margin-left: 1rem; +} + +#custom-music { + color: @mauve; + border-radius: 1rem; +} + +#custom-lock { + border-radius: 1rem 0px 0px 1rem; + color: @lavender; +} + +#custom-power { + margin-right: 1rem; + border-radius: 0px 1rem 1rem 0px; + color: @red; +} + +#tray { + margin-right: 1rem; + border-radius: 1rem; +} -- cgit