Hey all, I wrote a script to add users to a certain dscl group and I was wondering how can I get an interaction pop up that says "Please Type in your Name" and the name is then saved as lets say $name?
Solved
Scripters Help! User Interaction Stored as Variable

Best answer by Matt11
#!/bin/bash
#####################################
# Get Current Logged In User #
#####################################
user=`ls -l /dev/console | cut -d " " -f 4`
#####################################
# Move User to Local Admin Group #
#####################################
dscl . append /Groups/admin GroupMembership $user
Looks like this works well. Wonder if this can automated with an Extension Attribute :D
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.