How to Automatically Remove 'Where From' Metadata from anyfile on macOS Using Hazel
Tired of those persistent 'Where From' URLs cluttering your downloaded PDFs on macOS? Learn how to set up a powerful Hazel rule with a simple AppleScript to automatically remove this private metadata for good. Automate your file cleanup!

문제 제기:
macOS 사용자들이 겪는 'Where From' 메타데이터 문제 설명. (예: 다운로드한 PDF 파일의 Finder 정보 창에 원치 않는 URL 출처가 표시됨)
수동 제거 방법
방법1. finder 에서 정보가져오기 -> 출처 에서 오른쪽마우스 "URL제거"
방법2. 터미널에서 아래의 xattr
명령어로 확인

실제 터미널에서 해당 정보 삭제
xattr -d com.apple.metadata:kMDItemWhereFroms 경로
아무런 결과값이 안나오면 실행되었음. 혹시 2번 해보길 권함(이유, 1번에 안되는 경우도 있으므로)
Hazel app 을 이용하여 자동화


각각 스크립터를 아래의 명령어로 넣어두었습니다.
xattr -d com.apple.metadata:kMDItemWhereFroms "$1"
필자 같은 경우 Download 폴더에 지정해두었기 때문에 위 작업을 지정하고 run roles now 를 실행하였습니다.
이후 다운로드 폴더에 들어오는 모든 파일의 링크(URL부분)주석 설명은 지워집니다.