{"id":27296641,"url":"https://github.com/shubhamsharma0711/custom-unix-linux-shell","last_synced_at":"2026-04-17T01:02:03.235Z","repository":{"id":218743638,"uuid":"641441053","full_name":"SHUBHAMSHARMA0711/Custom-Unix-Linux-Shell","owner":"SHUBHAMSHARMA0711","description":"Custom Unix/Linux Shell, I developed as part of an Operating Systems course Assignment at IIITD. All Commands are implemented using both the fork system call and pthreads.","archived":false,"fork":false,"pushed_at":"2024-01-23T15:15:13.000Z","size":21,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-11T11:55:33.170Z","etag":null,"topics":["c","cse231","cse231-iiitd","custom-shell","execvp","fork","iiitd","linux-shell","os","os-assignment","shell","shell-assignment","thread","unix-shell"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SHUBHAMSHARMA0711.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-05-16T13:26:36.000Z","updated_at":"2024-09-14T19:33:50.000Z","dependencies_parsed_at":"2024-01-23T16:11:57.254Z","dependency_job_id":null,"html_url":"https://github.com/SHUBHAMSHARMA0711/Custom-Unix-Linux-Shell","commit_stats":null,"previous_names":["shubhamsharma0711/custom-unix-linux-shell"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/SHUBHAMSHARMA0711/Custom-Unix-Linux-Shell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHUBHAMSHARMA0711%2FCustom-Unix-Linux-Shell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHUBHAMSHARMA0711%2FCustom-Unix-Linux-Shell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHUBHAMSHARMA0711%2FCustom-Unix-Linux-Shell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHUBHAMSHARMA0711%2FCustom-Unix-Linux-Shell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SHUBHAMSHARMA0711","download_url":"https://codeload.github.com/SHUBHAMSHARMA0711/Custom-Unix-Linux-Shell/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHUBHAMSHARMA0711%2FCustom-Unix-Linux-Shell/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31910585,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-16T18:22:33.417Z","status":"ssl_error","status_checked_at":"2026-04-16T18:21:47.142Z","response_time":69,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","cse231","cse231-iiitd","custom-shell","execvp","fork","iiitd","linux-shell","os","os-assignment","shell","shell-assignment","thread","unix-shell"],"created_at":"2025-04-11T23:43:53.775Z","updated_at":"2026-04-17T01:02:01.162Z","avatar_url":"https://github.com/SHUBHAMSHARMA0711.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shell Description\nThis comprehensive overview provides details on external and internal commands implemented in the shell, along with error-handling mechanisms. Additionally, test cases and assumptions are outlined to guide users in utilizing the shell effectively.\n\n## External Commands\n\n### 1. ls\n    - ls -a\n    - ls -m\n\n### 2. cat\n    - cat -n\n    - cat -E\n\n### 3. date\n    - date -u\n    - date -I\n\n### 4. rm\n    - rm -v\n    - rm -i\n\n### 5. mkdir\n    - mkdir -p\n    - mkdir -v\n\n## Internal Commands\n\n### 1. cd\n    - cd ~\n    - cd ..\n\n### 2. echo\n    - echo *\n    - echo --help\n\n### 3. pwd\n    - pwd -L\n    - pwd -P\n\n## Error Handling\n\n1. **Command Not Found:** If the user enters any command other than the specified ones.\n2. **No Such File or Directory:** In **cat** and **rm** commands for non-existing files, and in **cd** for non-existing directories.\n3. **Invalid Option:** If the user enters an option not handled by the shell.\n4. **Missing Operands:** In **cat** if the user enters it without any argument.\n5. **Cannot Create Directory:** In **mkdir** if the user tries to create a duplicate directory.\n6. **Fork Error (Child Process Not Created):** Error handling for creating a child process using the Fork System Call.\n\n\n## Implementation Details\n\nThe shell can be implemented using both forks and threads. If someone wishes to use threads, they can add `\u0026t` at the end of the command. For example:\n- `ls -a \u0026t`\n- `cat -n cat.c \u0026t`\n- `date -I \u0026t`\n\n  \n## Test Cases\n\n### 1. ls\n   - `ls -a` \u0026 `ls -a \u0026t`\n   - `ls -m` \u0026 `ls -m \u0026t`\n\n### 2. cat\n   - `cat -n cat.c` \u0026 `cat -n cat.c \u0026t`\n   - `cat -E cat.c` \u0026 `cat -E cat.c \u0026t`\n\n### 3. date\n   - `date -u` \u0026 `date -u \u0026t`\n   - `date -I` \u0026 `date -I \u0026t`\n\n### 4. rm hello.c\n   - `rm -v hello.c` \u0026 `rm -v hello.c \u0026t`\n   - `rm -i hello.c` \u0026 `rm -i hello.c \u0026t`\n\n### 5. mkdir newDir\n   - `mkdir -p newDir/newDir2` \u0026 `mkdir -p newDir/newDir2 \u0026t`\n   - `mkdir -v newDir` \u0026 `mkdir -v newDir \u0026t`\n\n## Assumptions\n\n1. No unnecessary arguments will be passed in between or after the command.\n2. **cat** and **rm** commands will not be passed a directory as an argument.\n3. **mkdir** and **rm** commands will not be entered without any arguments.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshubhamsharma0711%2Fcustom-unix-linux-shell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshubhamsharma0711%2Fcustom-unix-linux-shell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshubhamsharma0711%2Fcustom-unix-linux-shell/lists"}