summarylogtreecommitdiffstats
path: root/xlunch-create-entry
diff options
context:
space:
mode:
authorPeter Munch-Ellingsen2017-09-12 10:59:59 +0200
committerPeter Munch-Ellingsen2017-09-12 11:20:36 +0200
commit3c02425f9b612355a0999af0ff2b1a93044e1b71 (patch)
tree576ec04ac1bd93d57e0e6f57c5c841038a4ecbce /xlunch-create-entry
parent0007fc7c077b6d82edb2ca67422286b4045e508e (diff)
downloadaur-3c02425f9b612355a0999af0ff2b1a93044e1b71.tar.gz
Updated to work with v3 of xlunch
Diffstat (limited to 'xlunch-create-entry')
-rw-r--r--[-rwxr-xr-x]xlunch-create-entry43
1 files changed, 0 insertions, 43 deletions
diff --git a/xlunch-create-entry b/xlunch-create-entry
index 46fc2d4179d2..e69de29bb2d1 100755..100644
--- a/xlunch-create-entry
+++ b/xlunch-create-entry
@@ -1,43 +0,0 @@
-#!/bin/bash
-
-APPS=/usr/share/applications
-PIXMAPS=/usr/share/pixmaps
-ICONS=/usr/share/icons
-SIZE=48
-
-echo "/$1" | grep ".desktop" | while read DESKTOPFILE; do
- FDATA="$(cat $DESKTOPFILE)"
- NAME="$(echo "$FDATA" | grep -i "^Name=" | head -n 1 | cut -d "=" -f 2-)"
- EXEC="$(echo "$FDATA" | grep -i "^Exec=" | head -n 1 | cut -d "=" -f 2-)"
- ICONNAME="$(echo "$FDATA" | grep -i "^Icon=" | head -n 1 | cut -d "=" -f 2-)"
- USETERM="$(echo "$FDATA" | grep -i "^Terminal=" | head -n 1 | cut -d "=" -f 2-)"
- if [ "$USETERM" = "true" ]; then
- EXEC="$TERM -e ""$EXEC"
- fi
-
- if [ "$ICONNAME" != "" ]; then
- ICON="$(find "$PIXMAPS" | grep $ICONNAME"[.]png$" | head -n 1)"
- if [ "$ICON" == "" ]; then
- ICON="$(find "$ICONS" | grep $SIZE"x"$SIZE | grep $ICONNAME"[.]png$" | head -n 1)"
- fi
-
- if [ "$ICON" == "" ]; then
- ICON="$(find "$ICONS" | grep "scalable" | grep -E $ICONNAME"[.]png$" | head -n 1)"
- if [ "$ICON" == "" ]; then
- SVGICON="$(find "$ICONS" | grep "scalable" | grep -E $ICONNAME"[.]svg$" | head -n 1)"
- if type convert >/dev/null 2>&1; then
- if [ "$SVGICON" != "" ]; then
- mkdir -p "svgicons"
- convert -size $SIZEx$SIZE -background none "$SVGICON" "svgicons/"$ICONNAME".png"
- ICON="svgicons/"$ICONNAME".png"
- fi
- else
- ICON=$SVGICON
- fi
- fi
- fi
- if [ "$ICON" != "" -a "$EXEC" != "" -a "$NAME" != "" ]; then
- echo "$NAME;$ICON;$EXEC"
- fi
- fi
-done | sort | uniq