Repository: madbomb122/Win10Script Branch: master Commit: 4c797d55ec2b Files: 13 Total size: 455.4 KB Directory structure: gitextract_1eaxieqw/ ├── .gitattributes ├── .github/ │ └── ISSUE_TEMPLATE/ │ ├── bug_report.md │ └── feature_request.md ├── Changelog.txt ├── LICENSE ├── README.md ├── Testing/ │ ├── Changelog.txt │ ├── Win10-Menu.ps1 │ └── readme.md ├── Version/ │ └── Version.csv ├── Win10-Menu.ps1 ├── _Win10-Script-Run.bat └── todo.md ================================================ FILE CONTENTS ================================================ ================================================ FILE: .gitattributes ================================================ /Testing export-ignore /Version export-ignore .gitattributes export-ignore todo.md export-ignore /.github/ export-ignore Update.bat export-ignore ================================================ FILE: .github/ISSUE_TEMPLATE/bug_report.md ================================================ --- name: Bug report about: Create a report to help us improve --- **Describe the bug** A clear and concise description of what the bug is. **To Reproduce** Steps to reproduce the behavior: 1. Go to '...' 2. Click on '....' 3. Scroll down to '....' 4. See error **Expected behavior** A clear and concise description of what you expected to happen. **Screenshots** If applicable, add screenshots to help explain your problem. **Desktop (please complete the following information):** - OS Version: [e.g. Creator's Update] - OS Build: [e.g. Home] - Modded OS: [e.g. No] -If you are using an OS that has removed items using a program like Nlite **Additional context** - Script Version: [e.g. 3.0.1] - Release Type: [e.g. Stable or Testing] ================================================ FILE: .github/ISSUE_TEMPLATE/feature_request.md ================================================ --- name: Feature request about: Suggest an idea for this project --- **Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. **Describe the solution you'd like** A clear and concise description of what you want to happen. **Describe alternatives you've considered** A clear and concise description of any alternative solutions or features you've considered. **Additional context** Add any other context or screenshots about the feature request here. ================================================ FILE: Changelog.txt ================================================ ----------------------------------------------------------------------------------- 3.7.2 (07-31-2021) Option Added Enable/Disable ScreenSaver Option Added Enable/Disable LockScreen Password Option Added ScreenSaver Wait Time (Configured in script/config file ONLY) Some Internal Script Changes (XML part) Some Internal Script Changes Fixed Disable/Enable entry mixup for Temeletry (thanks to St1ckys) More items Disable/Enable Feedback does Changed Box Art when script Runs Some Script Improvements Added More things Telemetry Enable/Disable Does in script Added an item for Cortana Enable/Disable in script Option Added Enable/Disable F1 Help Key Option Added Enable/Disable Accessibility Keys Option Added Enable/Disable Update for other Microsoft Products How the GUI's looks has been updated Look of the tabs has been updated Tabs are now on left side instead of top Changed Name of 'Metro Apps' to 'Windows Apps' Fixed bug were Apps were not being Hidden/Unhidden ----------------------------------------------------------------------------------- 3.6.9 (02-25-2019) Added ability to see Copyright/License Information from ToS, by inputting L Added Switch: -copy Shows Copyright/License Information, then exits script Internal Script Improvements 'Update.bat' file is no longer used Internal Script Changes Update for 'Windows Update P2P' Setting' Update for 'Disabling App Auto Download' Update/Fix for 'Start Menu Suggestions' Changed how 'Unpinning Startmenu Items' does it's job Change for 'Showing Task Manager Details'.. if it takes too long it will skip Fixed a messup that caused script to not run at all Minor Script Improvement/Changes Fixed an Issue with 'This PC' Folders not showing (when selecting 'Show/Add') the folders in some cases -Solves issue #6 License/Copyright Date Update for my script Added ability to Enable/Disable App Hibernation File (Swapfile.sys) Minor Script Improvement/Changes Fixed Issue with Metro Apps not displaying 'No Apps being *' messages Cortana Enable/Disable does more changes now ----------------------------------------------------------------------------------- 3.6.0 (08-21-2018) Fixed an issue with 'Share/Share with' that causes the script to stall (thanks to Cpt0r for letting me know) Reworked some internal script stuff (text display is easyer to read in script) Fixed bug with app Unhide/Hide/Uninstall were the wrong item ----------------------------------------------------------------------------------- 3.5.0 (08-07-2018) Share with Renamed to Share with/Share (it removes the share context too) Internal Script Changes Added Enable/Disable Long File Path More Interal Script Changes (decreased size of script a little) More Internal Script Improvements (decreased size of script a little, slight speed improvement) Fixed Issue with Symbols/Special Characters in filename and/or path Reverted some changes due to some changes being slower rather than faster Fixed Windows Update P2P type for 1803 ----------------------------------------------------------------------------------- 3.4.0 (06-16-2018) Fixed an issue with enable windows defender on newer than Annivery update didnt work Fixed an issue that caused an entry for disableingn app auto download to not set Fixed an issue that caused an entry for Removing AutoLogger file to not set Fixed bug with enable/disable start suggestions Fixed some typos Changed how "Update Available Popup" sets ownership Added Enable/Disable "Various Scheduled Tasks" -Option Not in GUI ^^But can be done by editing script or setting file.. Since it may cause problems Added 2 apps to list 'Microsoft.GetHelp' and 'Microsoft.Wallet' Added Option to Enable/Disable "Re-Opening of apps on boot" (Windows Enabled by default) Added Account Protection Warning (Warns if not on a Microsoft account) Changed Look of Gui a little (added Help button) Added a wait for each app section to finish before continuing Bug fix for remove 'This PC' items not showing that you are removing them Changed Unpin start menu items.. from unpinning Some to All items Metro App Unhide/Hide/Uninstall now are the first items to be set instead of last Internal Script changes Bug fix for Hiding/Removing '3d Objects' in 'This PC' for April 2018 Update Bug fix for Showing 'This PC', now should Re-Add removed items Renamed 'Application' to 'Application/Feature' Added 'Fax And Scan' to Uninstall/Install to 'Application/Feature' list Fixed a problem with Onedrive uninstall Added 'Window's Timeline' to Enable/Disable to 'Explorer' List Script will now Wait for Appx Tasks to finish before script closes/restarts computer ^to make sure appx task isnt inturrupted while doing it's job ----------------------------------------------------------------------------------- 3.3.0 (12-29-2017) Enabled Window Resize (best to resize so the yellow on bottom and right size are not visable) ^ Yellow block shows "Dont Resize past this area" Bug fix with Enabling "Previous Versions Context" Bug fix with Showing/Hding Tray Icons Bug fix with Checkboxes on Script Option not working properly ^Create Restore Point, Skip Items, Restart when Done, Update Check, Update Bat, Internet Check Bug fix with Enabling Aero Snap Added Remove option for 'This PC' items Improved Advertising ID (Enable/Disable) Improved Windows Defender (Enable/Disable) Improved Start Suggestions (Enable/Disable) Added Multi Xbox Apps (No seperate option for each apps) Fixed issue with "Task Manager Details" (thanks to dhoffman98) Improved how resize works/shows (size of gui items wont change still) Removed the yellow "Dont Resize past this area" boxes Added switch "-h" to show a list of switches Changed some internal script stuff Added option to disable the "Update is Available popup" under Application/Windows Update tab Added More stuff for disableing Wifi sense ----------------------------------------------------------------------------------- 3.2.0 (11-02-2017) Added Missing Items (MSRT Update, Driver Update, Restarte on Update) Fixed a typo that caused switch/arguments to not work and loading of settings Changed indent from spaces to tabs to decrease file size about 9 KB Added Registry entry for Auto Logger File Fixed a Typo Minor changes in script Added Color to Donate, Website and Copyright button Added Items for Fall Creator's Update ----------------------------------------------------------------------------------- 3.1.0 (08-26-2017) Added List for what is Unpined for the Unpined Item Renamed the Install in Metro to Unhide (you cant install metro apps w/o the appx file) Fixed a typo Added check for windows 10 Fixed Bug with script downloading Newer version of script Script has option updates bat file with new script name if update is downloaded using script Updates will use Update.bat if avaiable (will overwrite script file instead of creating new file) ----------------------------------------------------------------------------------- 3.0.0-GUI (08-16-2017) Changed Text Menu to Gui Menu Added Minor Version Various Improvements ----------------------------------------------------------------------------------- 2.2-Menu (05-28-2017) OLD SETTING FILES WILL NOT WORK Changed/added different arguments/switches -run Runs script with setting in script -run Settingfile Runs script with Settingfile -run WinDefault Runs script with Win Default -load Settingfile Loads Settingfile (Does not run) -load WinDefault Loads Win Default (Does not run) -sic Skip Internet Check -usc Check for update -atos Accepts ToS -auto Closes on Errors, End of Script (Implies -atos) -crp Creates a Restore Point -dnr Do not restart when done Note: Settingfile = name of your setting file Note: Old arguments/switches will not work Change Window content while dragging items from enable/disable to show/hide Fixed a bug with windows update not setting if path was not there Fixed problem with remove cast to device context item Changed how script does detection for metro apps Fixed bug with unpin not being corrently set to unpin Changed format for setting save/load (smaller files and more readable) Ability to add custom apps to hide/uninstall in setting file ----------------------------------------------------------------------------------- 2.1-Menu (05-13-2017) Added check for (Bellow) before script attempts to Install/Uninstall Windows Media Player Work Folders Client Linux Subsystem Onedrive (checks for OneDriveSetup.exe) Minor changes in script Fixed bug with enabling Windows Defender Fixed bug with smart screen and Wap push not disableing Fixed bug with metro apps Changed how Firewall is Enabled/Disabled Added Ability to Show/Hide Task Manager details Fixed Load setting bug (Thanks to Scott C) ----------------------------------------------------------------------------------- 2.0-Menu (04-22-2017) Internal Script Changes Fixed "Users File Icon on Desktop" showing as "Recycle Bin Icon on Desktop" Fixed "Removeing Recent Files in Quick Access" set incorrectly Fixed "Disabling Cast to Device Context" set incorrectly Change Powershell to Command Prompt (in Win+X) Changed the Internet check to ping github instead of google.com & yahoo.com ----------------------------------------------------------------------------------- 1.9-Menu (04-08-2017) Added some updates to settings for creator's update Changed TOS Display look Added Internet Check if script checks for update Various display changes Ability to name restore point (in script file only ATM) Added Ability to add/remove following apps 3D Viewer Removed Ability to add/remove following apps Asphalt 8 Bing Finance Bing News Bing Sports Bing Translator Candy Cursh Facebook Farm Ville Fresh Paint Houzza Microsoft Jackpot Microsoft Jigsaw Microsoft Mahjong Microsoft Sudoku Minecraft Studios Wordament Taptiles Twitter ----------------------------------------------------------------------------------- 1.8-Menu (03-19-2017) Added Script update check option Decided to remove Black Viper Service configuration from this script.. Please use the script for just the Black Viper Service configuration @ https://github.com/madbomb122/BlackViperScript ----------------------------------------------------------------------------------- 1.7-Menu (03-17-2017) Fixed bug with using the bat file to run with setting file Fixed bug with add/remove pin to "quick access" Removed Custom App Import in setting file (was causeing the apps to not Install/Hide/Uninstall) ----------------------------------------------------------------------------------- 1.6-Menu (03-14-2017) Disabled Black Viper Service configuration ----------------------------------------------------------------------------------- 1.5-Menu (03-12-2017) Added option to show/hide when an item is skipped Added a check if running in Powershell or Powershell ISE (ISE is not supported) Renamed 'Pin To' to 'Pin To Start' Added Ability to Add/Remove 'Pin To Quick Access' Fixed some Items not displaying Added Ability to Show/Hide following icons to desktop: Network Recycle Bin User's Files Control Panel ----------------------------------------------------------------------------------- 1.4-Menu (03-04-2017) Added Black Viper's service settings (Win 10 Home/Pro ONLY) Removed Lock Screen alt (script check run the correct lockscreen work around) Added a display of skipped items ----------------------------------------------------------------------------------- 1.3-Menu (02-27-2017) Load/save setting fix ----------------------------------------------------------------------------------- 1.2-Menu (02-20-2017) Metro Apps setting changeable in the menu ----------------------------------------------------------------------------------- 1.1-Menu (02-19-2017) Fixed 2 Bugs: If tos was set to accept in script it did not skip the tos fixed a messup with the add/remove/uninstall apps if you set it in script or file Working on making apps setting changeable in the menu ----------------------------------------------------------------------------------- 1.0-Menu (02-17-2017) -START VERSION OF NEW SCRIPT Done With adding a Menu Cant Change the Apps to Install/Hide/Uninstall from within script menu.. But you can from in the script file (or a loaded file). Note1: Settings file for Older script (3.5-mod and bellow) will NOT work Note2: 3.5-mod is the LAST of the old script ----------------------------------------------------------------------------------- 3.5-Mod (02-09-2017) -LAST VERSION OF OLD SCRIPT Re-ordered some items Added Write output when at Each different category Added Color for Some outputs Ability to Disable Output Ability to Disable Color of output renamed 4 items APP_SolitaireCollection to APP_SolitaireCollect APP_WindowsFeedback to APP_WindowsFeedbak APP_WindowsFeedbackHub to APP_WindowsFeedbakHub APP_MicrosoftOfficeHub to APP_MicrosoftOffHub ----------------------------------------------------------------------------------- 3.4-Mod (02-03-2017) Added 1 New Setting Items: Windows Update Check Type Also a few minor bug fixes ----------------------------------------------------------------------------------- 3.3-Mod (02-02-2017) Added Description to some items Ability to Create Restore Point Before running Script Added 12 New Setting Items: Recent Files in Quick Access Frequent Folders in Quick Access Most Used App in Start Menu Power Menu on Lock Screen Hibernate Power Option Sleep Power Option Window Content While Dragging Check For Windows Update Taskbar On Multi Display Taskbar Buttons On Multi Display Remote UAC Local Account Token Filter ----------------------------------------------------------------------------------- 3.2-Mod (02-01-2017) Added Description to some items Ability to run Pre-defined setting (currently only -Set Set1) Added 4 New Setting Items: Cortana Search (Can still search with cortana disabled) Classic Clock UI (for the taskbar flyout) Classic Battery UI (for the taskbar flyout) Recent Items and Frequent Places (in start menu) Added More Colors for Tiles (But disabled till i figure problem out) Renamed 2 Items: AeroResize to AeroSnap (Proper name of function) CameraOnLoc to CameraOnLockScreen (Gives better description of item) ----------------------------------------------------------------------------------- 3.1-Mod (1-29-2017) Ability to add Apps to Install, Hide or Uninstall, that the script doesnt list ^This can ONLY be done in the script itself ATM ----------------------------------------------------------------------------------- 3.0-Mod (01-28-2017) Greatly Improved the ability to import app list from setting file Also changed it so you can Install, Hide or Uninstall for each app (instead of the whole thing) Changed the Initial Text that show when you start script Removed 3 Apps (since they cant be hidden or removed) Fixed a few errors for Photo Viewer Settings ----------------------------------------------------------------------------------- 2.3-Mod (01-27-2017) Fixed a bug with imported settings from a file Added ability to import app list from setting file Added Facebook to applist ----------------------------------------------------------------------------------- 2.2-Mod (01-26-2017) Added ability to run imported settings from a file Added ability to run windows default settings w/o editing file Added a note when you run script and a way to skip it ----------------------------------------------------------------------------------- 2.1-Mod (01-25-2017) Change script so it does nothing by default Added item to have it run the windows default items Added 1 New Setting Items: seconds for the clock on the taskbar ----------------------------------------------------------------------------------- 2.0-Mod (01-25-2017) -- (Started doing my changes) Made Script easier to pick what you want to run Script by default returned items to the default of windows (that the script is set to change) Added 6 New Setting for Context Menu: (add/remove) Cast To Device Previous Versions Include in Library Pin To Share With Send To Added 5 New Settings: Volume Control Bar to classic/new Pid In Title Bar Aero Resize Aero Shake App Auto Download Added options for a few of the items that had more than once choice Added ability to Remove the bloatware instead of just hiding it ----------------------------------------------------------------------------------- 2.0 (01-08-2017) v2.0 Script by Disassembler0 https://github.com/Disassembler0/Win10-Initial-Setup-Script/ ================================================ FILE: LICENSE ================================================ The MIT License (MIT) Copyright (c) 2017 Disassembler -Original Win10 Initial Setup Script Copyright (c) 2017-2021 Madbomb122 -Modded Win10 Initial Setup Script Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: README.md ================================================ To Download go to -> [Win 10 Script -Release](https://github.com/madbomb122/Win10Script/releases) **Current Version** **Script:** `3.7.2` (July 31, 2021) ## Contents - [Description](#description) - [Requirements](#requirements) - [How to Use](#how-to-use) - [Usage](#usage) - [Advanced Usage](#advanced-usage) - [FAQ](#faq) ## Description This is a PowerShell script for automation of routine tasks/setting on Windows 10. This is by no means a complete set of settings. (There is ALOT that can be changed/done) The original basic script created by https://github.com/Disassembler0/Win10-Initial-Setup-Script/ ^ We have some of the same setting and a few different stuff too This script is a Highly Modded version of the 2.0 script by Disaseembler0. The script has added items with an easy way to change settings and options using a GUI. PS. Don't forget to check out my other Repo https://github.com/madbomb122/BlackViperScript ## Requirements **OS:** `Windows 10` **Needed Files:** `Win10-Menu.ps1` (Script File) **Recommended Files:** `_Win10-Script-Run.bat` ## How to Use Download/Save the following files Script File: [Win10-Menu.ps1](https://github.com/madbomb122/Win10Script/raw/master/Win10-Menu.ps1) (Script) -Size about `204.0 KB` -Need Bat File: [_Win10-Script-Run.bat](https://github.com/madbomb122/Win10Script/raw/master/_Win10-Script-Run.bat) -Size about `2.29 KB` -Recommended **Note 1: DO NOT RENAME THE FILES** **Note 2: HAVE THE FILES IN THE SAME DIRECTORY** Next follow the **Basic Usage** or **Advanced Usage** **You can do a `save as` on the filenames above to save them to you computer, you cannot do a `save as` on github's file list** ## Usage Run the Script by bat file `_Win10-Script-Run.bat` (Recommended) or `powershell.exe -NoProfile -ExecutionPolicy Bypass -File c:/Win10-Menu.ps1` *For the above, Please note you need change the c:/ to the fullpath of your file* Use the Menu Set what you want Select option to run script ### Advanced usage Use one of the following Methods you can 1. Run script with one (or more) of the switches below 2. Edit the script (bottom of file) to change the values 3. Edit the bat file (top of file) to change the values to add the switch | Switch | Description | Notes | | :-------- | :-------------------------------------------------------------------| :------------------------------- | | -atos | Accepts the ToS | | | -auto | Runs the script to be Automated.. Closes on Errors, End of Script) | Implies `-atos` | | -run | Runs script with setting in script | | | -run Settingfile | Runs script with Settingfile | May Imply `-atos` (If file was saved from script) | | -run WinDefault | Runs script with Win Default | | | -load Settingfile | Loads Settingfile (Does not run) | | | -load WinDefault | Loads Win Default (Does not run) | | | -sic | Skips Internet Check (If checking for update) | Tests by pinging github.com | | -usc | Checks for Update to Script file before running | Auto downloads and runs if found | | -crp | Creates a Restore Point | | | -dnr | Do not restart when done | | | -help | Lists of all the switches | Alt `-h` | Examples: `powershell.exe -NoProfile -ExecutionPolicy Bypass -File Win10-Menu.ps1 -auto -run mine.csv` `powershell.exe -NoProfile -ExecutionPolicy Bypass -File Win10-Menu.ps1 -atos -load WinDefault` ****** ## FAQ **Q:** The script file looks all messy in notepad, How do i view it? **A:** Try using wordpad or what I recommend, Notepad++ [https://notepad-plus-plus.org/](https://notepad-plus-plus.org/) **Q:** Do you accept any donations? **A:** If you would like to donate to me Please pick an item/giftcard from my amazon wishlist or Contact me about donating, Thanks. BTW The giftcard amount can be changed to a min of $1. **Wishlist:** [https://www.amazon.com/gp/registry/wishlist/YBAYWBJES5DE/](https://www.amazon.com/gp/registry/wishlist/YBAYWBJES5DE/) **Q:** How can I contact you? **A:** You can also PM me on reddit or email me 1. reddit /u/madbomb122 [https://www.reddit.com/user/madbomb122](https://www.reddit.com/user/madbomb122) 2. You can email me @ madbomb122@gmail.com. **Note** Before contacting me, please make sure you have ALL the needed files and the size is right (Look above under requirements). **Q:** Can you add *BLAH* to the apps list? **A:** Mabye, post [here](https://github.com/madbomb122/Win10Script/issues/8) and follow the instructions, and I may add it. **Q:** The script window closes or gives an error saying script is blocked, what do I do? **A:** By default windows blocks ps1 scripts, you can use one of the following 1. Use the bat file to run the script (recommended) 2. On an admin powershell console `Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy Unrestricted` **Q:** Can I run the script safely? **A:** Yes and No, it depends on what you do, some items may cause problems and some items will not cause any issues. **Q:** Can I run the script repeatedly? **A:** Yes, with same or different settings. **Q:** Did you test the script? **A:** Yes, but doesnt mean there isnt any bugs/errors. **Q:** I've run the script and it did *BLAH*, can I undo it? **A:** There are 2 possible ways... 1. Yes, Most things can easily be undone by going in the script and run it again with the deisred change. 2. System Restore can undo some of the changes, if you created a restore point (can be done from script) **Q:** The script messed up my computer. **A:** The script is 'as is', any problems you have/had is not my problem. **Q:** Can I use the script or modify it for my/my company's needs? **A:** Sure. Just don't forget to include copyright notice as per the license requirements, and leave any Copyright in script too. **Q:** Can I add an App to Install/Hide/Uninstall, if so how? **A:** Yes you can. You can add it in the script file under APPS_AppsInstall, APPS_AppsHide, APPS_AppsUninstall. ---------Please note you have to have the proper format and packagename for it to work. **Q:** Can you add *BLAH* to the script? **A:** Mabye, Depends on what it is and how hard it would be to add. **Q:** How do I request adding *BLAH* to the script? **A:** Just post it as an Issue. **Q:** Are you planning to add *BLAH* to the script? **A:** Check the todo list, anything i am planning to do or thinking of doing will be there. **Q:** How long are you going to maintain the script? **A:** No Clue. ================================================ FILE: Testing/Changelog.txt ================================================ ----------------------------------------------------------------------------------- 3.7.2 (07-31-2021) Option Added Enable/Disable ScreenSaver Option Added Enable/Disable LockScreen Password Option Added ScreenSaver Wait Time (Configured in script/config file ONLY) Some Internal Script Changes (XML part) Some Internal Script Changes Fixed Disable/Enable entry mixup for Temeletry (thanks to St1ckys) More items Disable/Enable Feedback does Changed Box Art when script Runs Some Script Improvements Added More things Telemetry Enable/Disable Does in script Added an item for Cortana Enable/Disable in script Option Added Enable/Disable F1 Help Key Option Added Enable/Disable Accessibility Keys Option Added Enable/Disable Update for other Microsoft Products How the GUI's looks has been updated Look of the tabs has been updated Tabs are now on left side instead of top Changed Name of 'Metro Apps' to 'Windows Apps' Fixed bug were Apps were not being Hidden/Unhidden ----------------------------------------------------------------------------------- 3.6.9 (02-25-2019) Added ability to see Copyright/License Information from ToS, by inputting L Added Switch: -copy Shows Copyright/License Information, then exits script Internal Script Improvements 'Update.bat' file is no longer used Internal Script Changes Update for 'Windows Update P2P' Setting' Update for 'Disabling App Auto Download' Update/Fix for 'Start Menu Suggestions' Changed how 'Unpinning Startmenu Items' does it's job Change for 'Showing Task Manager Details'.. if it takes too long it will skip Fixed a messup that caused script to not run at all Minor Script Improvement/Changes Fixed an Issue with 'This PC' Folders not showing (when selecting 'Show/Add') the folders in some cases -Solves issue #6 License/Copyright Date Update for my script Added ability to Enable/Disable App Hibernation File (Swapfile.sys) Minor Script Improvement/Changes Fixed Issue with Metro Apps not displaying 'No Apps being *' messages Cortana Enable/Disable does more changes now ----------------------------------------------------------------------------------- 3.6.0 (08-21-2018) Fixed an issue with 'Share/Share with' that causes the script to stall (thanks to Cpt0r for letting me know) Reworked some internal script stuff (text display is easyer to read in script) Fixed bug with app Unhide/Hide/Uninstall were the wrong item ----------------------------------------------------------------------------------- 3.5.0 (08-07-2018) Share with Renamed to Share with/Share (it removes the share context too) Internal Script Changes Added Enable/Disable Long File Path More Interal Script Changes (decreased size of script a little) More Internal Script Improvements (decreased size of script a little, slight speed improvement) Fixed Issue with Symbols/Special Characters in filename and/or path Reverted some changes due to some changes being slower rather than faster Fixed Windows Update P2P type for 1803 ----------------------------------------------------------------------------------- 3.4.0 (06-16-2018) Fixed an issue with enable windows defender on newer than Annivery update didnt work Fixed an issue that caused an entry for disableingn app auto download to not set Fixed an issue that caused an entry for Removing AutoLogger file to not set Fixed bug with enable/disable start suggestions Fixed some typos Changed how "Update Available Popup" sets ownership Added Enable/Disable "Various Scheduled Tasks" -Option Not in GUI ^^But can be done by editing script or setting file.. Since it may cause problems Added 2 apps to list 'Microsoft.GetHelp' and 'Microsoft.Wallet' Added Option to Enable/Disable "Re-Opening of apps on boot" (Windows Enabled by default) Added Account Protection Warning (Warns if not on a Microsoft account) Changed Look of Gui a little (added Help button) Added a wait for each app section to finish before continuing Bug fix for remove 'This PC' items not showing that you are removing them Changed Unpin start menu items.. from unpinning Some to All items Metro App Unhide/Hide/Uninstall now are the first items to be set instead of last Internal Script changes Bug fix for Hiding/Removing '3d Objects' in 'This PC' for April 2018 Update Bug fix for Showing 'This PC', now should Re-Add removed items Renamed 'Application' to 'Application/Feature' Added 'Fax And Scan' to Uninstall/Install to 'Application/Feature' list Fixed a problem with Onedrive uninstall Added 'Window's Timeline' to Enable/Disable to 'Explorer' List Script will now Wait for Appx Tasks to finish before script closes/restarts computer ^to make sure appx task isnt inturrupted while doing it's job ----------------------------------------------------------------------------------- 3.3.0 (12-29-2017) Enabled Window Resize (best to resize so the yellow on bottom and right size are not visable) ^ Yellow block shows "Dont Resize past this area" Bug fix with Enabling "Previous Versions Context" Bug fix with Showing/Hding Tray Icons Bug fix with Checkboxes on Script Option not working properly ^Create Restore Point, Skip Items, Restart when Done, Update Check, Update Bat, Internet Check Bug fix with Enabling Aero Snap Added Remove option for 'This PC' items Improved Advertising ID (Enable/Disable) Improved Windows Defender (Enable/Disable) Improved Start Suggestions (Enable/Disable) Added Multi Xbox Apps (No seperate option for each apps) Fixed issue with "Task Manager Details" (thanks to dhoffman98) Improved how resize works/shows (size of gui items wont change still) Removed the yellow "Dont Resize past this area" boxes Added switch "-h" to show a list of switches Changed some internal script stuff Added option to disable the "Update is Available popup" under Application/Windows Update tab Added More stuff for disableing Wifi sense ----------------------------------------------------------------------------------- 3.2.0 (11-02-2017) Added Missing Items (MSRT Update, Driver Update, Restarte on Update) Fixed a typo that caused switch/arguments to not work and loading of settings Changed indent from spaces to tabs to decrease file size about 9 KB Added Registry entry for Auto Logger File Fixed a Typo Minor changes in script Added Color to Donate, Website and Copyright button Added Items for Fall Creator's Update ----------------------------------------------------------------------------------- 3.1.0 (08-26-2017) Added List for what is Unpined for the Unpined Item Renamed the Install in Metro to Unhide (you cant install metro apps w/o the appx file) Fixed a typo Added check for windows 10 Fixed Bug with script downloading Newer version of script Script has option updates bat file with new script name if update is downloaded using script Updates will use Update.bat if avaiable (will overwrite script file instead of creating new file) ----------------------------------------------------------------------------------- 3.0.0-GUI (08-16-2017) Changed Text Menu to Gui Menu Added Minor Version Various Improvements ----------------------------------------------------------------------------------- 2.2-Menu (05-28-2017) OLD SETTING FILES WILL NOT WORK Changed/added different arguments/switches -run Runs script with setting in script -run Settingfile Runs script with Settingfile -run WinDefault Runs script with Win Default -load Settingfile Loads Settingfile (Does not run) -load WinDefault Loads Win Default (Does not run) -sic Skip Internet Check -usc Check for update -atos Accepts ToS -auto Closes on Errors, End of Script (Implies -atos) -crp Creates a Restore Point -dnr Do not restart when done Note: Settingfile = name of your setting file Note: Old arguments/switches will not work Change Window content while dragging items from enable/disable to show/hide Fixed a bug with windows update not setting if path was not there Fixed problem with remove cast to device context item Changed how script does detection for metro apps Fixed bug with unpin not being corrently set to unpin Changed format for setting save/load (smaller files and more readable) Ability to add custom apps to hide/uninstall in setting file ----------------------------------------------------------------------------------- 2.1-Menu (05-13-2017) Added check for (Bellow) before script attempts to Install/Uninstall Windows Media Player Work Folders Client Linux Subsystem Onedrive (checks for OneDriveSetup.exe) Minor changes in script Fixed bug with enabling Windows Defender Fixed bug with smart screen and Wap push not disableing Fixed bug with metro apps Changed how Firewall is Enabled/Disabled Added Ability to Show/Hide Task Manager details Fixed Load setting bug (Thanks to Scott C) ----------------------------------------------------------------------------------- 2.0-Menu (04-22-2017) Internal Script Changes Fixed "Users File Icon on Desktop" showing as "Recycle Bin Icon on Desktop" Fixed "Removeing Recent Files in Quick Access" set incorrectly Fixed "Disabling Cast to Device Context" set incorrectly Change Powershell to Command Prompt (in Win+X) Changed the Internet check to ping github instead of google.com & yahoo.com ----------------------------------------------------------------------------------- 1.9-Menu (04-08-2017) Added some updates to settings for creator's update Changed TOS Display look Added Internet Check if script checks for update Various display changes Ability to name restore point (in script file only ATM) Added Ability to add/remove following apps 3D Viewer Removed Ability to add/remove following apps Asphalt 8 Bing Finance Bing News Bing Sports Bing Translator Candy Cursh Facebook Farm Ville Fresh Paint Houzza Microsoft Jackpot Microsoft Jigsaw Microsoft Mahjong Microsoft Sudoku Minecraft Studios Wordament Taptiles Twitter ----------------------------------------------------------------------------------- 1.8-Menu (03-19-2017) Added Script update check option Decided to remove Black Viper Service configuration from this script.. Please use the script for just the Black Viper Service configuration @ https://github.com/madbomb122/BlackViperScript ----------------------------------------------------------------------------------- 1.7-Menu (03-17-2017) Fixed bug with using the bat file to run with setting file Fixed bug with add/remove pin to "quick access" Removed Custom App Import in setting file (was causeing the apps to not Install/Hide/Uninstall) ----------------------------------------------------------------------------------- 1.6-Menu (03-14-2017) Disabled Black Viper Service configuration ----------------------------------------------------------------------------------- 1.5-Menu (03-12-2017) Added option to show/hide when an item is skipped Added a check if running in Powershell or Powershell ISE (ISE is not supported) Renamed 'Pin To' to 'Pin To Start' Added Ability to Add/Remove 'Pin To Quick Access' Fixed some Items not displaying Added Ability to Show/Hide following icons to desktop: Network Recycle Bin User's Files Control Panel ----------------------------------------------------------------------------------- 1.4-Menu (03-04-2017) Added Black Viper's service settings (Win 10 Home/Pro ONLY) Removed Lock Screen alt (script check run the correct lockscreen work around) Added a display of skipped items ----------------------------------------------------------------------------------- 1.3-Menu (02-27-2017) Load/save setting fix ----------------------------------------------------------------------------------- 1.2-Menu (02-20-2017) Metro Apps setting changeable in the menu ----------------------------------------------------------------------------------- 1.1-Menu (02-19-2017) Fixed 2 Bugs: If tos was set to accept in script it did not skip the tos fixed a messup with the add/remove/uninstall apps if you set it in script or file Working on making apps setting changeable in the menu ----------------------------------------------------------------------------------- 1.0-Menu (02-17-2017) -START VERSION OF NEW SCRIPT Done With adding a Menu Cant Change the Apps to Install/Hide/Uninstall from within script menu.. But you can from in the script file (or a loaded file). Note1: Settings file for Older script (3.5-mod and bellow) will NOT work Note2: 3.5-mod is the LAST of the old script ----------------------------------------------------------------------------------- 3.5-Mod (02-09-2017) -LAST VERSION OF OLD SCRIPT Re-ordered some items Added Write output when at Each different category Added Color for Some outputs Ability to Disable Output Ability to Disable Color of output renamed 4 items APP_SolitaireCollection to APP_SolitaireCollect APP_WindowsFeedback to APP_WindowsFeedbak APP_WindowsFeedbackHub to APP_WindowsFeedbakHub APP_MicrosoftOfficeHub to APP_MicrosoftOffHub ----------------------------------------------------------------------------------- 3.4-Mod (02-03-2017) Added 1 New Setting Items: Windows Update Check Type Also a few minor bug fixes ----------------------------------------------------------------------------------- 3.3-Mod (02-02-2017) Added Description to some items Ability to Create Restore Point Before running Script Added 12 New Setting Items: Recent Files in Quick Access Frequent Folders in Quick Access Most Used App in Start Menu Power Menu on Lock Screen Hibernate Power Option Sleep Power Option Window Content While Dragging Check For Windows Update Taskbar On Multi Display Taskbar Buttons On Multi Display Remote UAC Local Account Token Filter ----------------------------------------------------------------------------------- 3.2-Mod (02-01-2017) Added Description to some items Ability to run Pre-defined setting (currently only -Set Set1) Added 4 New Setting Items: Cortana Search (Can still search with cortana disabled) Classic Clock UI (for the taskbar flyout) Classic Battery UI (for the taskbar flyout) Recent Items and Frequent Places (in start menu) Added More Colors for Tiles (But disabled till i figure problem out) Renamed 2 Items: AeroResize to AeroSnap (Proper name of function) CameraOnLoc to CameraOnLockScreen (Gives better description of item) ----------------------------------------------------------------------------------- 3.1-Mod (1-29-2017) Ability to add Apps to Install, Hide or Uninstall, that the script doesnt list ^This can ONLY be done in the script itself ATM ----------------------------------------------------------------------------------- 3.0-Mod (01-28-2017) Greatly Improved the ability to import app list from setting file Also changed it so you can Install, Hide or Uninstall for each app (instead of the whole thing) Changed the Initial Text that show when you start script Removed 3 Apps (since they cant be hidden or removed) Fixed a few errors for Photo Viewer Settings ----------------------------------------------------------------------------------- 2.3-Mod (01-27-2017) Fixed a bug with imported settings from a file Added ability to import app list from setting file Added Facebook to applist ----------------------------------------------------------------------------------- 2.2-Mod (01-26-2017) Added ability to run imported settings from a file Added ability to run windows default settings w/o editing file Added a note when you run script and a way to skip it ----------------------------------------------------------------------------------- 2.1-Mod (01-25-2017) Change script so it does nothing by default Added item to have it run the windows default items Added 1 New Setting Items: seconds for the clock on the taskbar ----------------------------------------------------------------------------------- 2.0-Mod (01-25-2017) -- (Started doing my changes) Made Script easier to pick what you want to run Script by default returned items to the default of windows (that the script is set to change) Added 6 New Setting for Context Menu: (add/remove) Cast To Device Previous Versions Include in Library Pin To Share With Send To Added 5 New Settings: Volume Control Bar to classic/new Pid In Title Bar Aero Resize Aero Shake App Auto Download Added options for a few of the items that had more than once choice Added ability to Remove the bloatware instead of just hiding it ----------------------------------------------------------------------------------- 2.0 (01-08-2017) v2.0 Script by Disassembler0 https://github.com/Disassembler0/Win10-Initial-Setup-Script/ ================================================ FILE: Testing/Win10-Menu.ps1 ================================================ ########## # Win 10 Setup Script/Tweaks with Menu(GUI) # # Modded Script + Menu(GUI) By # Author: Madbomb122 # Website: https://GitHub.com/Madbomb122/Win10Script/ # # Original Basic Script By # Author: Disassembler0 # Website: https://GitHub.com/Disassembler0/Win10-Initial-Setup-Script/ # Version: 2.0, 2017-01-08 (Version Copied) # $Script_Version = '3.7.2' $Script_Date = 'Jul-31-2021' #$Release_Type = 'Stable' ########## ## !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ## !! !! ## !! SAFE TO EDIT ITEM !! ## !! AT BOTTOM OF SCRIPT !! ## !! !! ## !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ## !! !! ## !! CAUTION !! ## !! DO NOT EDIT PAST THIS POINT !! ## !! !! ## !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! <#------------------------------------------------------------------------------#> $Copyright =' The MIT License (MIT) Copyright (c) 2017 Disassembler -Original Basic Version of Script Copyright (c) 2017-2021 Madbomb122 -Modded + Menu Version of Script Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice(s), this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ' <#-------------------------------------------------------------------------------- .Prerequisite to run script System: Windows 10 Files: This script .DESCRIPTION Makes it easier to setup an existing or new install with moded setting .BASIC USAGE Use the Menu and set what you want then Click Run the Script .ADVANCED USAGE One of the following Methods... 1. Edit values at bottom of the script 2. Edit bat file and run 3. Run the script with one of these switches (space between multiple) Switch Description of Switch -- Basic Switches -- -atos Accepts ToS -auto Implies -Atos...Closes on - User Errors, or End of Script -crp Creates Restore Point -dnr Do Not Restart when done -- Run Script Switches -- -run Runs script with settings in script -run FILENME Runs script with settings in the file FILENME -run wd Runs script with win default settings -- Load Script Switches -- -load FILENME Loads script with settings in the file FILENME -load wd Loads script with win default settings --Update Switches-- -usc Checks for Update to Script file before running -sic Skips Internet Check ------------------------------------------------------------------------------#> ########## # Pre-Script -Start ########## If([Environment]::OSVersion.Version.Major -ne 10) { Write-Host 'Sorry, this Script supports Windows 10 ONLY.' -ForegroundColor 'cyan' -BackgroundColor 'black' If($Automated -ne 1){ Read-Host -Prompt "`nPress Any key to Close..." } ;Exit } If($Release_Type -eq 'Stable'){ $ErrorActionPreference = 'SilentlyContinue' } Else{ $Release_Type = 'Testing' } $Script:PassedArg = $args If(!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")) { Start-Process powershell.exe "-NoProfile -ExecutionPolicy Bypass -File `"$PSCommandPath`" $PassedArg" -Verb RunAs ;Exit } $MySite = 'https://GitHub.com/madbomb122/Win10Script' $URL_Base = $MySite.Replace('GitHub','raw.GitHub')+'/master/' $Version_Url = $URL_Base + 'Version/Version.csv' $Donate_Url = 'https://www.amazon.com/gp/registry/wishlist/YBAYWBJES5DE/' $FileBase = $(If($psISE -ne $Null){ Split-Path $psISE.CurrentFile.FullPath -Parent } Else{ $PSScriptRoot }) + '\' $Script:Win10Ver = (Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion' -Name ReleaseID).ReleaseId $Script:OSBit = If([System.Environment]::Is64BitProcess){ 64 } Else{ 32 } ########## # Pre-Script -End ########## # Needed Variable -Start ########## $TasksList = @( 'Application Experience', 'Consolidator', 'Customer Experience Improvement Program', 'DmClient', 'KernelCeipTask', 'Microsoft Compatibility Appraiser', 'ProgramDataUpdater', 'Proxy', 'QueueReporting', 'SmartScreenSpecific', 'UsbCeip') <# 'AgentFallBack2016', 'AitAgent', 'CreateObjectTask', #'Diagnostics', 'DmClientOnScenarioDownload', 'FamilySafetyMonitor', 'FamilySafetyRefresh', 'FamilySafetyRefreshTask', 'FamilySafetyUpload', #'File History (maintenance mode)', 'GatherNetworkInfo', 'MapsUpdateTask', #'Microsoft-Windows-DiskDiagnosticDataCollector', 'MNO Metadata Parser', 'OfficeTelemetryAgentFallBack', 'OfficeTelemetryAgentLogOn', 'OfficeTelemetryAgentLogOn2016', 'Sqm-Tasks', #'StartupAppTask', 'Uploader', 'XblGameSaveTask', 'XblGameSaveTaskLogon') #> $Xbox_Apps = @(Get-AppxPackage *xbox*).Name $musnotification_files = @("$Env:windir\System32\musnotification.exe","$Env:windir\System32\musnotificationux.exe") $AppxOptions=@('Skip','Unhide','Hide','Uninstall') $colors = @( 'black', #0 'blue', #1 'cyan', #2 'darkblue', #3 'darkcyan', #4 'darkgray', #5 'darkgreen', #6 'darkmagenta',#7 'darkred', #8 'darkyellow', #9 'gray', #10 'green', #11 'magenta', #12 'red', #13 'white', #14 'yellow') #15 #Unicode Box Codes $Tlc = [char]0x2554 # ╔ $Blc = [char]0x255A # ╚ $Trc = [char]0x2557 # ╗ $Brc = [char]0x255D # ╝ $Sid = [char]0x2551 # ║ $ToB = [char]0x2550 # ═ Function BoxItem([String]$TxtToDisplay) { $TLen = $TxtToDisplay.Length $LLen = $TLen+9 $Ttop = "`n$Tlc".PadRight($LLen-1,$ToB) + $Trc $TBot = "$Blc".PadRight($LLen-2,$ToB) + $Brc DisplayOut $Ttop -C 14 DisplayOut $Sid," $TxtToDisplay ",$Sid -C 14,13,14 DisplayOut $TBot -C 14 } Function AnyKeyClose{ Read-Host -Prompt "`nPress Any key to Close..." } ########## # Needed Variable -End ########## # Update Functions -Start ########## Function UpdateCheck { If(InternetCheck) { $CSV_Ver = Invoke-WebRequest $Version_Url | ConvertFrom-Csv $CSVLine,$RT = If($Release_Type -eq 'Stable'){ 0,'' } Else{ 1,'Testing/' } $WebScriptVer = $CSV_Ver[$CSVLine].Version + "." + $CSV_Ver[$CSVLine].MinorVersion If($WebScriptVer -gt $Script_Version){ ScriptUpdateFun $RT } } Else { Clear-Host DisplayMisc -Line DisplayOutLML (''.PadRight(22)+'Error') -C 13 DisplayMisc -Line DisplayMisc DisplayOutLML 'No Internet connection detected or GitHub.com' -C 2 DisplayOutLML 'is currently down.' -C 2 DisplayOutLML 'Tested by pinging GitHub.com' -C 2 DisplayMisc DisplayOutLML 'To skip use one of the following methods' -C 2 DisplayOut '|',' 1. Change ','InternetCheck',' in bat file'.PadRight(28),'|' -C 14,2,15,2,14 DisplayOut '|',' 2. Change ','InternetCheck',' in bat file'.PadRight(28),'|' -C 14,2,15,2,14 DisplayOut '|',' 3. Run Script or Bat file with ','-sic',' switch ','|' -C 14,2,15,2,14 DisplayMisc DisplayMisc -Line AnyKeyClose } } Function ScriptUpdateFun([String]$RT) { $Script_Url = $URL_Base + $RT + 'Win10-Menu.ps1' $ScrpFilePath = $FileBase + 'Win10-Menu.ps1' $FullVer = "$WebScriptVer.$WebScriptMinorVer" $UpArg = '' If($Accept_ToS -ne 1){ $UpArg += '-atos ' } If($InternetCheck -eq 1){ $UpArg += '-sic ' } If($CreateRestorePoint -eq 1){ $UpArg += '-crp ' } If($Restart -eq 0){ $UpArg += '-dnr' } $UpArg += If($RunScr){ "-run $TempSetting " } Else{ "-load $TempSetting " } Clear-Host DisplayMisc -Line DisplayMisc DisplayOutLML (''.PadRight(18)+'Update Found!') -C 13 -L DisplayMisc DisplayOut '|',' Updating from version ',"$Script_Version".PadRight(30),'|' -C 14,15,11,14 -L DisplayMisc DisplayOut '|',' Downloading version ',"$FullVer".PadRight(31),'|' -C 14,15,11,14 -L DisplayOutLML 'Will run after download is complete.' -C 15 -L DisplayMisc DisplayMisc -Line (New-Object System.Net.WebClient).DownloadFile($Script_Url, $ScrpFilePath) Start-Process powershell.exe "-NoProfile -ExecutionPolicy Bypass -File `"$ScrpFilePath`" $UpArg" -Verb RunAs Exit } Function InternetCheck{ If($InternetCheck -eq 1 -or (Test-Connection www.GitHub.com -Count 1 -Quiet)){ Return $True } Return $False } ########## # Update Functions -End ########## # Multi Use Functions -Start ########## Function ThanksDonate { DisplayOut "`nThanks for using my script." -C 11 DisplayOut 'If you like this script please consider giving me a donation.' -C 11 DisplayOut "`nLink to donation:" -C 15 DisplayOut $Donate_Url -C 2 } Function cmpv{ Compare-Object (Get-Variable -Scope Script) $AutomaticVariables -Property Name -PassThru | Where-Object -Property Name -ne 'AutomaticVariables' | Where-Object { $_ -NotIn $WPFList } } Function Openwebsite([String]$Url){ Start-Process $Url } Function ShowInvalid([Int]$InvalidA){ If($InvalidA -eq 1){ Write-Host "`nInvalid Input" -ForegroundColor Red -BackgroundColor Black -NoNewline } Return 0 } Function CheckSetPath([String]$RPath){ While(!(Test-Path $RPath)){ New-Item -Path $RPath -Force | Out-Null } Return $RPath } Function RemoveSetPath([String]$RPath){ If(Test-Path $RPath){ Remove-Item -Path $RPath -Recurse } } Function StartOrGui{ SetAppxVar ;If($RunScr -eq $True){ RunScript } ElseIf($AcceptToS -ne 1){ GuiStart } } Function DisplayOut { Param ( [Alias ("T")] [String[]]$Text, [Alias ("C")] [Int[]]$Color ) For($i=0 ;$i -lt $Text.Length ;$i++){ Write-Host $Text[$i] -ForegroundColor $colors[$Color[$i]] -BackgroundColor 'Black' -NoNewLine } ;Write-Host } Function DisplayOutLML { Param ( [Alias('T')] [String]$Text, [Alias('C')] [Int[]]$Color ) DisplayOut '| ',"$Text".PadRight(50),' |' -C 14,$Color,14 } Function DisplayMisc { Param ( [Switch]$Line, [Int]$Misc = 14 ) $txt = If($Line){ '|'.PadRight(53,'-') + '|' } Else{ '|'.PadRight(53) + '|' } #Line or Blank Spaces $Splat = @{ Text = $txt ;Color = $Misc } DisplayOut @Splat } Function ScriptPreStart { SetDefault If($PassedArg.Length -gt 0){ ArgCheck } If($AcceptToS -eq 1){ TOS } Else{ StartOrGui } } Function SetAppxVar { $Script:DataGridApps = [PSCustomObject] @{ AppxName = 'Microsoft.3DBuilder'; CName = '3DBuilder'; VarName = 'APP_3DBuilder'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_3DBuilder]}, [PSCustomObject] @{ AppxName = 'Microsoft.Microsoft3DViewer'; CName = '3DViewer'; VarName = 'APP_3DViewer'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_3DViewer]}, [PSCustomObject] @{ AppxName = 'Microsoft.BingWeather'; CName = 'Bing Weather'; VarName = 'APP_BingWeather'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_BingWeather]}, [PSCustomObject] @{ AppxName = 'Microsoft.CommsPhone'; CName = 'Phone'; VarName = 'APP_CommsPhone'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_CommsPhone]}, [PSCustomObject] @{ AppxName = 'Microsoft.windowscommunicationsapps'; CName = 'Calendar & Mail'; VarName = 'APP_Communications'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_Communications]}, [PSCustomObject] @{ AppxName = 'Microsoft.GetHelp'; CName = "Microsoft's Self-Help"; VarName = 'APP_GetHelp'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_GetHelp]}, [PSCustomObject] @{ AppxName = 'Microsoft.Getstarted'; CName = 'Get Started Link'; VarName = 'APP_Getstarted'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_Getstarted]}, [PSCustomObject] @{ AppxName = 'Microsoft.Messaging'; CName = 'Messaging'; VarName = 'APP_Messaging'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_Messaging]}, [PSCustomObject] @{ AppxName = 'Microsoft.MicrosoftOfficeHub'; CName = 'Get Office Link'; VarName = 'APP_MicrosoftOffHub'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_MicrosoftOffHub]}, [PSCustomObject] @{ AppxName = 'Microsoft.MovieMoments'; CName = 'Movie Moments'; VarName = 'APP_MovieMoments'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_MovieMoments]}, [PSCustomObject] @{ AppxName = '4DF9E0F8.Netflix'; CName = 'Netflix'; VarName = 'APP_Netflix'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_Netflix]}, [PSCustomObject] @{ AppxName = 'Microsoft.Office.OneNote'; CName = 'Office OneNote'; VarName = 'APP_OfficeOneNote'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_OfficeOneNote]}, [PSCustomObject] @{ AppxName = 'Microsoft.Office.Sway'; CName = 'Office Sway'; VarName = 'APP_OfficeSway'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_OfficeSway]}, [PSCustomObject] @{ AppxName = 'Microsoft.OneConnect'; CName = 'One Connect'; VarName = 'APP_OneConnect'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_OneConnect]}, [PSCustomObject] @{ AppxName = 'Microsoft.People'; CName = 'People'; VarName = 'APP_People'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_People]}, [PSCustomObject] @{ AppxName = 'Microsoft.Windows.Photos'; CName = 'Photos'; VarName = 'APP_Photos'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_Photos]}, [PSCustomObject] @{ AppxName = 'Microsoft.SkypeApp'; CName = 'Skype'; VarName = 'APP_SkypeApp1'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_SkypeApp1]}, [PSCustomObject] @{ AppxName = 'Microsoft.MicrosoftSolitaireCollection'; CName = 'Microsoft Solitaire'; VarName = 'APP_SolitaireCollect'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_SolitaireCollect]}, [PSCustomObject] @{ AppxName = 'Microsoft.MicrosoftStickyNotes'; CName = 'Sticky Notes'; VarName = 'APP_StickyNotes'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_StickyNotes]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsSoundRecorder'; CName = 'Voice Recorder'; VarName = 'APP_VoiceRecorder'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_VoiceRecorder]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsAlarms'; CName = 'Alarms and Clock'; VarName = 'APP_WindowsAlarms'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsAlarms]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsCalculator'; CName = 'Calculator'; VarName = 'APP_WindowsCalculator'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsCalculator]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsCamera'; CName = 'Camera'; VarName = 'APP_WindowsCamera'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsCamera]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsFeedback'; CName = 'Windows Feedback'; VarName = 'APP_WindowsFeedbak1'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsFeedbak1]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsFeedbackHub'; CName = 'Windows Feedback Hub'; VarName = 'APP_WindowsFeedbak2'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsFeedbak2]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsMaps'; CName = 'Maps'; VarName = 'APP_WindowsMaps'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsMaps]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsPhone'; CName = 'Phone Companion'; VarName = 'APP_WindowsPhone'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsPhone]}, [PSCustomObject] @{ AppxName = 'Microsoft.WindowsStore'; CName = 'Microsoft Store'; VarName = 'APP_WindowsStore'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsStore]}, [PSCustomObject] @{ AppxName = 'Microsoft.Wallet'; CName = 'Stores Credit and Debit Card Information'; VarName = 'APP_WindowsWallet'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_WindowsWallet]}, [PSCustomObject] @{ AppxName = $Xbox_Apps; CName = 'Xbox Apps (All)'; VarName = 'APP_XboxApp'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_XboxApp]}, [PSCustomObject] @{ AppxName = 'Microsoft.ZuneMusic'; CName = 'Groove Music'; VarName = 'APP_ZuneMusic'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_ZuneMusic]}, [PSCustomObject] @{ AppxName = 'Microsoft.ZuneVideo'; CName = 'Groove Video'; VarName = 'APP_ZuneVideo'; AppOptions = $AppxOptions; AppSelected = $AppxOptions[$APP_ZuneVideo]} If($WPF_dataGrid){ $WPF_dataGrid.ItemsSource = $DataGridApps } } Function PassVal([String]$Pass){ Return $PassedArg[$PassedArg.IndexOf($Pass)+1] } Function ArgCheck { If($PassedArg -In '-help','-h'){ ShowHelp } If($PassedArg -Contains '-copy'){ ShowCopyright ;Exit } If($PassedArg -Contains '-run') { $tmp = PassVal '-run' If(Test-Path -LiteralPath $tmp -PathType Leaf) { LoadSettingFile $tmp ;$Script:RunScr = $True } ElseIf($tmp -In 'wd','windefault') { LoadWinDefault ;$Script:RunScr = $True } ElseIf($tmp.StartsWith('-') -or $PassedArg.IndexOf('-run') -eq $PassedArg.Length) { $Script:RunScr = $True } } If($PassedArg -Contains '-load') { $tmp = PassVal '-load' If(Test-Path -LiteralPath $tmp -PathType Leaf){ LoadSettingFile $tmp } ElseIf($tmp -In 'wd','windefault'){ LoadWinDefault } } If($PassedArg -Contains '-sic'){ $Script:InternetCheck = 1 } If($PassedArg -Contains '-usc'){ $Script:VersionCheck = 1 } If($PassedArg -Contains '-atos'){ $Script:AcceptToS = 'Accepted' } If($PassedArg -Contains '-dnr'){ $Script:Restart = 0 } If($PassedArg -Contains '-auto'){ $Script:Automated = 1 ;$Script:AcceptToS = 'Accepted' } If($PassedArg -Contains '-crp') { $Script:CreateRestorePoint = 1 $tmp = PassVal '-crp' If(!$tmp.StartsWith('-')){ $Script:RestorePointName = $tmp } } } Function ShowHelp { Clear-Host DisplayOut ' List of Switches' -C 13 DisplayOut ''.PadRight(53,'-') -C 14 DisplayOut ' Switch ',"Description of Switch`n".PadLeft(31) -C 14,15 DisplayOut '-- Basic Switches --' -C 2 DisplayOut ' -atos ',' Accepts ToS' -C 14,15 DisplayOut ' -auto ',' Implies ','-atos','...Runs the script to be Automated.. Closes on - User Input, Errors, or End of Script' -C 14,15,14,15 DisplayOut ' -crp ',' Creates Restore Point' -C 14,15 DisplayOut ' -dnr ',' Do Not Restart when done' -C 14,15 DisplayOut "`n-- Run Script Switches --" -C 2 DisplayOut ' -run ',' Runs script with settings in script' -C 14,15 DisplayOut ' -run ','FILENAME ',' Runs script with settings in the file',' FILENAME' -C 14,11,15,11 DisplayOut ' -run wd ',' Runs script with win default settings' -C 14,15 DisplayOut "`n-- Load Script Switches --" -C 2 DisplayOut ' -run ','FILENAME ',' Loads script with settings in the file',' FILENAME' -C 14,11,15,11 DisplayOut ' -load wd ',' Loads script with win default settings' -C 14,15 DisplayOut "`n--Update Switches--" -C 2 DisplayOut ' -usc ',' Checks for Update to Script file before running' -C 14,15 DisplayOut ' -sic '," Skips Internet Check, if you can't ping GitHub.com for some reason" -C 14,15 DisplayOut "`n--Help--" -C 2 DisplayOut ' -help ',' Shows list of switches, then exits script.. alt ','-h' -C 14,15,14 DisplayOut ' -copy ',' Shows Copyright/License Information, then exits script' -C 14,15 AnyKeyClose Exit } Function ShowCopyright { Clear-Host ;DisplayOut $Copyright -C 14 } Function TOSDisplay([Switch]$C) { If(!$C){ Clear-Host } $BC = 14 If($Release_Type -ne 'Stable') { $BC = 15 DisplayMisc -Line -Misc 15 DisplayOut '|'.PadRight(22),'Caution!!!'.PadRight(31),'|' -C 15,13,15 DisplayMisc -Misc 15 DisplayOut '|',' This script is still being tested. ','|' -C 15,14,15 DisplayOut '|'.PadRight(17),'USE AT YOUR OWN RISK.'.PadRight(36),'|' -C 15,14,15 DisplayMisc -Misc 15 } DisplayMisc -Line -Misc $BC DisplayOut '|'.PadRight(21),'Terms of Use'.PadRight(32),'|' -C $BC,11,$BC DisplayMisc -Line -Misc $BC DisplayMisc -Misc $BC DisplayOut '|',' This program comes with ABSOLUTELY NO WARRANTY. ','|' -C $BC,2,$BC DisplayOut '|',' This is free software, and you are welcome to ','|' -C $BC,2,$BC DisplayOut '|',' redistribute it under certain conditions.'.PadRight(52),'|' -C $BC,2,$BC DisplayMisc -Misc $BC DisplayOut '|',' Read License file for full Terms.'.PadRight(52),'|' -C $BC,2,$BC DisplayMisc -Misc $BC DisplayOut '|',' Use the switch ','-copy',' to see License Information or ','|' -C $BC,2,14,2,$BC DisplayOut '|',' enter ','L',' bellow.'.PadRight(44),'|' -C $BC,2,14,2,$BC DisplayMisc -Misc $BC DisplayMisc -Line -Misc $BC } Function TOS { $CopyR = $False While($TOS -ne 'Out') { TOSDisplay -c:$CopyR $CopyR = $False $Invalid = ShowInvalid $Invalid $TOS = Read-Host "`nDo you Accept? (Y)es/(N)o" If($TOS -In 'n','no'){ Exit } ElseIf($TOS -In 'y','yes') { $Script:AcceptToS = 'Accepted-Script' ;$TOS = 'Out' ;StartOrGui } ElseIf($TOS -eq 'l') { $CopyR = $True ;ShowCopyright } Else { $Invalid = 1 } } Return } Function LoadSettingFile([String]$Filename) { If($Filename) { (Import-Csv -LiteralPath $Filename -Delimiter ';').ForEach{ Set-Variable $_.Name $_.Value -Scope Script } #[System.Collections.ArrayList]$Script:APPS_AppsUnhide = $AppsUnhide.Split(',') #[System.Collections.ArrayList]$Script:APPS_AppsHide = $AppsHide.Split(',') #[System.Collections.ArrayList]$Script:APPS_AppsUninstall = $AppsUninstall.Split(',') SetAppxVar } } Function SaveSettingFiles([String]$Filename) { If($Filename) { #ForEach($temp In $APPS_AppsUnhide){$Script:AppsUnhide += $temp + ','} #ForEach($temp In $APPS_AppsHide){$Script:AppsHide += $temp + ','} #ForEach($temp In $APPS_Uninstall){$Script:AppsUninstall += $temp + ','} If(Test-Path -LiteralPath $Filename -PathType Leaf) { If($ShowConf -eq 1){ $Conf = ConfirmMenu 2 } Else{ $Conf = $True } If($Conf){ cmpv | Select-Object Name,Value | Export-Csv -LiteralPath $Filename -Encoding 'unicode' -Force -Delimiter ';' } } Else { cmpv | Select-Object Name,Value | Export-Csv -LiteralPath $Filename -Encoding 'unicode' -Force -Delimiter ';' } } } ########## # Multi Use Functions -End ########## # GUI -Start ########## Function SetCombo([String]$Name,[String]$Item) { $Items = $Item.Split(',') $combo = $(Get-Variable -Name ('WPF_'+$Name+'_Combo') -ValueOnly) [Void] $combo.Items.Add('Skip') ForEach($CmbItm In $Items){ [void] $combo.Items.Add($CmbItm) } SelectComboBoxGen $Name $(Get-Variable -Name $Name -ValueOnly) } Function SetComboM([String]$Name,[String]$Item) { $Items = $Item.Split(',') $combo = $(Get-Variable -Name ('WPF_'+$Name+'_Combo') -ValueOnly) [Void] $combo.Items.Add('Skip') ForEach($CmbItm In $Items){ [Void] $combo.Items.Add($CmbItm) } If($Var -NotLike 'APP_*'){ SelectComboBoxGen $Name $(Get-Variable -Name $Name -ValueOnly) } } Function SelectComboBox([Array]$List) { ForEach($Var In $List) { If($Var -NotLike 'APP_*'){ SelectComboBoxGen $Var $(Get-Variable -Name $Var -ValueOnly) } } } Function SelectComboBoxGen([String]$Name,[Int]$Numb){ $(Get-Variable -Name ('WPF_'+$Name+'_Combo') -ValueOnly).SelectedIndex = $Numb } Function RestorePointCBCheck { $WPF_CreateRestorePoint_CB.IsChecked,$WPF_RestorePointName_Txt = If($CreateRestorePoint -eq 1){ $True,$True } Else{ $False,$False } } Function ConfigGUIitms { $WPF_CreateRestorePoint_CB.IsChecked = If($CreateRestorePoint -eq 1){ $True } Else{ $False } $WPF_VersionCheck_CB.IsChecked = If($VersionCheck -eq 1){ $True } Else{ $False } $WPF_InternetCheck_CB.IsChecked = If($InternetCheck -eq 1){ $True } Else{ $False } $WPF_ShowSkipped_CB.IsChecked = If($ShowSkipped -eq 1){$True } Else{ $False } $WPF_Restart_CB.IsChecked = If($Restart -eq 1){ $True } Else{ $False } $WPF_RestorePointName_Txt.Text = $RestorePointName RestorePointCBCheck } Function OpenSaveDiaglog([Int]$SorO) { $SOFileDialog = If($SorO -eq 0){ New-Object System.Windows.Forms.OpenFileDialog } Else{ New-Object System.Windows.Forms.SaveFileDialog } $SOFileDialog.InitialDirectory = $FileBase $SOFileDialog.Filter = "CSV (*.csv)| *.csv" $SOFileDialog.ShowDialog() | Out-Null If($SorO -eq 0) { LoadSettingFile $SOFileDialog.Filename ConfigGUIitms SelectComboBox $VarList SetAppxVar } Else { GuiItmToVariable SaveSettingFiles $SOFileDialog.Filename } } Function GuiStart { Clear-Host DisplayOut 'Preparing GUI, Please wait...' -C 15 [xml]$XAML = @"