2

Is it possible to fine-tune the "Open safe files after downloading" setting in Safari? For example, to make Safari open files like ".ical" et. al., but not Zip-files.

If macOS has no built-in support for this, could a solution be a UNIX script daemon that instantly detects new files in the Downloads directory and opens files with certain extensions?

5

The preferences file is located at ~/Library/Preferences/com.apple.DownloadAssessment.plist

If the file doesn't exist, then create it and include the following:

<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com-PropertyList-1.0.dtd"> 
<plist version="1.0"> 
    <dict> 
        <key>LSRiskCategorySafe</key> 
        <dict> 
            <key>LSRiskCategoryExtensions</key> 
            <array> 
                <string>docx</string> 
                <string>xlsx</string> 
            </array> 
        </dict> 
    </dict> 
</plist>

To exclude Zip files, add the following to the preferences:

<dict> 
    <key>LSRiskCategoryNeutral</key> 
    <dict> 
        <key>LSRiskCategoryExtensions</key> 
        <array> 
            <string>zip</string> 
        </array> 
    </dict> 
</dict>

More info at: Source

  • You can also hold the alt button when clicking a link on a per-download basis – akostar Aug 5 '18 at 6:54
  • So they thought of it. That's beautiful! Thanks for a quick and precise answer! – forthrin Aug 5 '18 at 10:57
  • Not a problem, glad I could help! – akostar Aug 5 '18 at 13:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .