What language are the SlackBuild scripts written in?
What language is used to write the SlackBuild scripts? I'm interested in learning to write them.
|
|
More generally, they're written in bourne shell. "bash" is a shell capable of interpreting bourne shell scripts, but it also has a few extensions not present in bourne shell. These are sometimes called "bashisms". They are probably present here and there in some scripts. Note that you could write a slackbuild in any language, but it makes more sense to write them as bourne shell scripts.
|
The template SlackBuild scripts use /bin/sh which, on a default Slackware installation, is a symlink to /bin/bash. When bash is called as sh it works as a close approximation of the POSIX shell which is a superset of the Bourne shell.
Recently there was an inconclusive debate on the SlackBuild mailing list about whether to allow SlackBuild scripts using /bin/bash |
just as another note, bash has some shortcuts and usefull 'bashisms' that are perfectly safe to use but are concidered bad pactice because it makes it uncompatible with POSIX sh shell.
|
It's usually a good idea to avoid bashisms so that the scripts work in other shells.
|
All times are GMT -5. The time now is 04:57 AM. |