Microsoft Remote Desktop Version Extension Attribute

bmagistro
New Contributor II

So we are in the process of transitioning to version 10 and wanted a way to get the current version installed on our clients. Below is the script we are using. Tested with version 8 and version 10. Hope this is useful for someone else.

#!/usr/bin/env bash

RESULT="Not Installed"

if [[ -e /Applications/Microsoft Remote Desktop.app ]]; then
  RESULT=$(defaults read /Applications/Microsoft Remote Desktop.app/Contents/Info.plist CFBundleShortVersionString)

  if [[ "$RESULT" =~ ^8. ]]; then
    RESULT=$(defaults read /Applications/Microsoft Remote Desktop.app/Contents/Info.plist CFBundleGetInfoString)
  fi
fi
/bin/echo "<result>$RESULT</result>"
1 REPLY 1

mm2270
Legendary Contributor III

But.. why? Isn't this already captured in regular Application inventory, since it's in Applications?

Or is the issue being addressed with this that MS changed where they were storing the exact version string in the plist as indicated in your script?