Created
January 3, 2010 05:59
-
-
Save epall/267844 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using terms from application "Quicksilver" | |
on process text ThisClipping | |
do shell script "/Users/epall/bin/addreplacement " & ThisClipping | |
end process text | |
end using terms from |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
replace=$1 | |
with=$2 | |
commands="Add :NSUserReplacementItems:0 dict\n\ | |
Add :NSUserReplacementItems:0:on integer 1\n\ | |
Add :NSUserReplacementItems:0:replace string $replace\n\ | |
Add :NSUserReplacementItems:0:with string $with\n\ | |
Save\nExit\n" | |
echo $commands | /Users/epall/bin/PlistBuddy ~/Library/Preferences/.GlobalPreferences.plist 2>&1 > /dev/null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment