Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#18 squirrel-sql.sh script fails to execute

closed
Colin Bell
None
5
2002-03-27
2002-02-13
jimjamjoh
No

bash error is "no such file or directory"

weird behavior, because if i copy the contents exactly
into a new file, save, and execute, the script works
fine.

verified behavior on both redhat 7.1 and macos 10.1

Discussion

  • Colin Bell
    Colin Bell
    2002-02-13

    • assigned_to: nobody --> colbell
     
  • Colin Bell
    Colin Bell
    2002-02-13

    Logged In: YES
    user_id=233132

    Probably because I'm generating the install on a Windows
    machine and the file permissions for Linux aren't being
    setup. When I get my new machine (real soon now I hope)
    I'll be moving development to Linux and this problem should
    be solved.

    On a side note does SQuirreL run properly on the Mac? Thats
    been a platform that I haven't been able to test on.

    Col

     
  • Henner Zeller
    Henner Zeller
    2002-02-16

    Logged In: YES
    user_id=42577

    The generation on a windows machine might be one reason, but
    its not the execute permission (then it would say:
    'permission denied' if you try to execute it).

    Usually this is due to CRLF in the shell-script: The first
    line then says
    #!/bin/bash^M
    and, obviously, a binary with that name does not exist..

    This would explain, that copying makes the thing work.
    Bottomline: don't include CRLFs in shell scripts; this
    means, the <fixcrlf>-ant-task added in build.xml at
    03-Feb-02 should have fixed this problem, so the question
    ist, what version Kris used.

     
  • jimjamjoh
    jimjamjoh
    2002-02-18

    Logged In: YES
    user_id=335254

    Yeah, I think that the CRLF is responsible, as Vim reports
    the file formatting as a DOS file.

    If you're going to generate the Unix shell scripts in a
    Windows environment, gVim (www.vim.org) for windows my
    default saves files with unix-style line breaks.

    As for whether squirrel runs in OS X, it appears to run
    very well with Apple's Java 1.3.1 JVM.

     
  • Colin Bell
    Colin Bell
    2002-02-19

    Logged In: YES
    user_id=233132

    I'll take a look at the build script, its supposed to be
    formatting the shell script with LFs.

     
  • Colin Bell
    Colin Bell
    2002-02-19

    Logged In: YES
    user_id=233132

    Thats excellent news about the Mac. Would you be able to
    email (colbelloz at bigpond dot com) me a screen dump of
    Squirrel running on the Mac for the screenshots page on the
    web site?

    Thanks
    Col

     
  • Colin Bell
    Colin Bell
    2002-02-22

    Logged In: YES
    user_id=233132

    The build script is definitiely not ensuring that Unix
    script files have a LF line ending. This will be fixed in
    the next release.

    Col

     
  • jimjamjoh
    jimjamjoh
    2002-02-22

    Logged In: YES
    user_id=335254

    Col...

    Hey, did you get the OS X screenshots tarball I eMailed to
    you a few days ago? Sorry to post here but I've no other
    way of contacting you.

    -kris

     
  • Logged In: NO

    try: cat -v squirrel-sql.sh

    If you see ^M at the end of every line
    do:

    tr -d '\015' < squirrel-sql.sh > new_squirrel-sql.sh
    mv
    new_squirrel-sql.sh squirrel-sql.sh

    ...to remove the
    CarriageReturn chars and rename the resulting file. The script should
    work thereafter.

    I had the same problem downloading via Netscape
    v4.76.

     
  • Colin Bell
    Colin Bell
    2002-03-27

    • status: open --> closed
     
  • Colin Bell
    Colin Bell
    2002-03-27

    Logged In: YES
    user_id=233132

    Fixed in the just released 1.1beta2.

    Col