4 ms·
The headline seems weird. The list of file descriptors etc etc does not sound like shell internals, but like Unix operating system concepts.
by usr1106 4y ago
The headline seems weird. The list of file descriptors etc etc does not sound like shell internals, but like Unix operating system concepts.
- supriyo-biswas 4y agoIf you're after how the shell parses commands, the EBNF grammar in the POSIX specification is a good start: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_10 https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V... Unfortunately, there's not much to a shell other than it's parsing capabilities.
- chasil 4y agoIt is unfortunate that an LR-parsed language was chosen. https://archive.fosdem.org/2018/schedule/event/code_parsing_posix_s_hell/ https://archive.fosdem.org/2018/schedule/event/code_parsing_...
- ytch 4y agoIt more likes "How shell invokes a command", I attended a POSIX programming course in university, one homework is implementing a simple shell, you need to handle the FDs, Pipes, environment variables by POSIX API as the article explains.
- dottedmag 4y agoShell internals and Unix internals are pretty intertwined. Amount of ancient syscalls and ioctls that exist directly to support shells is quite large.