You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

💡 Did you know?

⏺ If you can't accept iCloud Terms and Conditions... Learn more >

⏺ If you don't see your iCloud notes in the Notes app... Learn more >

find/delete older iCloud files with launchctl

I'm regularly storing archives on iCloud, while also deleting older archives with the command


find ~/Library/Mobile\ Documents/com~apple~CloudDocs -name "*.tar.bz2" -mtime +6 -delete


This command works fine when entered manually, but it does nothing when part of a script executed by launchctl. Other commands in that script, like preparing and moving the current archive to iCloud, work fine, though. The launchd plist lists myself as User.


I'm stumped, any help would be appreciated.



Mac mini (M4)

Posted on Nov 17, 2024 8:12 AM

Reply

There are no replies.

find/delete older iCloud files with launchctl

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.