Monthly Archives: July 2025

Antranig Vartanian

July 19, 2025

Sometimes all I need to do is

sudo tmutil listlocalsnapshots / \
  | grep TimeMachine \
  | cut -d . -f 4 \
  |  xargs -I% sudo tmutil deletelocalsnapshots %

And suddenly I have like 70GB of more storage on my Mac.

I wish macOS was less… black magic-y.

Antranig Vartanian

July 7, 2025

Sometimes, when I have a long running process on my computer, like scp, rsync or curl I need to know when it’s done, so I don’t check the terminal every minute. That’s when I realized that this is a perfect fit for Apple Script and pwait.

Basically, it looks something like this:

pwait `pgrep xargs` \
  && osascript -e \
    'display notification "Extraction Done" with title "large xargs"'

Now I can go back to work, and I don’t have to check if the job is done every minute. A notification will appear when it’s done.

For remote jobs, I have realized, that I can send a notification to myself, kind of like a self-hosted Pushover, using XMPP, I don’t want to go into the details, but that seems like to be a good solution as well. Maybe I should just use Pushover anyway.