Patchwork [v2,04/11] tilo: replace sed with dirname in tilo.sh

login
register
mail settings
Submitter Aaro Koskinen
Date Dec. 23, 2013, 7:43 p.m.
Message ID <1387827813-8279-5-git-send-email-aaro.koskinen@iki.fi>
Download mbox | patch
Permalink /patch/304838/
State Accepted
Delegated to: David Miller
Headers show

Comments

Aaro Koskinen - Dec. 23, 2013, 7:43 p.m.
Use dirname to figure out the path of maketilo.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
---
 tilo/tilo.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/tilo/tilo.sh b/tilo/tilo.sh
index f152e288d967..175dacf71f22 100755
--- a/tilo/tilo.sh
+++ b/tilo/tilo.sh
@@ -112,7 +112,7 @@  if [ -z "$sun4u" -a -z "$sun4c" ]; then
 	exit 1
 fi
 
-`echo $0 | sed 's/tilo$/maketilo/'` $tilo_args out=$output
+$(dirname $0)/maketilo $tilo_args out=$output
 
 rm -f $to_remove