Currently I am writing a powershell script to automate some security measures and I have run into a small problem.
icacls myDirectory /inheritance:r /grant:r 'Administrators:F' $myGroup + ':F'
will fail as $myGroup gets tacked onto the icacls call and fails to properly add permissions to both groups. This is on Windows 7 and from the context of powershell.