forked from jamf/Jamf-Nation-Extension-Attributes
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CrashPlan_Version.xml
28 lines (28 loc) · 1.28 KB
/
CrashPlan_Version.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?xml version="1.0" encoding="UTF-8"?>
<extensionAttribute>
<displayName>CrashPlan Version</displayName>
<description/>
<dataType>string</dataType>
<scriptContentsMac>#!/bin/sh
#
############################################################################
#
# Extension Attribute checks to display CrashPlan Version with Release number.
#
# Uses CFBundleShortVersionString because this is the "release version number of the bundle"
# Ref: https://developer.apple.com/library/IOS/#documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
#
# Created By Geoffrey O'Brien - geoffrey-obrien@idexx.com
# last modified: 110515
#
############################################################################
#
if [ -d /Applications/CrashPlan.app ] ; then
Edition=$( sudo defaults read /Applications/CrashPlan.app/Contents/Info CFBundleName )
Version=$( sudo defaults read /Applications/CrashPlan.app/Contents/Info CFBundleShortVersionString )
echo "<result>$Edition - $Version</result>"
else
echo "<result>Not Installed</result>"
fi</scriptContentsMac>
<scriptContentsWindows/>
</extensionAttribute>