phoenix
phoenix copied to clipboard
Missing core utilities
The POSIX spec lists a whole lot of different utilities, some of which are not so relevant (I'm looking at you, fort77). Here's a list I've come up with, roughly grouped into categories.
- [ ] alias/unalias
- [ ] bc
- [ ] cal
- [ ] cksum
- [ ] command
- [ ] df
- [ ] du
- [ ] expr
- [ ] fc (Needs some kind of terminal text editor)
- [ ] file
- [ ] find
- [ ] getopts
- [ ] iconv
- [x] man: Just print a message saying to use
helpinstead - [ ] more/less. (more is the spec one, but less is nicer to use. Maybe redirect one to the other? Or just share a lot of code)
- [ ] od
- [ ] patch
- [ ] pathchk
- [ ] sh
- [x] sleep
- [ ] tee
- [ ] test - need to rename our existing
test! - [ ] time
- [ ] tsort
- [ ] type
- [ ] wait
- [ ] xargs
Text processing
- Per-line
- [ ] cut
- [ ] expand/unexpand
- [ ] fold
- [x] grep
- [x] head
- [ ] join
- [ ] nl
- [ ] paste
- [ ] pr
- [x] sort
- [ ] split
- [ ] uniq
- Printf-like
- [x] date
- [x] printf - missing a couple of features but mostly complete
- Sed-like
- [ ] awk
- [ ] csplit
- [ ] dd
- [ ] sed
- [ ] tr
- Binary
- [ ] strings
Comparison
- [ ] cmp
- [ ] comm
- [ ] diff
Terminal things
- [ ] read
- [ ] stty
- [ ] tabs
- [ ] tput
- [ ] tty
User/group/permission related
- [ ] chgrp
- [ ] chmod
- [ ] chown
- [ ] id
- [ ] logname
- [ ] mkdir lacks permission stuff too
- [ ] newgrp
- [ ] ulimit? Unless we just output "unlimited"
- [ ] umask
- [ ] uname
- [ ] who
Other ones requiring platform support
- [ ] crontab
- [ ] fuser I think?
- [ ] getconf?
- [ ] jobs?
- [ ] kill?
- [ ] link/ln/unlink? (link is equivalent to a specific invocation of ln)
- [ ] locale?
- [ ] localedef?
- [ ] logger
- [ ] lp - printers!
- [ ] mkfifo
- [ ] nice/renice
- [ ] nohup
- [ ] ps
Missing functionality
- [ ] cd: -LP and spec algorithm
- [ ] cp: options and spec algorithm
- [ ] echo: escapes
- [ ] env: Assigning variables, running a command with a set environment
- [ ] head: multiple inputs
- [ ] ls: I'm sure we're missing a bunch of stuff here
- [ ] mv: options and spec algorithm
- [ ] pwd: -LP
- [ ] tail: options
- [ ] touch: options and spec algorithm
you miss cc, a c compiler
you miss cc, a c compiler
Yeah that's one of the ones I skipped. A C compiler is not useful for Puter when it can't (yet?) run C programs. (Though, people are working on x86 emulation so who knows.)
This was originally a list I put together for my own notes, but decided to make it public instead. So what went on it was my opinion really. Feel free to implement anything not on this list if it makes sense. :^)
you miss cc, a c compiler
Yeah that's one of the ones I skipped. A C compiler is not useful for Puter when it can't (yet?) run C programs. (Though, people are working on x86 emulation so who knows.)
This was originally a list I put together for my own notes, but decided to make it public instead. So what went on it was my opinion really. Feel free to implement anything not on this list if it makes sense. :^)
Most computers can't run C directly, that's why they compile it :) You'd compile C into wasm, or into JavaScript ala emscripten. That is not the hard part, the hard part is implementing the posix C extensions. Essentially we'd need to embed emscripten into puter.
but maybe this is obviously too ambitious, so I would say, get us a wasm assembler and we will start from there
In discussions with the community (mostly via Discord at the moment) we seem to be leaning toward the direction of x86 emulation rather than something like emscripten. With this approach Puter's own filesystem could be mounted into something like a headless Archlinux instance using our FUSE driver.
In discussions with the community (mostly via Discord at the moment) we seem to be leaning toward the direction of x86 emulation rather than something like emscripten. With this approach Puter's own filesystem could be mounted into something like a headless Archlinux instance using our FUSE driver.
assuming you get x86 emulation you'll still have to translate the posix syscalls, unless you emulate the whole OS (but then Id just visit v86 or JSlinux), also it will be slower. since you do have to do that, you can support native wasm/js anyway