Created
February 24, 2019 15:59
-
-
Save waldekmastykarz/f66e7154a96a60ff65bc96cdcc7af425 to your computer and use it in GitHub Desktop.
Sets the specified user as site owner for a number of test sites
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i in {1..10000}; | |
do | |
label="$i" | |
if (( $i < 10 )); then | |
label="0$label" | |
fi | |
if (( $i < 100 )); then | |
label="0$label" | |
fi | |
if (( $i < 1000 )); then | |
label="0$label" | |
fi | |
if (( $i < 10000 )); then | |
label="0$label" | |
fi | |
label="PublicTeam$label" | |
echo "Updating owners $label..." | |
o365 spo site classic set --url "https://contoso.sharepoint.com/sites/$label" --owners [email protected] | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment