Skip to content

Commit

Permalink
05 16 23 testing (#881)
Browse files Browse the repository at this point in the history
* Fix power profile (#766) (#767)

* Fix power profile query

* fix syntax

* fix

* Update Invoke-WPFUltimatePerformance.ps1

* Update winutil.ps1

* power profile fix

* add reset network with netsh (#768)

* add verbose logon (#773)

* add verbose logon

Enable or disable verbose sign in status messages. Verbose status messages may be helpful when you are troubleshooting slow startup, shutdown, logon, or logoff behavior.

* compress-into-one-checkbox

* compile winutil.ps1

* Update README.md (#774)

* Update README.md

* Update README.md

* Adding 3 programs to the install tab (#789)

* Prism Launcher - Custom FOSS minecraft launcher

* Gsudo - Command line program that allows you to elevate a program as admin.

* WingetUI - Graphical front end for winget, chochlatey and scoop

Co-authored-by: Chris Titus <[email protected]>

* add undoscript feature + implement it on every tweaks (#776)

* add undoscript feature + implement it on right click menu

- add undoscript feature
- add undo for right click menu to go back to windows 11 default right click menu by implementing undoscript feature

* undoscript for WPFMiscTweaksDisplay

* undoscript for WPFEssTweaksRemoveEdge

* undoscript for WPFEssTweaksRemoveCortana

* undoscript for WPFEssTweaksStorage

* Update Invoke-WinUtilTweaks.ps1

thanks to @DeveloperDurp

* compile

* Fix packages name (#815)

* fix-winrar_package_name

* fix-vc++_package_name

* fix #687

* implement check for admin (#818)

check if script is running as admin or not and if not then it attempt to relaunch with admin privilege.

* add "NetFx4Extended-ASPNET45" under dotnet features (#831)

* add-docker-desktop (#834)

Co-authored-by: Chris Titus <[email protected]>

* Fix 'Get Installed' for multiple-dependency apps (#835)

* Update winutil.ps1 (#858)

fix typos

* Fixing AcceptEULA on Autologin

* Program Update: Replace Origin with EA App #544 (#875)

* New Theme support, initial functions.  (#878)

* Fix power profile (#766)

* Fix power profile query

* fix syntax

* fix

* Update Invoke-WPFUltimatePerformance.ps1

* Update winutil.ps1

* power profile fix

* Adding Nomacs Opensource free and fast Image viewer

* Adding theme support

Later when this is tested well, we can do one of 2 things.
1. Pass theme on a command line so people with bad vision will have an option to have a better (more visible theme)
2. Create a drop down with themes and a save button which would save it ti some local config file

* Fix for the compile script

---------

Co-authored-by: Chris Titus <[email protected]>

* Dark Mode Enable

* auto detect theme

---------

Co-authored-by: Padsala Tushal <[email protected]>
Co-authored-by: Taken <[email protected]>
Co-authored-by: Yurin Doctrine <[email protected]>
Co-authored-by: Aaron <[email protected]>
Co-authored-by: Sahil Jassal <[email protected]>
Co-authored-by: supplefrog <[email protected]>
Co-authored-by: KonTy <[email protected]>
  • Loading branch information
8 people authored Jul 13, 2023
1 parent 2c6b459 commit 6892744
Show file tree
Hide file tree
Showing 15 changed files with 808 additions and 144 deletions.
5 changes: 4 additions & 1 deletion Compile.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ $OFS = "`r`n"
$scriptname = "winutil.ps1"


Remove-Item .\$scriptname
if (Test-Path -Path "$($scriptname)")
{
Remove-Item -Force "$($scriptname)"
}

Write-output '
################################################################################################################
Expand Down
67 changes: 51 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# Chris Titus Tech's Windows Utility

This Utility is a compilation of windows tasks I perform on each Windows system I use. It is meant to streamline *installs*, debloat with *tweaks*, troubleshoot with *config*, and fix Windows *updates*. I am extremely picky on any contributions to keep this project clean and efficient.
This Utility is a compilation of Windows tasks I perform on each Windows system I use. It is meant to streamline *installs*, debloat with *tweaks*, troubleshoot with *config*, and fix Windows *updates*. I am extremely picky about any contributions to keep this project clean and efficient.

![screen-install](screen-install.png)

Requires you to launch PowerShell or Windows Terminal As ADMINISTRATOR!
## Usage:

The recommended way is to right click on the start menu and select (PowerShell As Admin *Windows 10* - Windows Terminal As Admin *Windows 11*)
Requires you to launch PowerShell or Windows Terminal As **ADMINISTRATOR!**
The recommended way is to right-click on the start menu and select (PowerShell As Admin *Windows 10* - Windows Terminal As Admin *Windows 11*)

Launch Command:

Expand All @@ -21,34 +22,68 @@ If you are having TLS 1.2 Issues or You cannot find or resolve `christitus.com/w
```
[Net.ServicePointManager]::SecurityProtocol=[Net.SecurityProtocolType]::Tls12;iex(New-Object Net.WebClient).DownloadString('https://raw.githubusercontent.com/ChrisTitusTech/winutil/main/winutil.ps1')
```

If you are still having issues try changing your DNS provider to 1.1.1.1 or 8.8.8.8

EXE Wrapper for $10 @ https://www.cttstore.com/windows-toolbox

## Overview

- Install
- Installs all selected programs
- Has Upgrade ALL existing programs button
- Install Selection: Organize programs by category and facilitate installation by enabling users to select programs and initiate the installation process with a single click.

- Upgrade All: Upgrade all existing programs to their latest versions, ensuring users have the most up-to-date and feature-rich software.

- Uninstall Selection: Effortlessly uninstall selected programs, providing users with a streamlined way to remove unwanted software from their system.

- Get Installed: Retrieve a comprehensive list of installed programs on the system, offering users visibility into the software currently installed on their computer.

- Import / Export: Enable users to import or export the selection list of programs, allowing them to save their preferred program configurations or share them with others. This feature promotes convenience and flexibility in managing program selections across different systems.

- Tweaks
- Optimizes windows and reduces running processes
- Has recommended settings for each type of system
- Recommended Selection: Provides pre-defined templates tailored for desktop, laptop, and minimal configurations, allowing users to select recommended settings and optimizations specific to their system type.

- Essential Tweaks: Offers a collection of essential tweaks aimed at improving system performance, privacy, and resource utilization. These tweaks include creating a system restore point, disabling telemetry, Wi-Fi Sense, setting services to manual, disabling location tracking, and HomeGroup, among others.

- Misc. Tweaks: Encompasses a range of various tweaks to further optimize the system. These tweaks include enabling/disabling power throttling, enabling num lock on startup, removing Cortana and Edge, disabling User Account Control (UAC), notification panel, and configuring TPM during updates, among others.

- Additional Tweaks: Introduces various other tweaks such as enabling dark mode, changing DNS settings, adding an Ultimate Performance mode, and creating shortcuts for WinUtil tools. These tweaks provide users with additional customization options to tailor their system to their preferences.

- Config
- Quick configurations for Windows Installs
- Has old legacy panels from Windows 7
- Reset Windows Update to factory settings
- System Corruption Scan
- Updates
- Fixes the default windows update scheme
- Features: Allows users to easily install various essential components and features to enhance their Windows experience. These features include installing .NET Frameworks, enabling Hyper-V virtualization, enabling legacy media support for Windows Media Player and DirectPlay, enabling NFS (Network File System) for network file sharing, and enabling Windows Subsystem for Linux (WSL) for running Linux applications on Windows.

- Fixes: Provides a range of helpful fixes to address common issues and improve system stability. This includes setting up autologon for seamless login experiences, resetting Windows updates to resolve update-related problems, performing a system corruption scan to detect and repair corrupted files, and resetting network settings to troubleshoot network connectivity issues.

- Legacy Windows Panels: Includes access to legacy Windows panels from Windows 7, allowing users to access familiar and powerful tools. These panels include Control Panel for managing system settings, Network Connections for configuring network adapters and connections, Power Panel for adjusting power and sleep settings, Sound Settings for managing audio devices and settings, System Properties for viewing and modifying system information, and User Accounts for managing user profiles and account settings.


- Updates:
- Default (Out of Box) Settings: Provides the default settings that come with Windows for updates.

- Security (Recommended) Settings: Offers recommended settings, including a slight delay of feature updates by 2 days and installation of security updates 4 days after release.

- Disable All Updates (Not Recommended!): Allows users to disable all Windows updates, but it's not recommended due to potential security risks.


Video and Written Article walkthrough @ <https://christitus.com/windows-tool/>

## Issues

If you have any issues with the script please submit them to Issues tab here on GitHub and fill out the template so I can fix any bugs or make feature requests.
If you encounter any challenges or problems with the script, I kindly request that you submit them via the "Issues" tab on the GitHub repository. By filling out the provided template, you can provide specific details about the issue, allowing me to promptly address any bugs or consider feature requests.

## Contribute Code

**Any new code must be submitted to TEST BRANCH! - No merges will be performed on MAIN branch**
To contribute a new code, please ensure that it is submitted to the **TEST BRANCH**. Please note that merges will not be performed directly on the MAIN branch.

When creating pull requests, it is essential to thoroughly document all changes made. This includes documenting any additions made to the tweaks section and ensuring that corresponding undo measures are in place to remove the newly added tweaks if necessary. Failure to adhere to this format may result in denial of the pull request. Additionally, comprehensive documentation is required for all code changes. Any code lacking sufficient documentation may also be denied.

By following these guidelines, we can maintain a high standard of quality and ensure that the codebase remains organized and well-documented.

## Thanks to all Contributors
Thanks a lot for spending your time helping Winutil grow. Thanks a lot! Keep rocking 🍻.

[![Contributors](https://contrib.rocks/image?repo=ChrisTitusTech/winutil)](https://github.com/ChrisTitusTech/winutil/graphs/contributors)

For pull requests, be sure and document ALL changes. If you add something to the tweaks section the undo MUST also be applied to remove the new tweaks. Any tweak not following this format will be denied. Any code not well documented will be denied.
## Support
- This project needs a ⭐️ from you. Don't forget to leave a star ⭐️.
- EXE Wrapper for $10 @ https://www.cttstore.com/windows-toolbox
32 changes: 26 additions & 6 deletions config/applications.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@
"winget": "Git.Git;GitHub.GitHubDesktop",
"choco": "git;github-desktop"
},
"WPFInstalldockerdesktop": {
"winget": "Docker.DockerDesktop",
"choco": "docker-desktop"
},
"WPFInstallgog": {
"winget": "GOG.Galaxy",
"choco": "goggalaxy"
Expand All @@ -115,6 +119,10 @@
"winget": "REALiX.HWiNFO",
"choco": "hwinfo"
},
"WPFInstallnomacs": {
"winget": "nomacs.nomacs",
"choco": "nomacs"
},
"WPFInstallimageglass": {
"winget": "DuongDieuPhap.ImageGlass",
"choco": "imageglass"
Expand Down Expand Up @@ -348,11 +356,11 @@
"choco": "dotnet-6.0-runtime"
},
"WPFInstallvc2015_64": {
"winget": "Microsoft.VC++2015-2022Redist-x64",
"winget": "Microsoft.VCRedist.2015+.x64",
"choco": "na"
},
"WPFInstallvc2015_32": {
"winget": "Microsoft.VC++2015-2022Redist-x86",
"winget": "Microsoft.VCRedist.2015+.x86",
"choco": "na"
},
"WPFInstallfoxpdf": {
Expand Down Expand Up @@ -460,16 +468,16 @@
"choco": "telegram"
},
"WPFInstallunity": {
"winget": "UnityTechnologies.UnityHub",
"winget": "Unity.UnityHub",
"choco": "unityhub"
},
"WPFInstallqbittorrent": {
"winget": "qBittorrent.qBittorrent",
"choco": "qbittorrent"
},
"WPFInstallorigin": {
"WPFInstalleaapp": {
"winget": "ElectronicArts.EADesktop",
"choco": "origin"
"choco": "ea-app"
},
"WPFInstallopenshell": {
"winget": "Open-Shell.Open-Shell-Menu",
Expand Down Expand Up @@ -516,7 +524,7 @@
"choco": "nuget.commandline"
},
"WPFInstallwinrar": {
"winget": "RARLab.WinRar",
"winget": "RARLab.WinRAR",
"choco": "winrar"
},
"WPFInstallneovim": {
Expand All @@ -530,5 +538,17 @@
"WPFInstallpostman": {
"winget": "Postman.Postman",
"choco": "postman"
},
"WPFInstallgsudo": {
"winget": "gerardog.gsudo",
"choco": "gsudo"
},
"WPFInstallwingetui": {
"winget": "SomePythonThings.WingetUIStore",
"choco": "na"
},
"WPFInstallprismlauncher": {
"winget": "PrismLauncher.PrismLauncher",
"choco": "na"
}
}
42 changes: 42 additions & 0 deletions config/themes.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"Classic": {
"ComboBoxBackgroundColor": "#777777",
"LabelboxForegroundColor": "#000000",
"MainForegroundColor": "#000000",
"MainBackgroundColor": "#777777",
"LabelBackgroundColor": "#777777",
"ComboBoxForegroundColor": "#000000",
"ButtonInstallBackgroundColor": "#222222",
"ButtonTweaksBackgroundColor": "#333333",
"ButtonConfigBackgroundColor": "#444444",
"ButtonUpdatesBackgroundColor": "#555555",
"ButtonInstallForegroundColor": "#FFFFFF",
"ButtonBackgroundColor": "#CACACA",
"ButtonBackgroundPressedColor": "#FFFFFF",
"ButtonBackgroundMouseoverColor": "AliceBlue",
"ButtonForegroundColor": "#000000",
"ButtonBorderThickness": "0",
"ButtonMargin": "0,3,0,3",
"ButtonCornerRadius": "0"
},
"Matrix": {
"ComboBoxBackgroundColor": "#000000",
"LabelboxForegroundColor": "#FFEE58",
"MainForegroundColor": "#9CCC65",
"MainBackgroundColor": "#000000",
"LabelBackgroundColor": "#000000",
"ComboBoxForegroundColor": "#FFEE58",
"ButtonInstallBackgroundColor": "#222222",
"ButtonTweaksBackgroundColor": "#333333",
"ButtonConfigBackgroundColor": "#444444",
"ButtonUpdatesBackgroundColor": "#555555",
"ButtonInstallForegroundColor": "#FFFFFF",
"ButtonBackgroundColor": "#000000",
"ButtonBackgroundPressedColor": "#FFFFFF",
"ButtonBackgroundMouseoverColor": "#A55A64",
"ButtonForegroundColor": "#9CCC65",
"ButtonBorderThickness": "3",
"ButtonMargin": "2",
"ButtonCornerRadius": "4"
}
}
31 changes: 31 additions & 0 deletions config/tweaks.json
Original file line number Diff line number Diff line change
Expand Up @@ -1922,6 +1922,9 @@
],
"InvokeScript": [
"Set-ItemProperty -Path \"HKCU:\\Control Panel\\Desktop\" -Name \"UserPreferencesMask\" -Type Binary -Value ([byte[]](144,18,3,128,16,0,0,0))"
],
"UndoScript": [
"Remove-ItemProperty -Path \"HKCU:\\Control Panel\\Desktop\" -Name \"UserPreferencesMask\""
]
},
"WPFEssTweaksDeBloat": {
Expand Down Expand Up @@ -2055,6 +2058,10 @@
"WPFEssTweaksStorage": {
"InvokeScript": [
"Remove-Item -Path \"HKCU:\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\StorageSense\\Parameters\\StoragePolicy\" -Recurse -ErrorAction SilentlyContinue"
],
"UndoScript": [
"New-Item -Path \"HKCU:\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\StorageSense\\Parameters\\StoragePolicy\" | Out-Null
"
]
},
"WPFMiscTweaksLapNum": {
Expand Down Expand Up @@ -2136,6 +2143,9 @@
}
}
"
],
"UndoScript": [
"winget install Microsoft.Edge"
]
},
"WPFMiscTweaksDisableNotifications": {
Expand All @@ -2159,6 +2169,12 @@
"WPFMiscTweaksRightClickMenu": {
"InvokeScript": [
"New-Item -Path \"HKCU:\\Software\\Classes\\CLSID\\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\" -Name \"InprocServer32\" -force -value \"\" "
],
"UndoScript": [
"
Remove-Item -Path \"HKCU:\\Software\\Classes\\CLSID\\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\" -Recurse -Confirm:$false -Force
Write-Host Restart Needed for change
"
]
},
"WPFEssTweaksDiskCleanup": {
Expand Down Expand Up @@ -2238,6 +2254,17 @@
}
]
},
"WPFMiscTweaksEnableVerboselogon": {
"registry": [
{
"path": "HKLM:\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\policies\\system",
"OriginalValue": "0",
"name": "VerboseStatus",
"value": "1",
"type": "DWord"
}
]
},
"WPFEssTweaksDeleteTempFiles": {
"InvokeScript": [
"Get-ChildItem -Path \"C:\\Windows\\Temp\" *.* -Recurse | Remove-Item -Force -Recurse
Expand All @@ -2247,6 +2274,10 @@
"WPFEssTweaksRemoveCortana": {
"InvokeScript": [
"Get-AppxPackage -allusers Microsoft.549981C3F5F10 | Remove-AppxPackage"
],
"UndoScript": [
"Get-AppxPackage -allusers | where Name -like \"Microsoft.549981C3F5F10\" | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register \"$($_.InstallLocation)\\AppXManifest.xml\"}
"
]
},
"WPFEssTweaksDVR": {
Expand Down
8 changes: 6 additions & 2 deletions functions/private/Invoke-WinUtilCurrentSystem.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,12 @@ Function Invoke-WinUtilCurrentSystem {

$filter = Get-WinUtilVariables -Type Checkbox | Where-Object {$psitem -like "WPFInstall*"}
$sync.GetEnumerator() | Where-Object {$psitem.Key -in $filter} | ForEach-Object {
if($sync.configs.applications.$($psitem.Key).winget -in $sync.InstalledPrograms.Id){
Write-Output $psitem.name
$dependencies = $($sync.configs.applications.$($psitem.Key).winget -split ";")

Foreach ($dependency in $dependencies) {
if($dependency -in $sync.InstalledPrograms.Id){
Write-Output $psitem.name
}
}
}
}
Expand Down
29 changes: 16 additions & 13 deletions functions/private/Invoke-WinUtilTweaks.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,16 @@ function Invoke-WinUtilTweaks {
Registry = "OriginalValue"
ScheduledTask = "OriginalState"
Service = "OriginalType"
ScriptType = "UndoScript"
}

}
Else{
$Values = @{
Registry = "Value"
ScheduledTask = "State"
Service = "StartupType"
}
}

if($sync.configs.tweaks.$CheckBox.registry){
$sync.configs.tweaks.$CheckBox.registry | ForEach-Object {
Set-WinUtilRegistry -Name $psitem.Name -Path $psitem.Path -Type $psitem.Type -Value $psitem.$($values.registry)
ScriptType = "InvokeScript"
}
}
if($sync.configs.tweaks.$CheckBox.ScheduledTask){
Expand All @@ -40,18 +37,24 @@ function Invoke-WinUtilTweaks {
Set-WinUtilService -Name $psitem.Name -StartupType $psitem.$($values.Service)
}
}
if($sync.configs.tweaks.$CheckBox.registry){
$sync.configs.tweaks.$CheckBox.registry | ForEach-Object {
Set-WinUtilRegistry -Name $psitem.Name -Path $psitem.Path -Type $psitem.Type -Value $psitem.$($values.registry)
}
}
if($sync.configs.tweaks.$CheckBox.$($values.ScriptType)){
$sync.configs.tweaks.$CheckBox.$($values.ScriptType) | ForEach-Object {
$Scriptblock = [scriptblock]::Create($psitem)
Invoke-WinUtilScript -ScriptBlock $scriptblock -Name $CheckBox
}
}

if(!$undo){
if($sync.configs.tweaks.$CheckBox.appx){
$sync.configs.tweaks.$CheckBox.appx | ForEach-Object {
Remove-WinUtilAPPX -Name $psitem
}
}
if($sync.configs.tweaks.$CheckBox.InvokeScript){
$sync.configs.tweaks.$CheckBox.InvokeScript | ForEach-Object {
$Scriptblock = [scriptblock]::Create($psitem)
Invoke-WinUtilScript -ScriptBlock $scriptblock -Name $CheckBox
}
}

}
}
}
Loading

0 comments on commit 6892744

Please sign in to comment.