├── .github
├── CONTRIBUTING.md
├── ISSUE_TEMPLATE.md
└── PULL_REQUEST_TEMPLATE.md
├── LICENSE
├── README.md
└── Scripts
├── Sync-KFM-Deployment
├── KFM_Deployment.ps1
└── readme.md
├── readme-template.md
├── readme.md
└── sample
├── readme.md
└── sample.ps1
/.github/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contribution Guidance
2 |
3 | If you'd like to contribute to this repository, please read the following guidelines. Contributors are more than welcome to share your learnings with others from centralized location.
4 |
5 | ## Code of Conduct
6 |
7 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
8 | For more information, see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
9 |
10 | ## Question or Problem?
11 |
12 | Please do not open GitHub issues for general support questions as the GitHub list should be used for script requests and bug reports. This way we can more easily track actual issues or bugs from the scripts and keep the general discussion separate from the actual script samples.
13 |
14 | ## Typos, Issues, Bugs and contributions
15 |
16 | Whenever you are submitting any changes to the OneDrive repositories, please follow these recommendations.
17 |
18 | * Always fork repository to your own account for applying modifications
19 | * Do not combine multiple changes to one pull request, please submit for example any samples and documentation updates using separate PRs
20 | * If you are submitting multiple samples, please create specific PR for each of them
21 | * If you are submitting typo or documentation fix, you can combine modifications to single PR where suitable
22 |
23 | ## Sample Naming and Structure Guidelines
24 |
25 | When you are submitting a new sample, it has to follow up below guidelines
26 |
27 | * You will need to have a README file for your contribution, which is based on [provided template](../samples/README-template.md) under the scripts folder. Please copy this template and update accordingly. README has to be named as README.md with capital letters.
28 | * Please include as much as possible information on the exact use case of your script. More information will help on others to understand the value of your script. You can add links and images as needed.
29 |
30 | * README template contains specific tracking image as a final entry in the page with img tag by default to https://telemetry.sharepointpnp.com/onedrive-admin-scripts/scripts/readme-template. This is transparent image, which is used to track popularity of individual samples in GitHub.
31 |
32 | * Updated the image src element according with repository name and folder information. If your sample is for example in samples folder and named as known-folder-move, src element should be updated as https://telemetry.sharepointpnp.com/onedrive-admin-scripts/script/known-folder-move
33 |
34 | * When you are submitting a new script, please name the sample solution folder accordingly
35 | * Do not use words "sample", "script" or "onedrive" in the folder or sample name - these are scripts for OneDrive management, so no reason to repeat that in the name
36 |
37 | * Do not use period/dot in the folder name of the provided sample
38 |
39 | ## Submitting Pull Requests
40 |
41 | Here's a high level process for submitting new samples or updates to existing ones.
42 |
43 | 1. Sign the Contributor License Agreement (see below)
44 | 1. Fork this repository [OneDrive/onedrive-admin-scripts](https://github.com/OneDrive/onedrive-admin-scripts) to your GitHub account
45 | 1. Create a new branch off the `master` branch for your fork for the contribution
46 | 1. Include your changes to your branch
47 | 1. Commit your changes using descriptive commit message * These are used to track changes on the repositories for monthly communications
48 | 1. Create a pull request in your own fork and target `master` branch
49 | 1. Fill up the provided PR template with the requested details
50 |
51 | Before you submit your pull request consider the following guidelines:
52 |
53 | * Make sure you have a link in your local cloned fork to the [OneDrive/onedrive-admin-scripts](https://github.com/OneDrive/onedrive-admin-scripts):
54 |
55 | ```shell
56 | # check if you have a remote pointing to the Microsoft repo:
57 | git remote -v
58 |
59 | # if you see a pair of remotes (fetch & pull) that point to https://github.com/OneDrive/onedrive-admin-scripts, you're ok... otherwise you need to add one
60 |
61 | # add a new remote named "upstream" and point to the Microsoft repo
62 | git remote add upstream https://github.com/OneDrive/onedrive-admin-scripts.git
63 | ```
64 |
65 | * Make your changes in a new git branch:
66 |
67 | ```shell
68 | git checkout -b my-awesome-script-name master
69 | ```
70 |
71 | * Ensure your fork is updated and not behind the upstream **onedrive-admin-scripts** repo. Refer to these resources for more information on syncing your repo:
72 | * [GitHub Help: Syncing a Fork](https://help.github.com/articles/syncing-a-fork/)
73 | * [Keep Your Forked Git Repo Updated with Changes from the Original Upstream Repo](http://www.andrewconnell.com/blog/keep-your-forked-git-repo-updated-with-changes-from-the-original-upstream-repo)
74 | * For a quick cheat sheet:
75 |
76 | ```shell
77 | # assuming you are in the folder of your locally cloned fork....
78 | git checkout master
79 |
80 | # assuming you have a remote named `upstream` pointing official **onedrive-admin-scripts** repo
81 | git fetch upstream
82 |
83 | # update your local master to be a mirror of what's in the main repo
84 | git pull --rebase upstream master
85 |
86 | # switch to your branch where you are working, say "my-awesome-script-name"
87 | git checkout my-awesome-script-name
88 |
89 | # update your branch to update it's fork point to the current tip of master & put your changes on top of it
90 | git rebase master
91 | ```
92 |
93 | * Push your branch to GitHub:
94 |
95 | ```shell
96 | git push origin my-awesome-script-name
97 | ```
98 |
99 | ## Merging your Existing Github Projects with this Repository
100 |
101 | If the sample you wish to contribute is stored in your own Github repository, you can use the following steps to merge it with the this repository:
102 |
103 | * Fork the `onedrive-admin-scripts` repository from GitHub
104 | * Create a local git repository
105 |
106 | ```shell
107 | md onedrive-admin-scripts
108 | cd onedrive-admin-scripts
109 | git init
110 | ```
111 |
112 | * Pull your forked copy of onedrive-admin-scripts into your local repository
113 |
114 | ```shell
115 | git remote add origin https://github.com/yourgitaccount/onedrive-admin-scripts.git
116 | git pull origin dev
117 | ```
118 |
119 | * Pull your other project from github into the scripts folder of your local copy of onedrive-admin-scripts
120 |
121 | ```shell
122 | git subtree add --prefix=scripts/projectname https://github.com/yourgitaccount/projectname.git master
123 | ```
124 |
125 | * Push the changes up to your forked repository
126 |
127 | ```shell
128 | git push origin master
129 | ```
130 |
131 | ## Signing the CLA
132 |
133 | Before we can accept your pull requests you will be asked to sign electronically Contributor License Agreement (CLA), which is prerequisite for any contributions to PnP repository. This will be one time process, so for any future contributions you will not be asked to re-sign anything. After the CLA has been signed, our PnP core team members will have a look on your submission for final verification of the submission. Please do not delete your development branch until the submission has been closed.
134 |
135 | You can find Microsoft CLA from the following address - https://cla.microsoft.com.
136 |
137 | Thank you for your contribution.
138 |
139 | > Sharing is caring.
140 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | > Use the following form to submit an issue only if it's related to samples in this repo. If you have an issue related to the OneDrive or its documentation, please submit the issue at [https://github.com/OneDrive/onedrive-api-docs/issues/new](https://github.com/OneDrive/onedrive-api-docs/issues/new). This will help us respond to your issue faster.
2 | >
3 | > ----
4 | >
5 | > Thank you for reporting an issue or suggesting an enhancement. We appreciate your feedback - to help the team to understand your needs, please complete the below template to ensure we have the necessary details to assist you.
6 | >
7 | > _(DELETE THIS PARAGRAPH AFTER READING)_
8 |
9 | ## Category
10 |
11 | - [ ] Question
12 | - [ ] Bug
13 | - [x] Enhancement
14 |
15 | > For the above list, an empty checkbox is [ ] as in [SPACE]. A checked checkbox is [x] with no space between the brackets. Use the `PREVIEW` tab at the top right to preview the rendering before submitting your issue.
16 | >
17 | > _(DELETE THIS PARAGRAPH AFTER READING)_
18 |
19 | ## Expected or Desired Behavior
20 |
21 | > _If you are reporting a bug, please describe the expected behavior. If you are suggesting an enhancement please describe thoroughly the enhancement, how it can be achieved, and expected benefit._
22 | >
23 | > _(DELETE THIS PARAGRAPH AFTER READING)_
24 |
25 | ## Observed Behavior
26 |
27 | > _If you are reporting a bug, please describe the behavior you expected to occur when performing the action. If you are making a suggestion, you can delete this section._
28 | >
29 | > _(DELETE THIS PARAGRAPH AFTER READING)_
30 |
31 | ## Steps to Reproduce
32 |
33 | > _If you are reporting a bug please describe the steps to reproduce the bug in sufficient detail to allow testing. Only way to fix things properly, is to have sufficient details to reproduce it. If you are making a suggestion, you can delete this section._
34 | >
35 | > _(DELETE THIS PARAGRAPH AFTER READING)_
36 |
37 | ## Submission Guidelines
38 |
39 | > - All suggestions or bugs are welcome, please let us know what's on your mind.
40 | > - If you are reporting an issue around any of the samples, please ensure that you have clear reference on the sample and possibly script file, which should be fixed.
41 | > - Remember to include sufficient details and context.
42 | > - If you have multiple suggestions or bugs please submit them in separate bugs so we can track resolution.
43 | >
44 | > _(DELETE THIS PARAGRAPH AFTER READING)_
45 |
46 | Thanks for your contribution! Sharing is caring.
47 |
--------------------------------------------------------------------------------
/.github/PULL_REQUEST_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | | Q | A |
2 | | --------------- | --------------------------------------- |
3 | | Bug fix? | no - yes? |
4 | | New feature? | no - yes? |
5 | | New script? | no - yes? |
6 | | Related issues? | fixes #X, partially #Y, mentioned in #Z |
7 |
8 | ## What's in this Pull Request?
9 |
10 | > Please describe the changes in this PR. Sample description or details around bugs which are being fixed.
11 | >
12 | > _(DELETE THIS PARAGRAPH AFTER READING)_
13 |
14 | ## Guidance
15 |
16 | > *Please update this PR information accordingly. We'll use this as part of our release notes in monthly communications.*
17 | >
18 | > *Please target your PR to `master` branch.*
19 | >
20 | > _(DELETE THIS PARAGRAPH AFTER READING)_
21 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | OneDrive Scripts for Administrators
2 | Copyright (c) Microsoft Corporation
3 | All rights reserved.
4 |
5 | MIT License
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in all
15 | copies or substantial portions of the Software.
16 |
17 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 | SOFTWARE.
24 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # OneDrive Scripts for Administrators
2 |
3 | This repository is home to scripts that might be useful to OneDrive Administrators.
4 |
5 | ## Microsoft Open Source Code of Conduct
6 |
7 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
8 | For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
9 |
--------------------------------------------------------------------------------
/Scripts/Sync-KFM-Deployment/KFM_Deployment.ps1:
--------------------------------------------------------------------------------
1 | <#
2 | .DESCRIPTION
3 | Script to gather KFM state that can help KFM planning and deployment.
4 |
5 | The sample scripts are not supported under any Microsoft standard support
6 | program or service. The sample scripts are provided AS IS without warranty
7 | of any kind. Microsoft further disclaims all implied warranties including,
8 | without limitation, any implied warranties of merchantability or of fitness for
9 | a particular purpose. The entire risk arising out of the use or performance of
10 | the sample scripts and documentation remains with you. In no event shall
11 | Microsoft, its authors, or anyone else involved in the creation, production, or
12 | delivery of the scripts be liable for any damages whatsoever (including,
13 | without limitation, damages for loss of business profits, business interruption,
14 | loss of business information, or other pecuniary loss) arising out of the use
15 | of or inability to use the sample scripts or documentation, even if Microsoft
16 | has been advised of the possibility of such damages.
17 |
18 | Author: Carter Green - cagreen@microsoft.com
19 |
20 | Deployment Guidance: https://docs.microsoft.com/en-us/onedrive/redirect-known-folders
21 | #>
22 | #CODE STARTS HERE
23 |
24 |
25 | #TenantID is now a required parameter. Use -GivenTenantID to set TenantID, e.g. "-GivenTenantID = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'"
26 | #OutputPath is now a required parameter. Use -OutputPath to designate location for logs, e.g. "-OutputPath = 'C:\...\Desktop\' + $env:USERNAME + "_" + $env:COMPUTERNAME + '.txt'"
27 | #Parameters will now be asked for upon execution of the script if not provided in the command line that runs the script.
28 | param(
29 | [parameter(Mandatory=$true, HelpMessage="Specify the tenant ID, e.g. xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx")]
30 | [ValidateNotNullOrEmpty()]
31 | [string]$GivenTenantID,
32 |
33 | [parameter(Mandatory=$true, HelpMessage='Specify the output path for log files. Example file path: C:\...\Desktop\ + $env:USERNAME + "_" + $env:COMPUTERNAME + ".txt" ')]
34 | [ValidateNotNullOrEmpty()]
35 | [string]$OutputPath
36 | )
37 |
38 | $PolicyState3 = ''
39 | $PolicyState4 = ''
40 | $KFMBlockOptInSet = 'False'
41 | $KFMBlockOptOutSet = 'False'
42 | $SpecificODPath = ''
43 | $TotalItemsNotInOneDrive = 0
44 | $TotalSizeNotInOneDrive = 0
45 | [Long]$DesktopSize = 0
46 | [Long]$DocumentsSize = 0
47 | [Long]$PicturesSize = 0
48 | $DesktopItems = 0
49 | $DocumentsItems = 0
50 | $PicturesItems = 0
51 |
52 | $DesktopPath = [environment]::GetFolderPath("Desktop")
53 | $DocumentsPath = [environment]::GetFolderPath("MyDocuments")
54 | $PicturesPath = [environment]::GetFolderPath("MyPictures")
55 |
56 | $ODAccounts = Get-ChildItem -Path HKCU:\Software\Microsoft\OneDrive\Accounts -name
57 |
58 | $ODPath = foreach ($account in $ODAccounts){
59 | If($account -notlike 'Personal'){
60 | 'HKCU:\Software\Microsoft\OneDrive\Accounts\' + $account
61 | }
62 | }
63 |
64 | foreach ($path in $ODPath){
65 | $ConfiguredTenantID = Get-ItemPropertyValue -path $path -name ConfiguredTenantID
66 | If ($GivenTenantID -eq $ConfiguredTenantID){
67 | $SpecificODPath = (Get-ItemPropertyValue -path $path -name UserFolder) + "\*"
68 | $KFMScanState = Get-ItemPropertyValue -path $path -name LastMigrationScanResult
69 | break
70 | }
71 | }
72 |
73 | $KFMGPOEligible = (($KFMScanState -ne 40) -and ($KFMScanState -ne 50))
74 |
75 | $DesktopInOD = ($DesktopPath -like $SpecificODPath)
76 | $DocumentsInOD = ($DocumentsPath -like $SpecificODPath)
77 | $PicturesInOD = ($PicturesPath -like $SpecificODPath)
78 |
79 | if(!$DesktopInOD){
80 | foreach ($item in (Get-ChildItem $DesktopPath -recurse | Where-Object {-not $_.PSIsContainer} | ForEach-Object {$_.FullName})) {
81 | $DesktopSize += (Get-Item $item).length
82 | $DesktopItems++
83 | }
84 | }
85 |
86 | if(!$DocumentsInOD){
87 | foreach ($item in (Get-ChildItem $DocumentsPath -recurse | Where-Object {-not $_.PSIsContainer} | ForEach-Object {$_.FullName})) {
88 | $DocumentsSize += (Get-Item $item).length
89 | $DocumentsItems++
90 | }
91 | }
92 |
93 | if(!$PicturesInOD){
94 | foreach ($item in (Get-ChildItem $PicturesPath -recurse | Where-Object {-not $_.PSIsContainer} | ForEach-Object {$_.FullName})) {
95 | $PicturesSize += (Get-Item $item).length
96 | $PicturesItems++
97 | }
98 | }
99 |
100 | $TotalItemsNotInOneDrive = $DesktopItems + $DocumentsItems + $PicturesItems
101 | $TotalSizeNotInOneDrive = $DesktopSize + $DocumentsSize + $PicturesSize
102 |
103 | $PolicyState1 = Get-ItemPropertyValue -path HKLM:\SOFTWARE\Policies\Microsoft\OneDrive -name KFMOptInWithWizard
104 | $KFMOptInWithWizardSet = ($PolicyState1 -ne $null) -and ($PolicyState1 -eq $GivenTenantID)
105 |
106 | $PolicyState2 = Get-ItemPropertyValue -path HKLM:\SOFTWARE\Policies\Microsoft\OneDrive -name KFMSilentOptIn
107 | $KFMSilentOptInSet = $PolicyState2 -eq $GivenTenantID
108 |
109 | Try{
110 | $PolicyState3 = Get-ItemPropertyValue -path HKLM:\SOFTWARE\Policies\Microsoft\OneDrive -name KFMBlockOptIn
111 | $KFMBlockOptInSet = ($PolicyState3 -ne $null) -and ($PolicyState3 -eq 1)
112 | }Catch{}
113 |
114 | Try{
115 | $PolicyState4 = Get-ItemPropertyValue -path HKLM:\SOFTWARE\Policies\Microsoft\OneDrive -name KFMBLockOptOut
116 | $KFMBlockOptOutSet = ($PolicyState4 -ne $null) -and ($PolicyState4 -eq 1)
117 | }Catch{}
118 |
119 | $PolicyState5 = Get-ItemPropertyValue -path HKLM:\SOFTWARE\Policies\Microsoft\OneDrive -name KFMSilentOptInWithNotification
120 | $SendNotificationWithSilent = $PolicyState5 -eq 1
121 |
122 | $ODVersion = Get-ItemPropertyValue -Path HKCU:\Software\Microsoft\OneDrive -Name Version
123 |
124 |
125 |
126 | Set-Content $OutputPath "$KFMGPOEligible | Device_is_KFM_GPO_eligible"
127 | if(!$DesktopInOD -or !$DocumentsInOD -or !$PicturesInOD){
128 | Add-Content $OutputPath "$TotalItemsNotInOneDrive | Total_items_not_in_OneDrive"
129 | Add-Content $OutputPath "$TotalSizeNotInOneDrive | Total_size_bytes_not_in_OneDrive`n"
130 | }
131 | Add-Content $OutputPath "$DesktopInOD | Desktop_is_in_OneDrive"
132 | if(!$DesktopInOD){
133 | Add-Content $OutputPath "$DesktopItems | Desktop_items"
134 | Add-Content $OutputPath "$DesktopSize | Desktop_size_bytes`n"
135 | }
136 | Add-Content $OutputPath "$DocumentsInOD | Documents_is_in_OneDrive"
137 | if(!$DocumentsInOD){
138 | Add-Content $OutputPath "$DocumentsItems | Documents_items"
139 | Add-Content $OutputPath "$DocumentsSize | Documents_size_bytes`n"
140 | }
141 | Add-Content $OutputPath "$PicturesInOD | Pictures_is_in_OneDrive `n"
142 | if(!$PicturesInOD){
143 | Add-Content $OutputPath "$PicturesItems | Pictures_items"
144 | Add-Content $OutputPath "$PicturesSize | Pictures_size_bytes`n"
145 | }
146 | Add-Content $OutputPath "$KFMOptInWithWizardSet | KFM_Opt_In_Wizard_Set"
147 | Add-Content $OutputPath "$KFMSilentOptInSet | KFM_Silent_Opt_In_Set"
148 | Add-Content $OutputPath "$SendNotificationWithSilent | KFM_Silent_With_Notification_Set"
149 | Add-Content $OutputPath "$KFMBlockOptInSet | KFM_Block_Opt_In_Set"
150 | Add-Content $OutputPath "$KFMBlockOptOutSet | KFM_Block_Opt_Out_Set `n"
151 | Add-Content $OutputPath "$ODVersion | OneDrive Sync client version"
152 |
--------------------------------------------------------------------------------
/Scripts/Sync-KFM-Deployment/readme.md:
--------------------------------------------------------------------------------
1 | # Windows Known Folder Move (KFM) deployment #
2 |
3 | ## Summary ##
4 |
5 | The script will create a txt file that shows 4 things:
6 |
7 | - Know Folder Move (KFM) eligibility (for whatever device it was run on)
8 | - Payload details (number of items and size of content within known folders)
9 | - KFM status (have the known folders been moved to OneDrive)
10 | - KFM GPO state (what GPOs have been set)
11 |
12 | The execution of the script can be done via Intune or other management tools that can execute a PowerShell script across Windows 10 devices. A TenantID as well as an output path is required. This level of detail will provide a better deployment of KFM.
13 |
14 | > More details around the Known Folder Move capability is available from the [official OneDrive documentation](https://docs.microsoft.com/en-us/onedrive/redirect-known-folders).
15 |
16 | ### Applies to ###
17 |
18 | - OneDrive
19 |
20 | ### Prerequisites ###
21 |
22 | - As the script reads registry values, you will need to be an administrator in the devices where it's executed.
23 |
24 | ### Solution ###
25 |
26 | Solution | Author(s)
27 | ---------|----------
28 | KFM Deployment script | Carter Green (Microsoft)
29 |
30 | ### Version history ###
31 |
32 | Version | Date | Comments
33 | ---------| -----| --------
34 | 1.0 | April 24th 2019 | Initial release
35 |
36 | ### Disclaimer ###
37 |
38 | **THIS SCRIPT IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**
39 |
40 | ----------
41 |
42 | # Execution
43 |
44 | Output
45 | ~~~
46 | True | Device_is_KFM_GPO_eligible
47 | 20 | Total_items_not_in_OneDrive
48 | 3480768 | Total_size_bytes_not_in_OneDrive
49 |
50 | False | Desktop_is_in_OneDrive
51 | 5 | Desktop_items
52 | 7573 | Desktop_size_bytes
53 |
54 | False | Documents_is_in_OneDrive
55 | 13 | Documents_items
56 | 3472353 | Documents_size_bytes
57 |
58 | False | Pictures_is_in_OneDrive
59 | 2 | Pictures_items
60 | 842 | Pictures_size_bytes
61 |
62 | True | KFM_Opt_In_Wizard_Set
63 | False | KFM_Silent_Opt_In_Set
64 | False | KFM_Silent_With_Notification_Set
65 | False | KFM_Block_Opt_In_Set
66 | False | KFM_Block_Opt_Out_Set
67 |
68 | 19.064.0402.0001 | OneDrive Sync client version
69 | ~~~
70 |
71 |
72 |
--------------------------------------------------------------------------------
/Scripts/readme-template.md:
--------------------------------------------------------------------------------
1 | # Title of the Script (SEO friendly) #
2 |
3 | ## Summary ##
4 |
5 | Description of the script
6 |
7 | ### Applies to ###
8 |
9 | - OneDrive
10 | - Potentially SharePoint if applies there as well
11 |
12 | ### Prerequisites ###
13 |
14 | - if any
15 |
16 | ### Solution ###
17 | Solution | Author(s)
18 | ---------|----------
19 | Name of the solution | name (company name)
20 |
21 | ### Version history ###
22 | Version | Date | Comments
23 | ---------| -----| --------
24 | 1.0 | February 8th 2026 | Initial release
25 |
26 | ### Disclaimer ###
27 |
28 | **THIS SCRIPT IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**
29 |
30 | ----------
31 |
32 | # Introduction
33 |
34 | Description of the script and what it does with potential set of additional links, images and other references.
35 |
36 |
--------------------------------------------------------------------------------
/Scripts/readme.md:
--------------------------------------------------------------------------------
1 | # OneDrive Admin Scripts #
2 |
3 | Different kind of automation scripts for OneDrive and Office 365 in general. See readme from specific folders for exact details.
4 |
5 | ## "Sharing is caring" ##
--------------------------------------------------------------------------------
/Scripts/sample/readme.md:
--------------------------------------------------------------------------------
1 | # Title of the Script (SEO friendly) #
2 |
3 | ## Summary ##
4 |
5 | Description of the script
6 |
7 | ### Applies to ###
8 |
9 | - OneDrive
10 | - Potentially SharePoint if applies there as well
11 |
12 | ### Prerequisites ###
13 |
14 | - if any
15 |
16 | ### Solution ###
17 |
18 | Solution | Author(s)
19 | ---------|----------
20 | Name of the solution | name (company name)
21 |
22 | ### Version history ###
23 |
24 | Version | Date | Comments
25 | ---------| -----| --------
26 | 1.0 | February 8th 2026 | Initial release
27 |
28 | ### Disclaimer ###
29 |
30 | **THIS SCRIPT IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**
31 |
32 | ----------
33 |
34 | ## Introduction ##
35 |
36 | Description of the script and what it does with potential set of additional links, images and other references.
37 |
38 | 
39 |
--------------------------------------------------------------------------------
/Scripts/sample/sample.ps1:
--------------------------------------------------------------------------------
1 | <#
2 | .Synopsis
3 | This script will do magical things when executed
4 |
5 | Goals
6 | · Ensure that you can automate cool stuff
7 |
8 |
9 | .EXAMPLE
10 |
11 | -------------------------- EXAMPLE 01 --------------------------
12 | Get-MagicalThingsInQueue
13 |
14 | #>
15 |
16 | function Get-MagicalThingsInQueue {
17 |
18 | #Commenting the code inline
19 | $today = get-date
20 |
21 | #Here's' the actual execution
22 | Write-Host ("Today is {0} and you have {1} magical things in queue." –f $today, (get-random))
23 | }
24 |
25 |
26 |
--------------------------------------------------------------------------------