diff --git a/usr/bin/jgespanso-pipe b/usr/bin/jgespanso-pipe
index 2cd38ef..04346ed 100755
--- a/usr/bin/jgespanso-pipe
+++ b/usr/bin/jgespanso-pipe
@@ -2,18 +2,21 @@
case $LANG in
pl*)
+ TYPE_TO_SEARCH="pisz, aby wyszukać"
CONFIGURE="Konfiguracja Espanso"
EDITCONF="Edytuj domyślny plik konfiguracyjny"
OPENCONFDIR="Otwórz katalog z konfiguracją"
DOCU="Dokumentacja Espanso (online)"
;;
es*)
+ TYPE_TO_SEARCH="Buscar"
CONFIGURE="Configurar Espanso"
EDITCONF="Editar archivo x defecto"
OPENCONFDIR="Abrir el directorio"
DOCU="Leer Documentacion de Espanso (en línea)"
;;
*)
+ TYPE_TO_SEARCH="Type to filter"
CONFIGURE="Configure Espanso"
EDITCONF="Edit default config file"
OPENCONFDIR="Open config directory"
@@ -26,14 +29,14 @@ esac
MENU_ITEMS=/tmp/espanso_list.csv
trap "rm -f $MENU_ITEMS" EXIT
-echo "^sep(Espanso - text expander)" >/tmp/espanso_list.csv
-
if [[ $(espanso status) =~ "not" ]]
then
+ echo "^sep(Espanso - text expander)" >/tmp/espanso_list.csv
echo "Espanso not running! Run it first by: espanso start" >>/tmp/espanso_list.csv
else
-
+echo "@search,,10,5,292,20,4,left,top,auto,#262626,\"\"\" $TYPE_TO_SEARCH\"\"\"" >/tmp/espanso_list.csv
+echo "^sep(Espanso - text expander)" >>/tmp/espanso_list.csv
while read -r line ; do
IFS='-' read -r id string <<< "$line"
@@ -54,7 +57,7 @@ fi
if [ $1 == "-s" ]; then
. /usr/bin/pipemenu-standalone.cfg
-MENU_PADDING_TOP=0
+MENU_PADDING_TOP=24
MENU_HALIGN="center"
MENU_VALIGN="top"
MENU_MARGIN_Y=40
diff --git a/usr/bin/jghistory-pipe b/usr/bin/jghistory-pipe
index 3471f1d..406b956 100755
--- a/usr/bin/jghistory-pipe
+++ b/usr/bin/jghistory-pipe
@@ -1,14 +1,17 @@
#!/bin/bash
case $LANG in
pl*)
+ TYPE_TO_SEARCH="pisz, aby wyszukać"
HISTHELPER="Ściągawka z historii"
NOTHING="Niczego tu nie ma... Otwórz terminal (W-t) i wykonaj jakieś polecenie"
;;
es*)
+ TYPE_TO_SEARCH="Buscar"
HISTHELPER="Historia breve"
NOTHING="Nada que ver aquí...Abrir la terminal (W-t) y ejecutar algunos comandos"
;;
*)
+ TYPE_TO_SEARCH="Type to filter"
HISTHELPER="History helper"
NOTHING="Nothing to see here... Open terminal (W-t) and run some commands"
;;
@@ -17,20 +20,24 @@ esac
MENU_ITEMS=/tmp/history_list.csv
trap "rm -f $MENU_ITEMS" EXIT
-echo "^sep($HISTHELPER)" >/tmp/history_list.csv
+
if [ -f ~/.bash_history ]; then
+echo "@search,,10,5,292,20,4,left,top,auto,#262626,\"\"\" $TYPE_TO_SEARCH\"\"\"" >/tmp/history_list.csv
+
+echo "^sep($HISTHELPER)" >>/tmp/history_list.csv
while read -r line ; do
- printf "\"\"\"%s\"\"\",xdotool type --delay 0 \"%s\"\n" "$line" "$line" >> $MENU_ITEMS
+ printf "\"\"\"%s\"\"\",xdotool type --delay 0 \'%s\'\n" "$line" "$line" >> $MENU_ITEMS
done < <(cat ~/.bash_history|sort|uniq)
else
+echo "^sep($HISTHELPER)" >/tmp/history_list.csv
echo "\"\"\"$NOTHING\"\"\",exo-open --launch TerminalEmulator" >>/tmp/history_list.csv
fi
### RUN
if [ $1 == "-s" ]; then
. /usr/bin/pipemenu-standalone.cfg
-MENU_PADDING_TOP=0
+MENU_PADDING_TOP=24
MENU_HALIGN="center"
MENU_VALIGN="top"
MENU_MARGIN_Y=40
@@ -47,3 +54,4 @@ fi
#cat ${CONFIG_FILE}
cat ${MENU_ITEMS}
+