How to add users to a group with the command line on a mac

To do what it says on the tin (or at least in the title) run:


sudo dscl -p / -append /Groups/GROUPNAMEHERE users USERNAMESHERE

It was a pain to find how to do this, so I thought I would post it up to make it easier for others. I discovered that www (the Mac apache user) is not in the wheel group so I added it. It conveniently allows me to chgrp stuff for apache to be able to write too as well as my own user.

Technorati Tags:
, ,

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • del.icio.us
  • Digg
  • DZone
  • Ma.gnolia
  • MisterWong
  • Reddit
  • scuttle
  • Slashdot
  • SphereIt
  • StumbleUpon
  • YahooMyWeb
  • Wists
discussion by DISQUS
Add New Comment