Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#336 closed bug (fixed)

[bash/sh] Install.sh fails due to weird if behaviour

Reported by: johndrinkwater Owned by: sikosis
Priority: low Milestone: R1
Component: Applications Version:
Keywords: Cc: diver
Blocked By: Blocking:
Has a Patch: no Platform: All

Description

/boot/apps/imkit$ ./Install.sh [pops up warning shown below] /boot/apps/imkit$

Head of script:

cd "$(dirname "$0")" if pwd | grep " ";

then alert "Please install from a directory with no spaces in the path name,

the current one (pwd) has spaces. Just move all the files to somewhere that doesn't have spaces, like /boot/home/mydirectory. If there are spaces, the install script malfunctions. Sorry.";

exit 1;

fi

Attachments (1)

Install.sh (5.6 KB ) - added by johndrinkwater 13 years ago.
The failing script

Download all attachments as: .zip

Change History (10)

comment:1 by korli, 13 years ago

Could you provide an easier way to reproduce this bug (ie attach a script which works in R5 and not on Haiku) ?

by johndrinkwater, 13 years ago

Attachment: Install.sh added

The failing script

comment:2 by diver, 13 years ago

Cc: diver added

comment:3 by korli, 13 years ago

bug_group: developers

comment:4 by korli, 13 years ago

Cc: axeld@… added

comment:5 by korli, 13 years ago

I found a short testcase :

echo toto | false echo $?

=> it returs 1 on R5 and 0 on Haiku. Seems like a process/pipe problem. Axel, any ideas ?

comment:6 by korli, 13 years ago

Resolution: fixed

comment:7 by korli, 13 years ago

My test case is fixed by Axel as of revision 17338

comment:8 by korli, 13 years ago

Status: newclosed

comment:9 by johndrinkwater, 13 years ago

works a treat

Note: See TracTickets for help on using tickets.