Skip to content

Instantly share code, notes, and snippets.

@homebysix
Last active August 29, 2015 14:06
Show Gist options
  • Save homebysix/07b50daa24a8aae11e0c to your computer and use it in GitHub Desktop.
Save homebysix/07b50daa24a8aae11e0c to your computer and use it in GitHub Desktop.
bash_version.sh
#!/bin/bash
###
#
# Name: bash_version.sh
# Description: Casper extension attribute that returns the installed
# version of /bin/bash.
# Author: Elliot Jordan <elliot@lindegroup.com>
# Created: 2014-09-25
# Last Modified: 2014-09-25
# Version: 1.0
#
###
bash_vers_full=`/bin/bash --version`
bash_vers_short=`echo $bash_vers_full | awk {'print $4'}`
echo "<result>$bash_vers_short</result>"
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment