Created
January 11, 2016 01:22
-
-
Save brianmichel/be97f7aa3884cb8546ac 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
on onConfirmUninstall() | |
set applicationName to "Slack" | |
try | |
display dialog "Are you sure you want to reset " & applicationName & "?" | |
set uninstallScript to quoted form of POSIX path of (path to resource "uninstall.bash") | |
do shell script "bash " & uninstallScript with administrator privileges | |
display dialog "Successfully Reset " & applicationName buttons {"OK"} default button "OK" | |
on error err | |
if err contains "User canceled" then | |
display dialog "Canceled " & applicationName & " Uninstall" buttons {"OK"} default button "OK" | |
else | |
display dialog "We’re sorry, but there was an error resetting " & applicationName & " described as: " & err buttons {"OK"} default button "OK" | |
end if | |
end try | |
end onConfirmUninstall | |
onConfirmUninstall() |
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
#!/usr/bin/env bash | |
#rm -rf /Applications/Slack.app | |
defaults delete com.tinyspeck.slackmacgap | |
rm -rf ~/Library/Application\ Support/Slack/ | |
rm -rf ~/Library/Containers/com.tinyspeck.slackmacgap/ | |
rm -rf ~/Library/Preferences/com.tinyspeck.slackmacgap.plist | |
rm -rf ~/Library/Caches/com.tinyspeck.slackmacgap/ | |
rm -rf ~/Library/Cookies/com.tinyspeck.slackmacgap.binarycookies | |
rm -rf ~/Library/Saved\ Application\ State/com.tinyspeck.slackmacgap.savedState | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment