Advertisement
Guest User

ad info to JSS

a guest
May 21st, 2012
277
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Awk 0.41 KB | None | 0 0
  1. #!/usr/bin/env awk -f
  2.  
  3. BEGIN {
  4.     FS=":";
  5.     user="foo"
  6. }
  7.  
  8. /^JobTitle/{ getline; pos = $0 }
  9. /^Phone/{phone = $2}
  10. /^EMail/{email = $2}
  11. /^Real/{ getline; real = $0}
  12. /^Unique/{uid = $2}
  13. /:company:/{ getline; co = $0}
  14. /:department:/{dept = $2}
  15.  
  16. END {
  17.     args = " -endUsername "user " -realname'"real"' -email" email " -position'" pos "' -phone '" phone "' -department" dept
  18.     system("jamf recon" args)
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement