[EnglishFrontPage] [TitleIndex] [WordIndex

POSIX

POSIX is a standard which was laid out in RFC<insert_number> in the 1980s... It defines a common set of features which a POSIX shell and NIX system should provide.

Nowadays bash has many more features than POSIX outlined.

(POSIX should not be confused with sysv, which is a layout of the init.d script system. ?)

Should I write scripts in POSIX?

bash is now considered the standard interpreter for almost all known UNIXs.

Exceptions are: Mac? IRIX? Solaris? ...

These days, you only need to write scripts in POSIX if ...

The Bash FAQ contains numerous examples of how to do things in a POSIX way (often alongside how to do that thing the modern way). It might be nice to have a CodeChartPosixVsModern showing the two different methods, and a link to the full wiki discussion page.

Exceptions

Some modern shells, bash included, occasionally deviate from the POSIX requirements. For example, grep under Debian processes the -f option in a way which contradicts the standard ...

Further Information

You may wish to see the Wikipedia page on "POSIX".


2012-07-01 04:11