![com apple safari plist com apple safari plist](https://cdn.neow.in/forum/uploads/post-71439-1235485277.jpg)
![com apple safari plist com apple safari plist](https://www.lifewire.com/thmb/-XY-rV-baEpNkKSAymE6mZy3hzk=/774x0/filters:no_upscale():max_bytes(150000):strip_icc()/001_back-up-or-move-safari-bookmarks-to-new-mac-2260891-fa5e76125150440088d360ed3515791c.jpg)
(I just tested with the Kindle app, anything should work.) Lockfiles are a standard Unix technique for locking with the "flock" system call, and you can verify this quite easily:Ĭd ~/Library/Preferencesperl -MFcntl=:flock -e 'open FH, " ' Will require to enter an admin password.if user_choice is "Hide" then do shell script "chflags hidden /Library/Preferences/*.plist.lockfile" with administrator privileges do shell script "chflags hidden ~/Library/Preferences/*.plist.lockfile" with administrator privilegeselse if user_choice is "Unhide" then do shell script "chflags nohidden /Library/Preferences/*.plist.lockfile" with administrator privileges do shell script "chflags nohidden ~/Library/Preferences/*.plist.lockfile" with administrator privilegesend if Hide Unhide plist.lockfile - version 2.0display dialog ¬ "Hide or Unhide the plist.lockfile files in the Preferences folders in /Library and ~/Library." & return & ¬ return & "Will require to enter an administrator password." & return with title "Hide or Unhide the ¬ plist.lockfile files" buttons default button 1 giving up after 60set dialogResult to resultset giveUp to gave up of dialogResultif giveUp is true then error number -128 - Cancel on giving up to cancel the t user_choice to button returned of dialogResult - Set the user choice.- Process the user choice.