UNIX QUESTIONS 1. How do I list all the files that are in the current directory?
ID: 3856928 • Letter: U
Question
UNIX QUESTIONS
1. How do I list all the files that are in the current directory?
2. What is the command to search all files in your current directory for the word "awesome"?
3. What is the command to use if you want to rename a file called badfile.txt to goodfile.txt
4. How would I change the current directory to a directory called HW_7 that is inside of a directory called Homework, which is inside of your home directory?
5. What command would be use to change the permissions on a file called my_work.txt to allow the file to be executable.
Explanation / Answer
UNIX QUESTIONS
1. How do I list all the files that are in the current directory?
find . -maxdepth 1 -type f
(only files)
ls
(both files and directory)
2. What is the command to search all files in your current directory for the word "awesome"?
ls *awesome*
3. What is the command to use if you want to rename a file called badfile.txt to goodfile.txt
mv badfile.txt goodfile.txt
4. How would I change the current directory to a directory called HW_7 that is inside of a directory called Homework, which is inside of your home directory?
cd ~/Homework/HW_7
5. What command would be use to change the permissions on a file called my_work.txt to allow the file to be executable
chmod +x my_work.txt
If you have any questions or need any further information please let me know...I shall be glad to help you..
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.