Re: Bash-script – doesn't work in a launcher

Johnny Rosenberg gurus.knugum at gmail.com
Sat Dec 31 18:15:58 UTC 2011


2011/12/31 Leo Noordhuizen <leo.noordhuizen at gmail.com>:
> Johnny,
>
> You answered your own question I think.
>
> Leo

Yes, I really did… :P

I tested it right after I posted my question and found out before
reading any replies, so I was somewhat embarrassed there for a while,
since I should obviously tested it BEFORE posting, then there wouldn't
be any need for posting at all…


Kind regards

Johnny Rosenberg
ジョニー・ローゼンバーグ

>
> On Sat, Dec 31, 2011 at 6:39 PM, Johnny Rosenberg <gurus.knugum at gmail.com>
> wrote:
>>
>> 2011/12/31 Steve Flynn <anothermindbomb at gmail.com>:
>> > On 31 December 2011 17:00, Johnny Rosenberg <gurus.knugum at gmail.com>
>> > wrote:
>> >
>> >> Of course the first line of the script is #! /bin/bash. Well, except a
>> >> few comment lines above it, but that shouldn't matter, should it?
>> >>
>> >> So it's basically something like this:
>> >>
>> >> # Comment
>> >> # Continuation of comment
>> >> # Another comment
>> >> # More comments
>> >>
>> >> #!/bin/bash
>> >
>> > The hash-bang line needs to be the first line in the script. Move that
>> > to the top of the script, stick in a "set -x" if you want to see
>> > what's happening under the covers.
>> >
>> >
>> >
>> > --
>> > Steve
>>
>> Thanks, and also thanks to ”J” who wrote a similar reply. Yes, I moved
>> it to the top and now it seems to work. It still doesn't work on my
>> wife's computer though, I'm not sure why… She runs Ubuntu 10.04, so
>> maybe there are some differences there, like older bash version or
>> something like that. I'll take a closer look at it now.
>>
>> Still I wonder why it worked with the #!/bin/bash line not at the top
>> when I ran it from a terminal, should it really…? Maybe because bash
>> is default in a terminal?
>>
>>
>> Kind regards
>>
>> Johnny Rosenberg
>> ジョニー・ローゼンバーグ
>>
>> --
>> ubuntu-users mailing list
>> ubuntu-users at lists.ubuntu.com
>> Modify settings or unsubscribe at:
>> https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>
>
>
> --
> ubuntu-users mailing list
> ubuntu-users at lists.ubuntu.com
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>




More information about the ubuntu-users mailing list