summaryrefslogtreecommitdiff
path: root/Userland
AgeCommit message (Collapse)Author
2018-10-28Add basic symlink support.Andreas Kling
- sys$readlink + readlink() - Add a /proc/PID/exe symlink to the process's executable. - Print symlink contents in ls output. - Some work on plumbing options into VFS::open().
2018-10-28Add /proc/mm and a /bin/mm utility that just dumps it.Andreas Kling
This shows some info about the MM. Right now it's just the zone count and the number of free physical pages. Lots more can be added. Also added "exit" to sh so we can nest shells and exit from them. I also noticed that we were leaking all the physical pages, so fixed that.
2018-10-28Canonicalize the path used by sh.Andreas Kling
With a bunch of LibC work to support the feature. LibC now initializes AK::StringImpl by default. It's now fine to use AK in LibC/Userland! :^)
2018-10-28Add save/unsave cursor escape sequences.Andreas Kling
Also added a little terminal test program called /bin/tst.
2018-10-28Colorize ls output.Andreas Kling
2018-10-28Give the shell a nice, colorful prompt.Andreas Kling
The cwd looks like crap, I need to write some code to strip out ".." and extra slashes from the path string.
2018-10-27Add a /bin/clear that prints the clear terminal escape sequence.Andreas Kling
It doesn't work yet, but it will!
2018-10-27Add some basic field width support to printf().Andreas Kling
Use it to make "ls" output a bit better. Also sys$spawn now fails with EACCES if the path is not a file that's executable by the current uid/gid.
2018-10-27Implement loading of linked ELF executables.Andreas Kling
This took me a couple hours. :^) The ELF loading code now allocates a single region for the entire file and creates virtual memory mappings for the sections as needed. Very nice!
2018-10-27Implement waitpid() support for getting the waitee's exit code.Andreas Kling
2018-10-27Greatly improve /proc/PID/stack by tracing the ebp frame chain.Andreas Kling
I also added a generator cache to FileHandle. This way, multiple reads to a generated file (i.e in a synthfs) can transparently handle multiple calls to read() without the contents changing between calls. The cache is discarded at EOF (or when the FileHandle is destroyed.)
2018-10-26Add a very hackish /proc/PID/stack.Andreas Kling
It walks the stack and identifies anything that looks like a kernel symbol. This could be a lot more sophisticated.
2018-10-26Properly null-terminate the argv list created by sh.Andreas Kling
2018-10-26Add sys$uname() and a /bin/uname utility.Andreas Kling
2018-10-26Implement sys$chdir() and teach sh+ls to cd around and browse different dirs.Andreas Kling
2018-10-26Implement argc/argv support for spawned tasks.Andreas Kling
Celebrate the new functionality with a simple /bin/cat implementation. :^)
2018-10-26Add sys$gethostname and /bin/hostnameAndreas Kling
2018-10-25Add /bin/false and /bin/true for fun. :^)Andreas Kling
2018-10-25Add gettimeofday() syscall and LibC wrappers gettimeofday() and time().Andreas Kling
This only has second accuracy right now, I'll work out subseconds later.
2018-10-25Add a "sleep" syscall that sleeps for N seconds.Andreas Kling
2018-10-25Implement errno in LibC.Andreas Kling
This also meant I had to implement BSS (SHT_NOBITS) sections in ELFLoader. I also added an strerror() so we can print out what the errors are.
2018-10-25ELFLoader should fail with an error message for unresolved symbols.Andreas Kling
2018-10-24Add a "pwd" utility to userland.Andreas Kling
It's implemented as a separate process. How cute is that. Tasks now have a current working directory. Spawned tasks inherit their parent task's working directory. Currently everyone just uses "/" as there's no way to chdir().
2018-10-24Add an lstat() syscall and use it to make "ls" nicer.Andreas Kling
2018-10-24Lots of hacking to make a very simple "ls" utility.Andreas Kling
I added a dead-simple malloc that only allows allocations < 4096 bytes. It just forwards the request to mmap() every time. I also added simplified versions of opendir() and readdir().
2018-10-24Add simplified mmap() and munmap() syscalls.Andreas Kling
2018-10-24Add a simplified waitpid() so that sh can wait on spawned commands.Andreas Kling
2018-10-23Minor userland tweaks.Andreas Kling
2018-10-23Assume commands are binaries in /bin for now.Andreas Kling
2018-10-23Start adding a basic /proc filesystem and a "ps" utility.Andreas Kling
2018-10-23Lots of hacking:Andreas Kling
- Turn Keyboard into a CharacterDevice (85,1) at /dev/keyboard. - Implement MM::unmapRegionsForTask() and MM::unmapRegion() - Save SS correctly on interrupt. - Add a simple Spawn syscall for launching another process. - Move a bunch of IO syscall debug output behind DEBUG_IO. - Have ASSERT do a "cli" immediately when failing. This makes the output look proper every time. - Implement a bunch of syscalls in LibC. - Add a simple shell ("sh"). All it can do now is read a line of text from /dev/keyboard and then try launching the specified executable by calling spawn(). There are definitely bugs in here, but we're moving on forward.
2018-10-22Okay, with some mucking around, there is now a /bin/id and it runs!Andreas Kling
It statically links against everything in LibC that it needs. This will work just fine for a long time to come!
2018-10-22Link "id" against the LibC.Andreas Kling
We can now produce what should essentially be a runnable Serenity executable.
2018-10-22Import very modest Userland.Andreas Kling