Cisco
200-901 · Question #148
The project is migrated to a new codebase, the "old_project" directory must be deleted. The directory has multiple read-only files, and it must be deleted recursively without prompting for…
The correct answer is A. rm -rf old_project. To remove non-empty directories and all the files without being prompted, use rm with the -r (recursive) and -f. https://linuxize.com/post/how-to-remove-files-and-directories-using-linux-command-line/
Infrastructure and Automation
Question
The project is migrated to a new codebase, the "old_project" directory must be deleted. The directory has multiple read-only files, and it must be deleted recursively without prompting for confirmation. Which bash command must be used?
Options
- Arm -rf old_project
- Brm -r old_project
- Crmdir -p old_project
- Drmdir old_project
How the community answered
(19 responses)- A95% (18)
- D5% (1)
Explanation
To remove non-empty directories and all the files without being prompted, use rm with the -r (recursive) and -f. https://linuxize.com/post/how-to-remove-files-and-directories-using-linux-command-line/
Topics
#Bash commands#File system management#Linux utilities
Community Discussion
No community discussion yet for this question.