From 13e87f0a9638168eb7cf5a705a472a1a99113aa2 Mon Sep 17 00:00:00 2001 From: Ross Burton Date: Fri, 29 Jun 2007 10:23:37 +0000 Subject: Capitalise titles without using bash syntax git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2059 311d38ba-8fff-0310-9ca6-ca027cbcb966 --- meta/packages/puzzles/oh-puzzles_svn.bb | 6 ++---- meta/packages/puzzles/puzzles_r7593.bb | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) (limited to 'meta/packages/puzzles') diff --git a/meta/packages/puzzles/oh-puzzles_svn.bb b/meta/packages/puzzles/oh-puzzles_svn.bb index f6599484e6..d4d8b3b5a7 100644 --- a/meta/packages/puzzles/oh-puzzles_svn.bb +++ b/meta/packages/puzzles/oh-puzzles_svn.bb @@ -3,7 +3,7 @@ LICENSE = "MIT" SECTION = "x11" DEPENDS = "gtk+ gconf intltool-native librsvg" PV = "0.1+svn${SRCDATE}" -PR = "r3" +PR = "r4" inherit autotools pkgconfig @@ -19,9 +19,7 @@ do_install_append () { for prog in *; do if [ -x $prog ]; then # Convert prog to Title Case - firstchar=${prog:0:1} - title=`echo "$firstchar" | tr a-z A-Z` - title="$title${prog:1}" + title=$(echo $prog | sed 's/\(^\| \)./\U&/g') echo "making ${D}/${datadir}/applications/$prog.desktop" cat < ${D}/${datadir}/applications/$prog.desktop [Desktop Entry] diff --git a/meta/packages/puzzles/puzzles_r7593.bb b/meta/packages/puzzles/puzzles_r7593.bb index bcb19bae2c..e580116198 100644 --- a/meta/packages/puzzles/puzzles_r7593.bb +++ b/meta/packages/puzzles/puzzles_r7593.bb @@ -1,6 +1,6 @@ DEPENDS = "gtk+" -PR = "r4" +PR = "r5" MOD_PV = "${@bb.data.getVar('PV',d,1)[1:]}" #SRC_URI = "http://www.chiark.greenend.org.uk/~sgtatham/puzzles/puzzles-${PV}.tar.gz" @@ -35,9 +35,7 @@ do_install () { for prog in *; do if [ -x $prog ]; then # Convert prog to Title Case - firstchar=${prog:0:1} - title=`echo "$firstchar" | tr a-z A-Z` - title="$title${prog:1}" + title=$(echo $prog | sed 's/\(^\| \)./\U&/g') echo "making ${D}/${datadir}/applications/$prog.desktop" cat < ${D}/${datadir}/applications/$prog.desktop [Desktop Entry] -- cgit v1.2.3