Skip to main content
Jamf Nation, hosted by Jamf, is the largest Apple IT management community in the world. Dialog with your fellow IT professionals, gain insight about Apple device deployments, share best practices and bounce ideas off each other. Join the conversation.
Posted: by scott.mielke
Product: Mac OS X
Downloads: 592


[script]sudo <mountPoint> <computerName> <currentUsername> <enableFileSharing>[/script]

If there is a hardcoded value specified for <enableFileSharing> in the script, or if the parameter is not passed by The Casper Suite, the hardcoded value in the script will be used.

The data that is specified for the <enableFileSharing> parameter should be specified in one of
the following formats:

"t" "T" "true" "True" "TRUE"
"f" "F" "false" "False" "FALSE"
"y" "Y" "yes" "Yes "YES"
"n" "N" "no" "No" "NO"


This script enables or disables the Personal File Sharing preference on Mac OS X 10.3 or later. If there is a hardcoded value specified in the script for <enableFileSharing> it will be used. The value can also be populated from the JSS by deploying the script as a policy payload. Since the Casper Suite defines the first three parameters of a bash script as (1) Mount Point, (2) Computer Name and (3) username, the script uses the fourth parameter ($4) as the passable parameter (variable) to acquire the status of <enableFileSharing> and to set the enableFileSharing status.


Generating Preview...