j99mac
#1
I am trying to run a script
set admin2 to “admin2”
set Admin to do shell script “sudo dsconfigad -group admin01” & admin2 with administrator
and get the error sudo: no tty present and no askpass program specified
How can I get a osx dsconfigad command to run with veritable
There’s various bits missing in your post, so maybe I’ve got it wrong.
2nd line of your script:
- space missing after ‘admin01’
- at the end ‘privileges’ is missing - the phrase is ‘with administrator privileges’
Last line: veritable what?
Anyway, you shouldn’t use ‘sudo’ and ‘with administrator privileges’ together.
In an AppleScript use ‘administrator privileges’ alone.
That said, I’ve never heard of ‘dsconfigad’, so I do not know whether it can be run in this way.
j99mac
#3
Thanks I got some of the script to work. Dose anyone know how AppleScript like spaces. before a veriable