vietnamese crab exporter

An AppleScript trick turns any NAS device into a Time Machine drive

genius
You can turn any network attached storage device into a Time Machine back-up drive with one simple step.

Simply download this app package and drag your drive onto it. The script adds the drive as a Time Machine capable device and then you can simply add it under Time Machine System Preferences.

The full script is right here if you want to roll your own:

on open names
set volumeName to names as text
set macAddress to (do shell script "ifconfig en0 | grep ether | tr -d '\11' | sed s/ether/ | sed 's/ /g' | sed s/://g")
set hostName to (do shell script "hostname -fs")
tell application "Finder"
set theSize to round (((capacity of startup disk) / 1024 / 1024) / 1024)
end tell

do shell script "defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1" with administrator privileges

do shell script "sudo hdiutil create -size " & theSize & " -type SPARSEBUNDLE -nospotlight -volname \"Backup of " & hostName & "\" -fs \"Journaled HFS+\" ~/" & hostName & "_" & macAddress & ".sparsebundle" with administrator privileges
do shell script "mv ~/" & hostName & "_" & macAddress & ".sparsebundle /Volumes/" & volumeName & "/" with administrator privileges

tell application "Finder" to eject volumeName

Techcrunch event

This Week Only: Buy one pass, get the second at 50% off


Your next round. Your next hire. Your next breakout opportunity. Find it at TechCrunch Disrupt 2026, where 10,000+ founders, investors, and tech leaders gather for three days of 250+ tactical sessions, powerful introductions, and market-defining innovation. Register before May 8 to bring a +1 at half the cost.

This Week Only: Buy one pass, get the second at 50% off


Your next round. Your next hire. Your next breakout opportunity. Find it at TechCrunch Disrupt 2026, where 10,000+ founders, investors, and tech leaders gather for three days of 250+ tactical sessions, powerful introductions, and market-defining innovation. Register before May 8 to bring a +1 at half the cost.

San Francisco, CA | October 13-15, 2026

tell application "System Preferences"
activate
end tell

tell application "System Events"
tell application process "System Preferences"
set frontmost to true
click menu item "Time Machine" of menu "View" of menu bar 1
end tell
end tell

end open

via MacOSXHints

Topics

, , ,
Loading the next article
Error loading the next article