Hands-on task
xargs: delete files from a list with spaces
After cleaning up the media library, a list of files to delete was collected in /root/obsolete.list — one full path per line, and the names contain spaces. Delete all listed files with a single command using xargs. Everything not on the list must stay — including a file named /srv/media/draft.
- xargs
- xargs -d
- rm
- spaces in file names
- input redirection