Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
FlashVersion=$(defaults read /Library/Internet\ Plug-Ins/Flash\ Player.plugin/Contents/Info.plist CFBundleShortVersionString)
echo "<result>$FlashVersion</result>"
exit 0
#!/bin/sh
CD="/path/to/cocoaDialog.app/Contents/MacOS/cocoaDialog"
# pass the title, text, and Icon via $4, $5, $6, and timeout via $7
cdTitle=$4
cdText=$5
# what icon to use
# if no icon is given, set a default
if [[ -z "$6" ]]; then
cdIcon="/private/var/inte/icons/globeDownload.icns"
else
touch /Library/Application\ Support/Macromedia/mms.cfg | echo "AutoUpdateDisable=1" > /Library/Application\ Support/Macromedia/mms.cfg
user=`/usr/bin/defaults read /Library/Preferences/com.apple.loginwindow lastUserName`
CP_USER_HOME="/Users/$user"
userGroup=`id -gn "$user"`
CP_USER_NAME="$user"
startDesktop=false
#!/bin/sh
# unload CrashPlan LaunchDaem if it exists
if [[ -e /Library/LaunchDaemons/com.crashplan.engine.plist ]]; then
launchctl unload /Library/LaunchDaemons/com.crashplan.engine.plist
/Library/Application\ Support/CrashPlan/Uninstall.app/Contents/Resources/uninstall.sh
rm -rf /Library/Application\ Support/CrashPlan
fi
YosemiteVM:Preferences integer$ defaults read /Users/integer/Library/Containers/com.microsoft.rdc.mac/Data/Library/Preferences/com.microsoft.rdc.mac.plist
{
QmoteUUIDKey = "ff870b10-7e8e-47c2-98bd-f14f3f0cd1b0";
"bld_number" = 26665;
"bookmarklist.expansionStates" = {
GENEREAL = 1;
};
"bookmarkorder.ids" = (
"{2a3925d6-659e-456e-ab03-86919b30b54b}"
);
YosemiteVM:Preferences integer$ defaults read /Users/integer/Library/Containers/com.microsoft.rdc.mac/Data/Library/Preferences/com.microsoft.rdc.mac.plist
{
QmoteUUIDKey = "ff870b10-7e8e-47c2-98bd-f14f3f0cd1b0";
"bld_number" = 26665;
"bookmarklist.expansionStates" = {
GENEREAL = 1;
};
"bookmarkorder.ids" = (
"{2a3925d6-659e-456e-ab03-86919b30b54b}"
);
@stevewood-tx
stevewood-tx / gist:227c2294c935a0f48f28
Last active February 29, 2016 22:17
MS RDC 8 Bookmark Script
#!/bin/sh
# date: 18 Jun 2014
# Name: RDC-Connection.sh
# Author: Steve Wood (swood@integer.com)
# updated: 29 Feb 2016 - included line to add remote program to start on connection for @gmarnin
# grab the logged in user's name
loggedInUser=`/bin/ls -l /dev/console | /usr/bin/awk '{ print $3 }'`
## Set global variables
LOGPATH='/path/to/your/logs'
JSSURL='https://<yourjssurl>'
JSSCONTACTTIMEOUT=120 # amount of time to wait before timing out waiting for connection
LOGFILE=$LOGPATH/deployment-$(date +%Y%m%d-%H%M).logging #re-name to whatever name you want
VERSION=10.11.5
## Setup logging
if [[ ! -d $LOGPATH ]]; then