FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » anyone else writing Linux (or cross-system) applications in PHP?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: anyone else writing Linux (or cross-system) applications in PHP? [message #180282 is a reply to message #180279] Sun, 03 February 2013 20:26 Go to previous messageGo to previous message
John Hasler is currently offline  John Hasler
Messages: 5
Registered: February 2013
Karma:
Junior Member
I wrote:
> [Debian] maintainers are free to use [Bash] in scripts.

J G Miller writes:
> Certainly not boot time scripts and it appears that it
> is frowned upon for other scripts.

From the Debian Policy Manual:

All command scripts, including the package maintainer scripts inside
the package and used by dpkg, should have a #! line naming the shell
to be used to interpret them. In the case of Perl scripts this
should be #!/usr/bin/perl.

....

Shell scripts (sh and bash) other than init.d scripts should almost
certainly start with set -e so that errors are detected. init.d
scripts are something of a special case, due to how frequently they
need to call commands that are allowed to fail, and it may instead be
easier to check the exit status of commands directly. See Writing the
scripts, Section 9.3.2 for more information about writing init.d
scripts.

...

If a shell script requires non-SUSv3 features from the shell
interpreter other than those listed above, the appropriate shell must
be specified in the first line of the script (e.g., #!/bin/bash) and
the package must depend on the package providing the shell (unless
the shell package is marked "Essential", as in the case of bash).

...

If in doubt whether a script complies with these requirements, use
/bin/bash.

...

csh and tcsh should be avoided as scripting languages.
--
John Hasler
jhasler(at)newsguy(dot)com
Dancing Horse Hill
Elmwood, WI USA
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Problem with readdir and ssh2
Next Topic: web designers and developers
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 13:53:02 GMT 2024

Total time taken to generate the page: 0.05323 seconds