Fix qtile config: consolidate terminal variable and remove unused imports
This commit is contained in:
@@ -1,15 +1,12 @@
|
||||
from libqtile import bar, extension, hook, layout, qtile, widget
|
||||
from libqtile.config import Click, Drag, Group, Key, KeyChord, Match, Screen
|
||||
from libqtile import bar, hook, layout, qtile, widget
|
||||
from libqtile.config import Click, Drag, Group, Key, Match, Screen
|
||||
from libqtile.lazy import lazy
|
||||
from libqtile.utils import guess_terminal
|
||||
import os
|
||||
import subprocess
|
||||
|
||||
|
||||
mod = "mod4"
|
||||
terminal = guess_terminal()
|
||||
|
||||
myTerm = "alacritty"
|
||||
terminal = "alacritty"
|
||||
|
||||
keys = [
|
||||
Key([mod], "h", lazy.layout.left(), desc="Move focus to left"),
|
||||
@@ -221,14 +218,14 @@ def make_top_bar(primary=False):
|
||||
widget.CPU(
|
||||
foreground = colors[4],
|
||||
padding = 8,
|
||||
mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(myTerm + ' -e btop')},
|
||||
mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(terminal + ' -e btop')},
|
||||
format="CPU: {load_percent}%",
|
||||
),
|
||||
make_sep(),
|
||||
widget.Memory(
|
||||
foreground = colors[8],
|
||||
padding = 8,
|
||||
mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(myTerm + ' -e btop')},
|
||||
mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(terminal + ' -e btop')},
|
||||
format = 'Mem: {MemUsed:.0f}{mm}',
|
||||
),
|
||||
make_sep(),
|
||||
|
||||
Reference in New Issue
Block a user