Skip to content

Latest commit

 

History

History
48 lines (39 loc) · 1.59 KB

File metadata and controls

48 lines (39 loc) · 1.59 KB

Possible project proposal?

How the UNIX Shell works (Sam)

  • fork() and execve() syscalls
  • /usr/bin/[ is just a symlink to /usr/bin/test
    • /usr/bin/[, 1, =, 2, ] returns 1
    • /usr/bin/[, 1, =, 1, ] returns 0
$ echo -e '#!/usr/bin/env python\nimport sys; print(sys.argv)' > script.py
$ chmod +x script.py
$ a='1 2 3'
$ ./script.py $a
["./script.py", "1", "2", "3"]
$ ./script.py $a
["./script.py", "1 2 3"]

Fish shell (Russel)

Oil shell (Evan)

Ammonite shell (Sam)

  • Slides: https://docs.google.com/presentation/d/11vZzXCfAA0aOFAuHA0nAvAzALGFGCH-dqHxx6XMgbk8
  • Shell underlies important applications/orchestration but has low guarantees! (no typesafety)
  • But at least it's concise? Safer alternatives are very verbose (Python, Java, Scala)
  • Develop a Scala library to make it less verbose (still using Scala REPL)
  • Develop a Scala REPL suitable for system shell.
    • No more than twice as verbose as Bash.