Skip to content

Minour she bang issue (#! /bin/path/to/wrenc) not working properly #142

Open
@aosenkidu

Description

@aosenkidu
Idunn2:she_bang_bug angelos$ pwd
/Users/angelos/development/kestrel-devel/she_bang_bug

I made two "shell scripts" - well, I probably should not have them end in .sh, but that does not matter for this showcase.

Idunn2:she_bang_bug angelos$ ls
she_bank_not_working_correctly.sh       this_works.sh

Contents of the files:

Idunn2:she_bang_bug angelos$ cat she_bank_not_working_correctly.sh 
#! /Users/angelos/development/kestrel-console/wren-console/bin/wrenc
System.print("This line is never executed, as wrenc does not like the *space* character")

Note the " " after the "!". Historically we would write that space character, see the other file:

Idunn2:she_bang_bug angelos$ cat this_works.sh 
#!/Users/angelos/development/kestrel-console/wren-console/bin/wrenc
System.print("This works now, as I deleted the *space* character")

/* historically we used to have a space after she bang 
So every "script" starts with the same 4 letters: "#! /", aka with the same 32bit "magic number".
Ofc this is not a serious bug. But a minour inconvenience.
*/

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions