https://github.com/samagra14/samsh
A hackable basic shell built in C.
https://github.com/samagra14/samsh
c linux shell
Last synced: over 1 year ago
JSON representation
A hackable basic shell built in C.
- Host: GitHub
- URL: https://github.com/samagra14/samsh
- Owner: samagra14
- Created: 2017-11-06T06:54:32.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-11-06T06:58:30.000Z (over 8 years ago)
- Last Synced: 2025-03-17T15:06:53.208Z (over 1 year ago)
- Topics: c, linux, shell
- Language: C
- Size: 2.93 KB
- Stars: 7
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# samsh - A basic C shell
---
SAMSH is a simple implementation of a shell in C.t demonstrates the basics of how a shell works.That is: read, parse, fork, exec, and wait. Since its purpose is learning (not feature completeness or even fitness for casual use), it has many limitations, including:
* Commands must be on a single line.
* Arguments must be separated by whitespace.
* No quoting arguments or escaping whitespace.
* No piping or redirection.
* Only builtins are: `cd`, `help`, `exit`.
## Contributing
New contributions are always welcome from fellow developers who are interested in learning the dynamics of a shell. Just follow the given guidelines :
* Create your own fork of the repo
* Migrate to a new branch
* Implement your changes
* Open a pull request for the changes and provide a detailed enough description of your work.
## Todos
There is a lot of scope of improvement in the shell. Pick one from the list below:
1. Implementing Tab completion
2. You can implement one of the following builtins :
* `alias`
* `logout`
* `enable`
* `declare`
3. Implementing config files.
4. Implementing history-record and up arrow command display.
## License
This code is in the public domain (see [UNLICENSE](UNLICENSE) for more details). This means you can use, modify, and distribute it without any restriction. I appreciate, but don't require, acknowledgement in derivative works.