From 2c8bb44a038b8334b2610720d26da0fdef9b23cc Mon Sep 17 00:00:00 2001 From: Daniel Napora Date: Fri, 26 Aug 2022 17:18:30 +0200 Subject: [PATCH] tint2 pipe --- usr/bin/jgtint2-pipe | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/usr/bin/jgtint2-pipe b/usr/bin/jgtint2-pipe index c04fd3e..db0a75f 100755 --- a/usr/bin/jgtint2-pipe +++ b/usr/bin/jgtint2-pipe @@ -1,5 +1,5 @@ #!/bin/bash -#TODO Handle more than one tint + #TODO Reset to defaults TINT2PATH="$HOME/.config/tint2" @@ -22,8 +22,9 @@ case $LANG in AUTOHIDE="Autoukrywanie ?" SIZEHIDDEN="Rozmiar gdy ukryty" ICONS="Ikony" - CLOCK_LINE1="" - CLOCK_LINE2="" + CLOCK_LINE1="Zegar linia 1" + CLOCK_LINE2="Zegar linia 2" + NONE="brak" RESET="Resetuj" TOP="Góra" BOTTOM="Dół" @@ -65,6 +66,9 @@ case $LANG in AUTOHIDE="Autohide?" SIZEHIDDEN="Size when hidden:" ICONS="Icon theme" + CLOCK_LINE1="Clock line 1" + CLOCK_LINE2="Clock line 2" + NONE="none" RESET="Reset to default" TOP="Top" BOTTOM="Bottom" @@ -106,6 +110,9 @@ case $LANG in AUTOHIDE="Autohide?" SIZEHIDDEN="Size when hidden:" ICONS="Icon theme" + CLOCK_LINE1="Clock line 1" + CLOCK_LINE2="Clock line 2" + NONE="none" RESET="Reset to default" TOP="Top" BOTTOM="Bottom" @@ -160,18 +167,18 @@ qactions () { # Clock if [[ "$PANELITEMS" == *C* ]]; then out+=("^sep()") - out+=("Clock line 1 [ $(date "+${TF1}") ],^checkout(cl1)") - out+=("Clock line 2 [ $(date "+${TF2}") ],^checkout(cl2)") + out+=("$CLOCK_LINE1 [ $(date "+${TF1}") ],^checkout(cl1)") + out+=("$CLOCK_LINE2 [ $(date "+${TF2}") ],^checkout(cl2)") out2+=("^tag(cl1)") - out2+=("^sep(Clock first line)") + out2+=("^sep($CLOCK_LINE1)") out2+=("$(date +"%H:%M") (%H:%M),t2ctl clockline1 '%H:%M' ${TINT};$me") out2+=("$(date +"%I:%M %p") (%I:%M %p),t2ctl clockline1 '%I:%M %p' ${TINT};$me") out2+=("$(date +"%-I:%M %p") (%I-:%M %p),t2ctl clockline1 '%-I:%M %p' ${TINT};$me") out2+=("$(date +"%H:%M:%S") (%H:%M:%S),t2ctl clockline1 '%H:%M:%S' ${TINT};$me") out2+=("^tag(cl2)") - out2+=("^sep(Clock second line )") - out2+=("none,t2ctl clockline2 none ${TINT};$me") + out2+=("^sep($CLOCK_LINE2)") + out2+=("$NONE,t2ctl clockline2 none ${TINT};$me") out2+=("^sep()") out2+=("$(date +"%A %d %B") (%A %d %B),t2ctl clockline2 '%A %d %B' ${TINT};$me") out2+=("$(date +"%a %d %b") (%a %d %b),t2ctl clockline2 '%a %d %b' ${TINT};$me") @@ -298,7 +305,7 @@ out+=("^sep($TINT2_CONFIGURE)") getvalues qactions out+=("$CONFIGURE $TINT2,tint2conf $TINT") - out+=("$EDIT_TINT2 $TINT2,xdg-open $TINT") + out+=("$EDIT_TINT2 $TINT2,geany $TINT") fi