Dotfiles config update (2022-05-26)
This commit is contained in:
parent
331da17daa
commit
c87cc70c08
|
@ -9,8 +9,9 @@ Xft.hintstyle: hintfull
|
||||||
Xft.lcdfilter: lcdfilter
|
Xft.lcdfilter: lcdfilter
|
||||||
|
|
||||||
XTerm*renderFont: true
|
XTerm*renderFont: true
|
||||||
!XTerm*faceName: xft:Mononoki Nerd Font
|
|
||||||
XTerm*faceName: xft:Monospace
|
XTerm*faceName: xft:Monospace
|
||||||
|
!XTerm*faceName: xft:Liberation Mono
|
||||||
|
!XTerm*faceName: xft:Mononoki Nerd Font
|
||||||
XTerm*faceSize: 10
|
XTerm*faceSize: 10
|
||||||
XTerm*utf8: 2
|
XTerm*utf8: 2
|
||||||
XTerm*locale: true
|
XTerm*locale: true
|
||||||
|
|
|
@ -5,13 +5,19 @@ desktop_files_home="${HOME}/.local/share/applications"
|
||||||
|
|
||||||
list_desktop_files() {
|
list_desktop_files() {
|
||||||
if [ -d "${desktop_files}" ] ; then
|
if [ -d "${desktop_files}" ] ; then
|
||||||
ls -1 "${desktop_files}"
|
ls -1 "${desktop_files}/" | grep ".desktop"
|
||||||
fi
|
fi
|
||||||
if [ -d "${desktop_files_home}" ] ; then
|
if [ -d "${desktop_files_home}" ] ; then
|
||||||
ls -1 "${desktop_files_home}"
|
ls -1 "${desktop_files_home}/" | grep ".desktop"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
list_desktop_icons() {
|
||||||
|
list_desktop_files | while read desktop_file ; do
|
||||||
|
echo " ${desktop_file}"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
rundesk () {
|
rundesk () {
|
||||||
if [ -z ${1} ] ; then
|
if [ -z ${1} ] ; then
|
||||||
echo "No file entry"
|
echo "No file entry"
|
||||||
|
@ -30,7 +36,8 @@ else
|
||||||
runDesktop="rundesk"
|
runDesktop="rundesk"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
list_output=$(list_desktop_files | dmenu "$@")
|
#list_output=$(list_desktop_files | dmenu "$@")
|
||||||
|
list_output=$(list_desktop_icons | dmenu "$@")
|
||||||
if [ -f "${desktop_files}/${list_output}" ] ; then
|
if [ -f "${desktop_files}/${list_output}" ] ; then
|
||||||
${runDesktop} "${desktop_files}/${list_output}"
|
${runDesktop} "${desktop_files}/${list_output}"
|
||||||
elif [ -f "${desktop_files_home}/${list_output}" ] ; then
|
elif [ -f "${desktop_files_home}/${list_output}" ] ; then
|
||||||
|
|
|
@ -1,15 +1,26 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
dmenu_path_output() {
|
list_binaries() {
|
||||||
cachedir="${XDG_CACHE_HOME:-"$HOME/.cache"}"
|
binaries=0
|
||||||
cache="$cachedir/dmenu_run"
|
path_binaries=${PATH}
|
||||||
[ ! -e "$cachedir" ] && mkdir -p "$cachedir"
|
count_path=1
|
||||||
IFS=:
|
while [ ${binaries} -eq 0 ] ; do
|
||||||
if stest -dqr -n "$cache" $PATH; then
|
current_path=$(echo ${path_binaries} | cut -d ":" -f ${count_path})
|
||||||
stest -flx $PATH | sort -u | tee "$cache"
|
if [ -z "${current_path}" ] ; then
|
||||||
|
binaries=1
|
||||||
else
|
else
|
||||||
cat "$cache"
|
ls -1 ${current_path}/
|
||||||
|
count_path=$(expr ${count_path} + 1)
|
||||||
fi
|
fi
|
||||||
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
dmenu_path_output | dmenu "$@" | ${SHELL:-"/bin/sh"} &
|
list_binaries_icons() {
|
||||||
|
list_binaries | while read current_binary ; do
|
||||||
|
echo " ${current_binary}"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
#list_output=$(list_binaries | dmenu "$@")
|
||||||
|
list_output=$(list_binaries_icons | dmenu "$@")
|
||||||
|
${list_output}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user