현재 폴더에 다수의 *.pairs 파일과 FastCommunityMH라는 실행파일이 존재할 때, 다음과 같은 shell script로 여러 파일에 대해 같은 명령을 처리할 수 있다.

$ for file in *.pairs; do ./FastCommunityMH -f "$file"; done


Reference