특정 파일을 제외하고 하위 디렉토리의 모든 디렉토리와 파일을 지울 때..

물어보길 원할 때 다음과 같은 커맨드를 사용하면 유용하다.


$ find . -maxdepth 1 -type d -not -name "google" -not -name "gift-wine*" -exec rm -ri {} \;


결과는 다음 화면이 나온다.

rm: "." and ".." may not be removed

하나씩 물어봄


Posted by '김용환'
,