Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement more utility commands like cat, mkdir etc... #14

Open
29jm opened this issue Nov 22, 2020 · 5 comments
Open

Implement more utility commands like cat, mkdir etc... #14

29jm opened this issue Nov 22, 2020 · 5 comments

Comments

@29jm
Copy link
Owner

29jm commented Nov 22, 2020

On top of my head, the following are missing and could be implemented with the functions available in the libc right now:

  • cat
  • cd (this one should be implemented in the terminal app, not as a standalone program)
  • tree (in fact it's already implemented in test.c, but not in a useful form)
  • rm
  • grep
@xadaemon
Copy link
Contributor

I will give a shot at cat and rm might make for a fun challenge

@29jm
Copy link
Owner Author

29jm commented Dec 20, 2020

@octetd actually I added a basic cat a few commits ago, but it doesn't support multiple files, e.g. cat file1 file2, maybe you could add that? As for rm I added an unlink program that literally just calls unlink (the system call), but It'd be cool to have a more proper rm, with support for its -r option.

The current unlink system call won't delete folders though, not even empty ones. I'll add an rmdir syscall, you can assume you have it (from unistd.h, see man 3 rmdir) in the mean time if you start before I push it.

@xadaemon
Copy link
Contributor

xadaemon commented Dec 20, 2020 via email

@GandelXIV
Copy link
Contributor

I will try implementing cd.

@29jm
Copy link
Owner Author

29jm commented Apr 5, 2022

I will try implementing cd.

Excellent, let me know if I can help with anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants