Permalink
Browse files

Use the PBI_ICONURL variable in a PBI, if it exists, when updating me…

…ta-file
  • Loading branch information...
1 parent 90ee280 commit 191425dd808de3a2b239517af958af1bb1f7528c @kmoore134 kmoore134 committed Nov 12, 2013
Showing with 8 additions and 1 deletion.
  1. +8 −1 src-sh/pbi-manager10/pbi-manager
View
9 src-sh/pbi-manager10/pbi-manager
@@ -2048,7 +2048,7 @@ do_pbi_mt_syncpbi()
PBI_FILENAME="${PBI_MT_PBIFILE}"
load_info_from_header
- mFlags="add --app -i \"http://images.pbidir.com/progicons/generic.png\""
+ mFlags="add --app"
if [ -n "$PBI_PROGAUTHOR" ] ; then mFlags="$mFlags -a \"${PBI_PROGAUTHOR}\""; fi
if [ -n "$PBI_CATEGORY" ] ; then mFlags="$mFlags -c \"${PBI_CATEGORY}\""; fi
if [ -n "$PBI_LICENSE" ] ; then mFlags="$mFlags -l \"${PBI_LICENSE}\""; fi
@@ -2061,6 +2061,13 @@ do_pbi_mt_syncpbi()
if [ -n "$PBI_PROGTYPE" ] ; then mFlags="$mFlags -t \"$PBI_PROGTYPE\""; fi
if [ "$PBI_REQUIRESROOT" = "YES" ] ; then mFlags="$mFlags -r"; fi
+ # Set the icon URL, or make it generic if it doesn't exist
+ if [ -n "$PBI_ICONURL" ] ; then
+ mFlags="$mFlags -i \"${PBI_ICONURL}\""
+ else
+ mFlags="$mFlags -i \"http://images.pbidir.com/progicons/generic.png\""
+ fi
+
# Add the app
echo "${0} ${mFlags} -n \"${PBI_PROGNAME}\" `realpath ${PBI_MT_METAFILE}`" >/tmp/.pbiCmd.$$
chmod 755 /tmp/.pbiCmd.$$

0 comments on commit 191425d

Please sign in to comment.