Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $users_list = Get-ADUser -Filter *
- If (-not (Test-Path "C:\WorkingDirectory")) { New-Item -ItemType Directory -Path "C:\WorkingDirectory" }
- foreach($user in $users_list)
- {
- $repos = $user.SamAccountName
- New-Item -ItemType Directory -Path "C:\WorkingDirectory\$repos"
- }
Advertisement
Add Comment
Please, Sign In to add comment