This PowerShell script is an attempt to create a graphical user interface (GUI) that acts as a "Program Manager" for the Windows Package Manager (winget). Its intended purpose is to allow users to search for applications available through winget and install them from a user-friendly interface, without needing to use the command line directly.
The script uses advanced PowerShell concepts, including background jobs (Start-Job), to run winget operations asynchronously to prevent the GUI from freezing.
This script is a developmental example and is not guaranteed to be functional.
To attempt to run this script, you will need:
- Windows Operating System.
- PowerShell 5.1 or newer.
- .NET Framework: Required for the Windows Forms GUI.
- Windows Package Manager (
winget):wingetmust be installed and accessible from your system's PATH.
- Download: Download the
CRASHES HiddenSettings.PS1script file. - Unblock: Right-click the file, go to Properties, and click
Unblockif it was downloaded from the internet. - Run: Execute the script from a PowerShell console.
."\CRASHES HiddenSettings.PS1"
The intended functionality of the application is as follows:
- Upon launch, the script is supposed to load all packages available via
winget. - Users can type a search term in the search box and click Search to filter the list of programs.
- The list view should display the Name, ID, Version, and Source of the available packages.
- Users can select one or more programs from the list and click Install Selected to begin the installation process.
- GUI Front-End: Uses Windows Forms to create a familiar program manager interface.
wingetWrapper: The script is designed to be a graphical wrapper around thewinget searchandwinget installcommands.- Asynchronous Operations: Attempts to use
Start-Jobto run thewinget searchcommand in the background to keep the UI from freezing. This is a complex operation and is a likely source of the script's instability. - Dynamic UI Updates: The script is intended to populate the list of programs with the results from the background job.
- Scripting Language: PowerShell
- GUI Framework: .NET Windows Forms (WinForms).
- Backend: Windows Package Manager (
winget). - Concurrency: PowerShell Jobs (
Start-Job).
- Unstable Code: This script is provided for educational or diagnostic purposes only. Its filename indicates it is prone to crashing. The use of background jobs, inter-thread communication (
Invoke), andInvoke-Expressioncan lead to race conditions and unhandled exceptions. - Administrator Privileges: While not explicitly enforced with a self-elevation check, installing software via
wingettypically requires administrator rights.
Distributed under the MIT License. See LICENSE.txt for more information.
Zach Whiteman - elitesoftwarecolimited@gmail.com
HuggingFace - https://huggingface.co/EliteSoftware
HuggingFace (Personal) - https://huggingface.co/TheShadyRainbow
LinkTree - https://linktr.ee/zachrainbow