file get_updated

This commit is contained in:
2026-06-12 08:05:48 +02:00
parent 84f901a083
commit 71b8cf5ceb
66 changed files with 2916 additions and 0 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+11
View File
@@ -0,0 +1,11 @@
import os
import json
# Gets colors from wallust wallpaper
def get_colors():
with open(f"{os.path.expanduser('~')}/.cache/qtile/colors.json") as f:
colors = json.load(f)
return colors['colors']
colors = get_colors()
+19
View File
@@ -0,0 +1,19 @@
from libqtile.config import Group
# Create labels for groups and assign them a default layout.
groups = []
group_names = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "minus", "equal", "y", "u"]
group_labels = ["", "", "", "", "", "", "", "", "", "", "", "", "", ""]
group_layouts = ["monadtall", "monadtall", "spiral", "monadtall", "monadwide", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall", "monadtall"]
# Add group names, labels, and default layouts to the groups object.
for i in range(len(group_names)):
groups.append(
Group(
name=group_names[i],
layout=group_layouts[i].lower(),
label=group_labels[i],
))
+16
View File
@@ -0,0 +1,16 @@
import os
import subprocess
from libqtile import hook, qtile
# Startup applications
@hook.subscribe.startup_once
def autostart():
if qtile.core.name == "x11":
autostartscript = "~/.config/qtile/scripts/x11-autostart.sh"
elif qtile.core.name == "wayland":
autostartscript = "~/.config/qtile/scripts/wayland-autostart.sh"
home = os.path.expanduser(autostartscript)
subprocess.Popen([home])
+233
View File
@@ -0,0 +1,233 @@
from libqtile import qtile
from libqtile.config import Click, Drag, Key
from libqtile.lazy import lazy
from .groups import groups
mod = "mod4"
terminal = "ghostty"
keys = [
# Open terminal
Key([mod], "Return", lazy.spawn(terminal),
desc="Launch terminal"),
# Qtile System Actions
Key([mod, "shift"], "q", lazy.shutdown(),
desc="Shutdown Qtile"),
# Active Window Actions
Key([mod], "f", lazy.window.toggle_fullscreen(),
desc="Toggle window fullscreen"),
Key([mod], "q", lazy.window.kill(),
desc="Close active window"),
Key([mod, "control"], "l",
lazy.layout.grow_right(),
lazy.layout.grow(),
lazy.layout.increase_ratio(),
lazy.layout.delete(),
desc="Increase active window size."
),
Key([mod, "control"], "Right",
lazy.layout.grow_right(),
lazy.layout.grow(),
lazy.layout.increase_ratio(),
lazy.layout.delete(),
desc="Increase active window size."
),
Key([mod, "control"], "h",
lazy.layout.grow_left(),
lazy.layout.shrink(),
lazy.layout.decrease_ratio(),
lazy.layout.add(),
desc="Decrease active window size."
),
Key([mod, "control"], "Left",
lazy.layout.grow_left(),
lazy.layout.shrink(),
lazy.layout.decrease_ratio(),
lazy.layout.add(),
desc="Decrease active window size."
),
Key([mod, "control"], "k",
lazy.layout.grow_up(),
lazy.layout.grow(),
lazy.layout.decrease_nmaster(),
desc="Increase active window size."
),
Key([mod, "control"], "Up",
lazy.layout.grow_up(),
lazy.layout.grow(),
lazy.layout.decrease_nmaster(),
desc="Increase active window size."
),
Key([mod, "control"], "j",
lazy.layout.grow_down(),
lazy.layout.shrink(),
lazy.layout.increase_nmaster(),
desc="Decrease active window size."
),
Key([mod, "control"], "Down",
lazy.layout.grow_down(),
lazy.layout.shrink(),
lazy.layout.increase_nmaster(),
desc="Decrease active window size."
),
# Window Focus (Arrows and Vim keys)
Key([mod], "Up", lazy.layout.up(),
desc="Change focus to window above."),
Key([mod], "Down", lazy.layout.down(),
desc="Change focus to window below."),
Key([mod], "Left", lazy.layout.left(),
desc="Change focus to window on the left."),
Key([mod], "Right", lazy.layout.right(),
desc="Change focus to window on the right."),
Key([mod], "k", lazy.layout.up(),
desc="Change focus to window above."),
Key([mod], "j", lazy.layout.down(),
desc="Change focus to window below."),
Key([mod], "h", lazy.layout.left(),
desc="Change focus to window on the left."),
Key([mod], "l", lazy.layout.right(),
desc="Change focus to window on the right."),
# Move windows around MonadTall/MonadWide Layouts
Key([mod, "shift"], "Up", lazy.layout.shuffle_up(),
desc="Shuffle window up."),
Key([mod, "shift"], "Down", lazy.layout.shuffle_down(),
desc="Shuffle window down."),
Key([mod, "shift"], "Left", lazy.layout.swap_left(),
desc="Shuffle window left."),
Key([mod, "shift"], "Right", lazy.layout.swap_right(),
desc="Shuffle window right."),
Key([mod, "shift"], "k", lazy.layout.shuffle_up(),
desc="Shuffle window up."),
Key([mod, "shift"], "j", lazy.layout.shuffle_down(),
desc="Shuffle window down."),
Key([mod, "shift"], "h", lazy.layout.swap_left(),
desc="Shuffle window left."),
Key([mod, "shift"], "l", lazy.layout.swap_right(),
desc="Shuffle window right."),
# Qtile Layout Actions
Key([mod], "r", lazy.layout.reset(),
desc="Reset the sizes of all window in group."),
Key([mod], "Tab", lazy.next_layout(),
desc="Switch to the next layout."),
Key([mod, "shift"], "f", lazy.layout.flip(),
desc="Flip layout for Monadtall/Monadwide"),
Key([mod, "shift"], "space", lazy.window.toggle_floating(),
desc="Toggle floating window."),
# Switch focus to specific monitor (out of three)
Key([mod], "i",
lazy.to_screen(0),
desc='Keyboard focus to monitor 1'),
Key([mod], "o",
lazy.to_screen(1),
desc='Keyboard focus to monitor 2'),
Key([mod], "p",
lazy.to_screen(2),
desc='Keyboard focus to monitor 3'),
# Switch focus of monitors
Key([mod], "period",
lazy.next_screen(),
desc='Move focus to next monitor'),
Key([mod], "comma",
lazy.prev_screen(),
desc='Move focus to prev monitor'),
]
# Add group specific keybindings
for i in groups:
keys.extend([
Key([mod], i.name, lazy.group[i.name].toscreen(),
desc="Mod + number to move to that group."),
Key(["mod1"], "Tab", lazy.screen.next_group(),
desc="Move to next group."),
Key(["mod1", "shift"], "Tab", lazy.screen.prev_group(),
desc="Move to previous group."),
Key([mod, "shift"], i.name, lazy.window.togroup(i.name),
desc="Move focused window to new group."),
])
# Scratchpad keybindings
keys.extend([
Key(["mod1"], "Return", lazy.group['scratchpad'].dropdown_toggle('term')),
Key(["mod1"], "v", lazy.group['scratchpad'].dropdown_toggle('volume')),
Key([mod], "a", lazy.group['scratchpad'].dropdown_toggle('angular')),
Key([mod], "n", lazy.group['scratchpad'].dropdown_toggle('notebook')),
])
# Drag floating layouts.
mouse = [
Drag([mod], "Button1", lazy.window.set_position_floating(),
start=lazy.window.get_position()),
Drag([mod], "Button3", lazy.window.set_size_floating(),
start=lazy.window.get_size()),
Click([mod], "Button2", lazy.window.bring_to_front())
]
# Application keybindings
keys.extend([
Key([mod, "shift"], "Return", lazy.spawn("ghostty"),
desc="Launch file browser"),
Key([mod], "Space", lazy.spawn("rofi -show drun"),
desc="Application launcher"),
Key([mod], "b", lazy.spawn("firefox"),
desc="Launch web browser"),
Key([mod], "e", lazy.spawn("nautilus"),
desc="Launch file browser"),
# Media Keys
Key([], "XF86AudioRaiseVolume", lazy.spawn("wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.03+"),
desc="Volume Up"),
Key([], "XF86AudioLowerVolume", lazy.spawn("wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.03-"),
desc="Volume Down"),
Key([], "XF86AudioMute", lazy.spawn("wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"),
desc="Toggle Mute"),
Key([], "XF86AudioPlay", lazy.spawn("playerctl play-pause"),
desc="Play/Pause"),
Key([], "XF86AudioNext", lazy.spawn("playerctl next"),
desc="Next Song"),
Key([], "XF86AudioPrev", lazy.spawn("playerctl previous"),
desc="Previous Song"),
Key([], "XF86AudioStop", lazy.spawn("playerctl stop"),
desc="Stop music"),
Key([], "XF86MonBrightnessUp", lazy.spawn("brightnessctl set 5%+"),
desc="Increase brightness"),
Key([], "XF86MonBrightnessDown", lazy.spawn("brightnessctl set 5%-"),
desc="Decrease brightness"),
])
# Add X11-specific keybindings
if qtile.core.name == "x11":
keys.extend([
Key([mod, "shift"], "r", lazy.restart(),
desc="Restart Qtile"),
Key([mod], "Escape", lazy.spawn("betterlockscreen -l"),
desc="Lock screen"),
Key([mod], "v", lazy.spawn("~/.config/qtile/scripts/greenclip.sh"),
desc="Clipboard Manager"),
Key([], "XF86TouchpadToggle", lazy.spawn("/home/wingej0/dotfiles/scripts/touchpad-toggle.sh"),
desc="Toggle Touchpad"),
])
# Add Wayland-specific keybindings
elif qtile.core.name == "wayland":
keys.extend([
Key([mod, "shift"], "r", lazy.reload_config(),
desc="Reload Qtile config"),
Key([mod], "Escape", lazy.spawn("swaylock"),
desc="Lock screen"),
Key(["control", "mod1"], "delete", lazy.spawn("wlogout"),
desc="Launch powermenu"),
Key([mod], "v", lazy.spawn("~/.config/qtile/scripts/clipboard.sh"),
desc="Clipboard Manager"),
Key([mod], "print", lazy.spawn("~/.config/qtile/scripts/gif-recorder.sh"),
desc="Gif Recorder")
])
+49
View File
@@ -0,0 +1,49 @@
from .get_theme import colors
from libqtile import layout
from libqtile.config import Match
# Define layouts and layout themes
layout_theme = {
"margin":8,
"border_width": 4,
"border_focus": colors['color11'],
"border_normal": colors['color0'],
}
layouts = [
layout.Bsp(**layout_theme),
layout.MonadTall(**layout_theme),
layout.MonadWide(**layout_theme),
layout.RatioTile(**layout_theme),
layout.MonadThreeCol(**layout_theme),
layout.Tile(**layout_theme),
layout.Floating(**layout_theme),
layout.Max(**layout_theme),
layout.TreeTab(**layout_theme),
layout.Spiral(
main_pane_ratio = 0.70,
ratio = 0.52,
new_client_position = "bottom",
**layout_theme
)
]
floating_layout = layout.Floating(
float_rules=[
# Run the utility of `xprop` to see the wm class and name of an X client.
*layout.Floating.default_float_rules,
Match(wm_class="confirmreset"), # gitk
Match(wm_class="makebranch"), # gitk
Match(wm_class="maketag"), # gitk
Match(wm_class="ssh-askpass"), # ssh-askpass
Match(title="branchdialog"), # gitk
Match(title="pinentry"), # GPG key password entry
Match(title="Mailspring"),
Match(func=lambda c: c.is_transient_for()),
],
fullscreen_border_width = 0,
border_width = 4,
border_focus = colors['color11'],
border_normal = colors['color1']
)
+11
View File
@@ -0,0 +1,11 @@
from .groups import groups
from libqtile.config import ScratchPad, DropDown
# Define Scratchpads
groups.append(ScratchPad("scratchpad", [
DropDown("term", "kitty", width=0.8, height=0.8, x=0.1, y=0.1, opacity=1),
DropDown("volume", "pavucontrol", width=0.8, height=0.8, x=0.1, y=0.1, opacity=0.8),
DropDown("angular", "kitty", width=0.8, height=0.8, x=0.1, y=0.1, opacity=1),
DropDown("notebook", "kitty", width=0.8, height=0.8, x=0.1, y=0.1, opacity=1),
]))
+43
View File
@@ -0,0 +1,43 @@
from .widgets import init_widgets
from libqtile import bar
from libqtile.config import Screen
screens = [
# HDMI-A-1
Screen(
top=bar.Bar(
widgets=init_widgets(1),
background='#0000003f',
margin=0,
size=30,
opacity=0.9
),
x=0
),
# DP-1
Screen(
top=bar.Bar(
widgets=init_widgets(1),
background='#0000003f',
margin=0,
size=30,
opacity=0.9
),
x=1920
),
# DP-2
Screen(
top=bar.Bar(
widgets=init_widgets(1),
background='#0000003f',
margin=0,
size=30,
opacity=0.9
),
x=3840
),
]
+6
View File
@@ -0,0 +1,6 @@
# Define Widgets
widget_defaults = dict(
font="Fira Code Nerd Font",
fontsize = 11,
)
+392
View File
@@ -0,0 +1,392 @@
import os
import subprocess
from libqtile import qtile
from libqtile.lazy import lazy
from qtile_extras import widget
from qtile_extras.widget.decorations import RectDecoration
from .get_theme import colors
from .widget_defaults import widget_defaults
dark_widgets = {
"decorations" : [
RectDecoration(
colour = colors['color11'],
filled = True,
radius = 10,
padding_y = 4,
group = True
)
]
}
light_widgets = {
"decorations" : [
RectDecoration(
colour = colors['color15'],
filled = True,
radius = 10,
padding_y = 4,
group = True
)
]
}
mid_widgets = {
"decorations" : [
RectDecoration(
colour = colors['color1'],
filled = True,
radius = 10,
padding_y = 4,
group = True
)
]
}
def init_widgets(monitor):
widgets_list = [
widget.Sep(
linewidth = 0,
padding = 5
),
widget.Sep(
linewidth = 0,
padding = 10,
**dark_widgets
),
widget.TextBox(
font="FontAwesome6Free",
fontsize=14,
foreground=colors['color15'],
text="",
**dark_widgets
),
# qtile button
widget.TextBox(
font="Fira Code Nerd Font Bold",
fontsize = 12,
foreground=colors['color15'],
text="Qtile",
mouse_callbacks={
'Button1' : lazy.spawn('rofi -show drun'),
},
**dark_widgets
),
# separators with curved sections
widget.Sep(
linewidth = 0,
padding = 10,
**dark_widgets
),
widget.Sep(
linewidth = 0,
padding = 10,
),
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
# memory icon
widget.TextBox(
text='',
font="FontAwesome6Free",
fontsize=12,
foreground=colors['color0'],
margin=0,
padding=5,
**light_widgets
),
# memory percentage
widget.Memory(
foreground=colors['color0'],
format='{MemPercent}%',
measure_mem="M",
margin=0,
padding=0,
**widget_defaults,
**light_widgets
),
# separator
widget.Sep(
foreground=colors['color0'],
padding=10,
size_percent=60,
**light_widgets
),
# cpu icon
widget.TextBox(
text='',
font="FontAwesome6Free",
fontsize=12,
foreground=colors['color0'],
margin=0,
padding=5,
**light_widgets
),
# cpu percentage
widget.CPU(
foreground=colors['color0'],
format='{load_percent}%',
margin=0,
padding=0,
**widget_defaults,
**light_widgets
),
# separator
widget.Sep(
foreground=colors['color0'],
padding=10,
size_percent=60,
**light_widgets
),
# temperature icon
widget.TextBox(
text='',
font="FontAwesome6Free",
fontsize=12,
foreground=colors['color0'],
padding=5,
**light_widgets
),
# thermal sensor
widget.ThermalSensor(
foreground=colors['color0'],
**widget_defaults,
**light_widgets
),
# separators to close module and open next
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
widget.Sep(
linewidth = 0,
padding = 10
),
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
# sun icon
widget.TextBox(
text='',
font="FontAwesome6Free",
fontsize=12,
foreground=colors['color0'],
**light_widgets
),
# brightness percentage
widget.GenPollText(
foreground=colors['color0'],
func=lambda: subprocess.check_output(f"{os.path.expanduser('~')}/.config/qtile/scripts/brightness.sh").decode("utf-8").strip(),
update_interval=30,
**widget_defaults,
**light_widgets
),
# separator
widget.Sep(
foreground=colors['color0'],
padding=10,
size_percent=60,
**light_widgets
),
# audio icon
widget.TextBox(
font="FontAwesome6Free",
fontsize=12,
foreground=colors['color0'],
text="",
**light_widgets
),
# volume percentage
widget.Volume(
foreground=colors['color0'],
get_volume_command = f"{os.path.expanduser('~')}/.config/qtile/scripts/volume.sh",
**widget_defaults,
**light_widgets
),
# close module, separator, open next module
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
widget.Sep(
linewidth = 0,
padding = 10
),
widget.Sep(
linewidth = 0,
padding = 10,
**mid_widgets
),
# current layout icon
widget.CurrentLayoutIcon(
foreground=colors['color15'],
scale=0.50,
**mid_widgets
),
# current layout
widget.CurrentLayout(
foreground=colors['color15'],
**widget_defaults,
**mid_widgets
),
# separators
widget.Sep(
linewidth = 0,
padding = 10,
**mid_widgets
),
widget.Sep(
linewidth = 0,
padding = 10
),
# groups/workspaces
widget.GroupBox(
active=colors['color15'],
borderwidth = 2,
foreground=colors['color15'],
disable_drag=True,
font="FontAwesome6Free",
fontsize=11,
hide_unused=False,
highlight_color=['#00000000', '#00000000'],
highlight_method="line",
inactive=colors['color0'],
this_current_screen_border=colors['color0'],
this_screen_border=colors['color15'],
other_current_screen_border=colors['color1'],
other_screen_border=colors['color0'],
urgent_method = "line",
use_mouse_wheel=False,
**dark_widgets
),
# separator
widget.Sep(
linewidth = 0,
padding = 10,
**dark_widgets
),
widget.Sep(
linewidth = 0,
padding = 10
),
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
# browser
widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn("firefox --new-window"),
},
**light_widgets
),
# filebrowser
widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn('nautilus'),
},
**light_widgets
),
widget.Sep(
linewidth = 0,
padding = 10,
**light_widgets
),
widget.Sep(
linewidth = 0,
padding = 10
),
widget.Sep(
linewidth = 0,
padding = 10,
**dark_widgets
),
widget.Clock(
foreground=colors['color15'],
font="Fira Code Nerd Font Bold",
fontsize=12,
format=' %b %d | %I:%M %p',
mouse_callbacks={
'Button1' : lazy.spawn('wlogout'),
},
**dark_widgets
),
widget.Sep(
linewidth = 0,
padding = 15,
**dark_widgets
),
widget.Sep(
linewidth = 0,
padding = 5
),
]
if qtile.core.name == "x11":
clipboard = widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn(f"{os.path.expanduser('~')}/.config/qtile/scripts/greenclip.sh"),
},
**light_widgets
)
screenshot = widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn('flameshot launcher'),
},
**light_widgets
)
elif qtile.core.name == "wayland":
clipboard = widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn(f"{os.path.expanduser('~')}/.config/qtile/scripts/clipboard.sh"),
},
**light_widgets
)
screenshot = widget.TextBox(
foreground=colors['color0'],
font="FontAwesome6Free",
fontsize=12,
text='',
mouse_callbacks={
'Button1' : lazy.spawn(f"{os.path.expanduser('~')}/.config/qtile/scripts/grim.sh"),
},
**light_widgets
)
#widgets_list.insert(50, clipboard)
#widgets_list.insert(51, screenshot)
return widgets_list