News for hackers. Stuff that matters.
Re:Spark by etanol on Tuesday November 15, 2011 @03:24AM (#3237522)
The script is not a proper POSIX bourne shell script, as it uses arrays.

For starters, it won't work in dash (Debian and Ubuntu /bin/sh implementation). So the shebang line should be changed to #!/bin/bash (not sure if it would work in Zsh either).

Re:Spark by VMG on Tuesday November 15, 2011 @05:47AM (#3237783)
Maybe this shouldn't be a shell script. A C implementation would be quite portable and also pretty fast.
Re:Spark by willvarfar on Tuesday November 15, 2011 @03:33AM (#3237538)
Fork and fix please!
Re:Spark by imrehg on Tuesday November 15, 2011 @04:23AM (#3237646)
... and send a pull-request, so everyone can share the happy.
Re:Spark by etanol on Tuesday November 15, 2011 @06:59AM (#3237926)
Already done, and someone even did a better fix:

https://github.com/holman/spark/pull/8

Re:Spark by kelnos on Tuesday November 15, 2011 @04:06PM (#3240219)
NetBSD seriously doesn't put bash in /bin? That's just broken by design.
Re:Spark by ketralnis on Tuesday November 15, 2011 @06:40PM (#3240910)
I can't speak to NetBSD, but FreeBSD doesn't put any user-installed programs in /bin or /usr/bin, they all go into /usr/local. Since bash isn't distributed as part of the base system, it goes into /usr/local/bin/bash
Re:Spark by kelnos on Saturday November 26, 2011 @04:53AM (#3279528)
So then how do you write cross-platform scripts? You can't even do "#!/usr/bin/env bash" since I'm assuming what you're saying means 'env' is in /usr/local/ as well, but on Linux systems it'll be in /usr/.

Broken! Can we please just pick one convention and stick with it? Oh, standards... so many to choose from.