-
Notifications
You must be signed in to change notification settings - Fork 25
Find Implementation #30
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
base: main
Are you sure you want to change the base?
Conversation
…'s recursive properties
…nt within existing while loop. Pardon our (commented out) dust
|
I am going to review this PR. |
|
Verification Testing "find / c* Code Walkthrough Checklist [ ✔ ] Does the code achieve its intended purpose? |
|
Verification Testing → to test how well the recursive search works Code Walkthrough I also agree with the logical error mentioned above. Formatting Checklist
Code Checks:
Very impressive job guys!! : ) |
|
Looks good!! I am not a huge fan of how it prints "found!" all over the place but I will chalk that up to personal preference :-) Behavior seems all good to me. I do agree that the extra buffer needs to go, and so does the logic error (although it's not really causing problems in most cases, it should still be fixed). It's easy to get it to mess up the formatted output, especially with slashes. Searching in ., ./, and / all produce different outputs, which is okay, except with / it actually displays two slashes (which is technically okay) 4.75/5 0.25 -> fix errors mentioned above. |

This pull request addresses issue #7.
The find command finds the path for a given file in a directory recursively. If a directory is not given then it will find the path of the file in the current directory. We added a test directory with text files to ensure the command is working. If a file does not exist in the current directory, then it will print nothing.
find
Examples:
find . test2.txt
path: /tests/test2.txt
find . test1.txt
path: /tests/itests/test1.txt
path: /tests/tests1.txt