mirror of
https://github.com/The-Repo-Club/DotFiles.git
synced 2025-02-17 18:03:23 -05:00
Update Qtile
Signed-off-by: The-Repo-Club <wayne6324@gmail.com>
This commit is contained in:
parent
7c1fbc918e
commit
ba3103220d
@ -267,6 +267,8 @@ screens = [
|
|||||||
Widgets.space,
|
Widgets.space,
|
||||||
Widgets.picom,
|
Widgets.picom,
|
||||||
Widgets.sep,
|
Widgets.sep,
|
||||||
|
Widgets.github1,
|
||||||
|
Widgets.sep,
|
||||||
Widgets.chords,
|
Widgets.chords,
|
||||||
],
|
],
|
||||||
24,
|
24,
|
||||||
@ -314,6 +316,11 @@ screens = [
|
|||||||
[
|
[
|
||||||
Widgets.weather,
|
Widgets.weather,
|
||||||
Widgets.sep,
|
Widgets.sep,
|
||||||
|
Widgets.space,
|
||||||
|
Widgets.picom,
|
||||||
|
Widgets.sep,
|
||||||
|
Widgets.github2,
|
||||||
|
Widgets.sep,
|
||||||
Widgets.chords,
|
Widgets.chords,
|
||||||
],
|
],
|
||||||
24,
|
24,
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
from libqtile.config import Group, Match
|
from libqtile.config import Group, Match
|
||||||
|
|
||||||
|
|
||||||
class Groups(object):
|
class Groups(object):
|
||||||
groups = [
|
groups = [
|
||||||
# first group that hold the terminals
|
# first group that hold the terminals
|
||||||
@ -7,7 +8,7 @@ class Groups(object):
|
|||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
persist=False,
|
persist=True,
|
||||||
matches=[Match(wm_class=['Alacritty', 'kitty'])],
|
matches=[Match(wm_class=['Alacritty', 'kitty'])],
|
||||||
position=1,
|
position=1,
|
||||||
screen_affinity=1,
|
screen_affinity=1,
|
||||||
@ -17,7 +18,7 @@ class Groups(object):
|
|||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
persist=False,
|
persist=True,
|
||||||
matches=[Match(wm_class=['Code'])],
|
matches=[Match(wm_class=['Code'])],
|
||||||
position=2,
|
position=2,
|
||||||
screen_affinity=1,
|
screen_affinity=1,
|
||||||
@ -27,7 +28,7 @@ class Groups(object):
|
|||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
persist=False,
|
persist=True,
|
||||||
matches=[Match(wm_class=['Nemo'])],
|
matches=[Match(wm_class=['Nemo'])],
|
||||||
position=3,
|
position=3,
|
||||||
screen_affinity=1,
|
screen_affinity=1,
|
||||||
@ -37,8 +38,8 @@ class Groups(object):
|
|||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
persist=False,
|
persist=True,
|
||||||
matches=[Match(wm_class=['Nemo'])],
|
# matches=[Match(wm_class=['Nemo'])],
|
||||||
position=4,
|
position=4,
|
||||||
screen_affinity=1,
|
screen_affinity=1,
|
||||||
name='4',
|
name='4',
|
||||||
@ -47,8 +48,8 @@ class Groups(object):
|
|||||||
# label='ﱘ',
|
# label='ﱘ',
|
||||||
init=True,
|
init=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
persist=False,
|
persist=True,
|
||||||
matches=[Match(wm_class=['Nemo'])],
|
# matches=[Match(wm_class=['Nemo'])],
|
||||||
position=5,
|
position=5,
|
||||||
screen_affinity=1,
|
screen_affinity=1,
|
||||||
name='5',
|
name='5',
|
||||||
@ -56,7 +57,7 @@ class Groups(object):
|
|||||||
Group(
|
Group(
|
||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
persist=False,
|
persist=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
matches=[Match(wm_class=['firefox'], role=['browser'])],
|
matches=[Match(wm_class=['firefox'], role=['browser'])],
|
||||||
position=6,
|
position=6,
|
||||||
@ -66,7 +67,7 @@ class Groups(object):
|
|||||||
Group(
|
Group(
|
||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
persist=False,
|
persist=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
# matches=[Match(wm_class=['firefox'])],
|
# matches=[Match(wm_class=['firefox'])],
|
||||||
position=7,
|
position=7,
|
||||||
@ -76,9 +77,9 @@ class Groups(object):
|
|||||||
Group(
|
Group(
|
||||||
# label='調',
|
# label='調',
|
||||||
init=True,
|
init=True,
|
||||||
persist=False,
|
persist=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
# matches=[Match(wm_class=['firefox'])],
|
matches=[Match(wm_class=['Steam'])],
|
||||||
position=8,
|
position=8,
|
||||||
screen_affinity=2,
|
screen_affinity=2,
|
||||||
name='8',
|
name='8',
|
||||||
@ -86,9 +87,9 @@ class Groups(object):
|
|||||||
Group(
|
Group(
|
||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
persist=False,
|
persist=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
# matches=[Match(wm_class=['firefox'])],
|
matches=[Match(wm_class=['discord'])],
|
||||||
position=9,
|
position=9,
|
||||||
screen_affinity=2,
|
screen_affinity=2,
|
||||||
name='9',
|
name='9',
|
||||||
@ -96,7 +97,7 @@ class Groups(object):
|
|||||||
Group(
|
Group(
|
||||||
# label='',
|
# label='',
|
||||||
init=True,
|
init=True,
|
||||||
persist=False,
|
persist=True,
|
||||||
exclusive=False,
|
exclusive=False,
|
||||||
matches=[Match(wm_class=['PkgBrowser'])],
|
matches=[Match(wm_class=['PkgBrowser'])],
|
||||||
position=10,
|
position=10,
|
||||||
|
13
qtile/.config/qtile/scripts/picom-toggle.sh
Executable file
13
qtile/.config/qtile/scripts/picom-toggle.sh
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# https://github.com/jaagr/polybar/wiki/User-contributed-modules
|
||||||
|
|
||||||
|
#The command for starting compton
|
||||||
|
#always keep the -b argument!
|
||||||
|
|
||||||
|
if pgrep -x "picom" > /dev/null
|
||||||
|
then
|
||||||
|
killall picom
|
||||||
|
else
|
||||||
|
picom -CGb --experimental-backend --config ~/.config/i3/picom.conf
|
||||||
|
fi
|
11
qtile/.config/qtile/scripts/picom.sh
Executable file
11
qtile/.config/qtile/scripts/picom.sh
Executable file
@ -0,0 +1,11 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# https://github.com/jaagr/polybar/wiki/User-contributed-modules
|
||||||
|
|
||||||
|
#The icon that would change color
|
||||||
|
if pgrep -x "picom" > /dev/null
|
||||||
|
then
|
||||||
|
echo -n "Loaded"
|
||||||
|
else
|
||||||
|
echo -n "UnLoaded"
|
||||||
|
fi
|
@ -1,6 +1,7 @@
|
|||||||
from colors import colorScheme, foregroundColor, backgroundColor
|
from colors import colorScheme, foregroundColor, backgroundColor
|
||||||
from libqtile import widget
|
from libqtile import widget
|
||||||
from libqtile.lazy import lazy
|
from libqtile.lazy import lazy
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
|
||||||
class Widgets(object):
|
class Widgets(object):
|
||||||
@ -175,7 +176,62 @@ class Widgets(object):
|
|||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
picom = widget.Picom(
|
picom = widget.GenPollText(
|
||||||
fmt='{}',
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/picom.sh").decode("utf-8"),
|
||||||
|
mouse_callbacks={
|
||||||
|
'Button1': lambda: subprocess.run("/home/repo/.config/qtile/scripts/picom-toggle.sh"),
|
||||||
|
},
|
||||||
|
update_interval=1,
|
||||||
padding=10,
|
padding=10,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
github1 = widget.WidgetBox(
|
||||||
|
widgets=[
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/notifications").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/gists").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/repositories").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
text_closed='[Github <]',
|
||||||
|
text_open='[Github >]',
|
||||||
|
)
|
||||||
|
|
||||||
|
github2 = widget.WidgetBox(
|
||||||
|
widgets=[
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/notifications").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/gists").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
widget.GenPollText(
|
||||||
|
fmt='{}',
|
||||||
|
func=lambda: subprocess.check_output("/home/repo/.config/qtile/scripts/github/repositories").decode("utf-8"),
|
||||||
|
update_interval=10,
|
||||||
|
padding=10,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
text_closed='[Github <]',
|
||||||
|
text_open='[Github >]',
|
||||||
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user