Compare commits

...

77 Commits

Author SHA1 Message Date
Gabi
c71fad54dc
Change formating in WPFTweaksRemoveCopilot (#3808) 2025-12-15 10:17:47 -06:00
Gabi
4eb76a9099
Cleanup-WPFTweaksServices (#3806)
* Remove unneccary services from WPFTweaksServices

* Update tweaks.json
2025-12-15 10:16:59 -06:00
Gabi
95d8660b3a
Update WPFToggleStartMenuRecommendations (#3805) 2025-12-15 10:16:19 -06:00
ChrisTitusTech
4bd25e62e1 Deploying to main from @ ChrisTitusTech/winutil@da6b105573 🚀 2025-12-15 15:37:23 +00:00
Gabi
da6b105573
Remove Services from WPFTweaksServices (#3732) 2025-12-12 09:00:51 -06:00
Gabi
64022cc08d
Remove unneccary ScheduledTasks from WPFTweaksTele (#3764) 2025-12-12 09:00:02 -06:00
Gabi
401f7f384a
Remove-WPFTweaksWifi (#3765)
* Remove WPFTweaksWifi From Standart preset

* Remove WPFTweaksWifi
2025-12-12 08:59:29 -06:00
Gabi
e2efb3a483
Update WPFTweaksRemoveCopilot (#3768) 2025-12-12 08:58:59 -06:00
Gabi
4dc0fd6a6e
Delete-WPFTweaksRecallOff (#3769)
Co-authored-by: Chris Titus <dfm.titus@gmail.com>
2025-12-12 08:58:01 -06:00
Gabi
f671ad4518
Update-WPFTweaksRazerBlock (#3770)
* Update WPFTweaksRazerBlock's InvokeScript

* Format fix for WPFTweaksRazerBlock

* Update WPFTweaksRazerBlock

* Update WPFTweaksRazerBlock

* Update WPFTweaksRazerBlock

* Better format for WPFTweaksRazerBlock's InvokeScript

* Better format for WPFTweaksRazerBlock's InvokeScript

* Fomat fix on WPFTweaksRazerBlock
2025-12-12 08:55:27 -06:00
Gabi
c2cb00fc68
Remove-WPFTweaksDebloatAdobe (#3771)
* Remove WPFTweaksDebloatAdobe

* Delete functions/public/Invoke-WPFRunAdobeCCCleanerTool.ps1

* Update feature.json

* Update feature.json

* Create Invoke-WPFRunAdobeCCCleanerTool.ps1
2025-12-12 08:48:43 -06:00
Gabi
7503444e2b
Rename-WPFTweaksLoc (#3773)
* Rename WPFTweaksLoc

* Rename WPFTweaksLoc
2025-12-12 08:47:35 -06:00
Gabi
80ab6ba005
Description update for WPFTweaksConsumerFeatures (#3774) 2025-12-12 08:47:15 -06:00
Gabi
2e0073af75
Update-WPFTweaksTele (#3775)
* Update WPFTweaksTele's InvokeScript

* Update WPFTweaksTele's InvokeScript
2025-12-12 08:46:54 -06:00
Gabi
3cb0a4b664
Deleted WPFTweaksDisableLMS1 (#3776)
Co-authored-by: Chris Titus <dfm.titus@gmail.com>
2025-12-11 14:33:01 -06:00
Gabi
e9b40ae710
Description Update for WPFTweaksDisableEdge (#3778) 2025-12-11 14:25:32 -06:00
Gabi
408327daec
Delete-WPFTweaksStorage (#3779)
* Remove WPFTweaksStorage from Standart Preset

* Remove WPFTweaksStorage

* move to advanced tweaks
2025-12-11 14:22:49 -06:00
Gabi
7f7424406f
Rename WPFTweaksDisableWpbtExecution (#3780) 2025-12-11 14:18:04 -06:00
Gabi
ccc44414a2
Rename WPFTweaksDisableipsix (#3782) 2025-12-11 14:09:26 -06:00
Gabi
06ea48dd01
Delete-WPFTweaksRemoveOnedrive (#3785)
* Update tweaks.json

* Update-WPFTweaksRemoveOnedrive

* Update-WPFTweaksRemoveOnedrive

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Delete WPFTweaksRemoveOnedrive
2025-12-11 14:03:54 -06:00
Gabi
5a6b1ef086
Update-WPFTweaksLaptopHibernation (#3786)
* Update WPFTweaksLaptopHibernation's InvokeScript

* Update WPFTweaksLaptopHibernation's Script
2025-12-11 14:01:16 -06:00
Gabi
aba3d786bc
Update applications.json (#3791) 2025-12-11 13:58:41 -06:00
Gabi
7765c1032b
Add-WPFTweaksMakeEdgeUninstallable (#3792)
* Add WPFTweaksMakeEdgeUninstallable

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* formating fix
2025-12-11 13:55:34 -06:00
Gabi
015f1b0709
Replace-System.IO.Directory (#3794)
* Update main.ps1

* Update start.ps1

* Update main.ps1

* Update main.ps1
2025-12-11 13:34:03 -06:00
Gabi
19b6f8abfa
Remove-Reg.exe (#3798)
* Update WPFTweaksRemoveHome to use powershell

* Fix WPFTweaksRemoveGallery format

* Format fix for WPFTweaksRemoveHome

* Update tweaks.json

* fix my f up

* Update tweaks.json to use registry modifications

Replaced InvokeScript and UndoScript with registry modifications for removing Home from Explorer and setting This PC as default.

* fix missing comma from twitch chat
2025-12-11 13:13:16 -06:00
ChrisTitusTech
80e872aa60 Deploying to main from @ ChrisTitusTech/winutil@cfaf139a6a 🚀 2025-12-02 15:36:46 +00:00
CodingWonders
cfaf139a6a
[Tweaks] Conditionally determine when to use sc and Set-Service (#3761)
* [Tweaks] Conditionally determine when to use sc and Set-Service

* Clean up comments in Set-WinUtilService.ps1

Removed comments explaining the handling of auto delayed start for PWSH 5.

---------

Co-authored-by: Chris Titus <contact@christitus.com>
2025-12-01 14:29:27 -06:00
Chris Titus Tech
becfba603d clean up spacing 2025-12-01 07:49:40 -06:00
makhlwf
2b68976e7b
feat(accessibility): add accessibility labels to tweaks ui (#3731) 2025-12-01 13:45:58 -06:00
Gabi
5369d9d99b
Add Create Issue (#3729) 2025-12-01 13:41:59 -06:00
Gabi
8b3e1280df
Update-WPFTweaksDeBloat (#3709)
* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Added comments to InvokeScript of WPFTweaksDeBloat

* Update tweaks.json

* Update tweaks.json
2025-12-01 13:41:28 -06:00
Alvaro Parker
ce77be324b
Add zed to applications (#3734) 2025-12-01 13:31:44 -06:00
Soumyadip Nayak
6168e93d4c
Remove deprecated CryptoWalletEnabled policy from Edge debloat tweaks (#3737) 2025-12-01 13:29:59 -06:00
Younes Aassila
d98118e322
Fix #3736 (#3748) 2025-12-01 13:26:21 -06:00
dependabot[bot]
f69f107d9d
Bump actions/checkout from 5 to 6 (#3745)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-01 13:20:16 -06:00
Gabi
f3c3613d26
OneDrive Removal Updated, read description (#3659)
* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Remove Unneccary -ErrorAction in OneDrive-Removal

* Format fixes for WPFTweaksRemoveOnedrive
2025-12-01 13:18:08 -06:00
Chris Titus Tech
b265675560 Removal of more winget user scope code 2025-11-17 07:37:29 -06:00
Chris Titus
e0237642c8
commit for removal of user scope progs and user scope winget (#3727) 2025-11-17 13:10:44 -06:00
Gabi
aedaa2f789
Update-WPFTweaksStorage (#3717)
* Update tweaks.json

* Syntax fix for WPFTweaksStorage

* Merge branch 'ChrisTitusTech:main' into Update-WPFTweaksStorage
2025-11-17 12:52:14 -06:00
Gabi
8c2f9075a0
Rename-WPFTweaksAH (#3715)
* Update tweaks.json

* Update preset.json

* Merge branch 'ChrisTitusTech:main' into Rename-WPFTweaksAH
2025-11-17 12:51:29 -06:00
Chris Titus Tech
c9e6861ad4 final fix for tweaks order 2025-11-17 06:50:06 -06:00
Chris Titus Tech
43ec73684e fix up ordering for tweaks 2025-11-17 06:46:54 -06:00
Gabi
bfbb643543
Update-WPFTweaksEndTaskOnTaskbar (#3714)
* Update tweaks.json

* Syntax fix on WPFTweaksEndTaskOnTaskbar

* Merge branch 'ChrisTitusTech:main' into Update-WPFTweaksEndTaskOnTaskbar
2025-11-17 12:11:39 -06:00
Gabi
067ec31086
Update-WPFTweaksBlockAdobeNet (#3708)
* Update tweaks.json

* Fix

* Final Fix

* Added comments to WPFTweaksBlockAdobeNet

* Syntax change for WPFTweaksBlockAdobeNet

* Removed double \ from WPFTweaksBlockAdobeNet

* Added back double \ for WPFTweaksBlockAdobeNet

* Syntax fix for WPFTweaksBlockAdobeNet

* Syntax fix for WPFTweaksBlockAdobeNet again

* Fix for WPFTweaksBlockAdobeNet

* Merge branch 'ChrisTitusTech:main' into Update-WPFTweaksBlockAdobeNet
2025-11-17 12:07:23 -06:00
Gabi
63221a7cb9
Remove-WPFFeatureSearchSuggestions (#3706)
* Update feature.json

* Merge branch 'ChrisTitusTech:main' into Remove-WPFFeatureSearchSuggestions
2025-11-17 12:04:31 -06:00
Gabi
7e40d379d8
Update-WPFTweaksDeleteTempFiles (#3705)
* Update tweaks.json

* Add -Path for better syntax

* Fix

* Merge branch 'ChrisTitusTech:main' into Update-WPFTweaksDeleteTempFiles
2025-11-17 12:00:21 -06:00
Myles Markevich
c766c974cf
Fix typo in oscdimg.exe message box text (#3701) 2025-11-17 11:55:42 -06:00
Gabi
7d2804c706
Remove WPFTweaksHome (#3687)
* Remove WPFTweaksHome from tweaks.jsom

* Remove WPFTweaksHome from preset.json

* Merge branch 'ChrisTitusTech:main' into Remove-WPFTweaksHome

* Merge branch 'ChrisTitusTech:main' into Remove-WPFTweaksHome
2025-11-17 11:54:58 -06:00
Gabi
2ee9047dd6
Duplicates and Typos (#3660)
* Rename m to M

* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Merge branch 'ChrisTitusTech:main' into Typo-Fix

* Merge branch 'ChrisTitusTech:main' into Typo-Fix

* Extra space

* From Tweaks to Toggle

* Merge branch 'ChrisTitusTech:main' into Typo-Fix
2025-11-17 11:48:07 -06:00
Ivan Lepekha
21c49d6a75
Fix explanation logic in 'WPFToggleSnapFlyout' (#3648) 2025-11-17 11:44:53 -06:00
Chris Titus Tech
351a77043e fix application errors from hyphens 2025-11-17 05:42:43 -06:00
Cube1ber
c8bb38f3a9
Added Proton Authenticator to applications.json (#3643)
* Added Proton Authenticator to applications.json

Proton Authenticator is a popular open source 2fa app from proton.

* Update name in applications.json

---------

Co-authored-by: CyberSphinx <202843220+CyberSphonx@users.noreply.github.com>
2025-11-17 11:33:49 -06:00
Ivan Lepekha
5fb5e43cc7
[Applications] Adding Ente Auth (#3635)
* Applications: Added Ente Auth

* Applications: Added Kando

* Revert "Applications: Added Kando"

This reverts commit 6a3e22f868c5f59dba72689cf54861bd424c8431.
2025-11-17 11:32:53 -06:00
Akhil Kumar Achanta
eeb410e985
fix(tweaks): Correct operator for checking tweak type in Invoke-WinUtilTweaks (#3625)
The Invoke-WinUtilTweaks function was using the '-contains' operator on a string variable to check for toggle-type tweaks. This operator is intended for collections (arrays), not for substring matching within a string, leading to incorrect logic flow.

This caused an issue where selecting one tweak (e.g., WPFTweaksRightClickMenu) could erroneously trigger the action of another (e.g., WPFTweaksDisableCrossDeviceResume).

This commit replaces the incorrect '-contains' operator with the '-like' operator and appropriate wildcards ('*Toggle*'). This ensures that tweak types are identified correctly, resolving the bug and preventing unintended system modifications.
2025-11-17 11:29:56 -06:00
Akhil Kumar Achanta
8eaf6ddd9c
feat: Add Beeper to Messaging applications (#3617)
* feat: Add Beeper to Messaging applications

This commit adds the Beeper desktop application to the list of installable packages in the "Messaging" category.

The entry has been added to `config/applications.json` with the official download URL and the correct silent installation arguments.

Fixes #3608

* Fix job failure: ensure excluded directory exists before processing

This commit updates the Invoke-Preprocessing function to prevent workflow failures caused by missing excluded directories.
Previously, the script would attempt to recursively list files in excluded paths, resulting in an error if a directory did not exist.
The updated logic checks if the excluded path refers to a directory (ends with a backslash) and creates it if necessary before proceeding. This avoids "Cannot find path" errors and ensures smoother preprocessing, especially for jobs that depend on directory existence for exclusion logic.
No changes are made for excluded files or wildcard patterns.
2025-11-17 11:24:28 -06:00
Brian
3c54e0ea3f
Fix Multiplane Overlay toggle (#3632) 2025-11-17 11:19:12 -06:00
Gabi
d17e8bcd98
Remove dns0.eu (#3682)
* Update dns.json

* Forgot one

* Forgot this
2025-11-17 11:18:31 -06:00
ChrisTitusTech
ef1fc2ae59 Deploying to main from @ ChrisTitusTech/winutil@7d1fb52277 🚀 2025-11-17 15:35:22 +00:00
ChrisTitusTech
7d1fb52277 Deploying to main from @ ChrisTitusTech/winutil@95988fca80 🚀 2025-11-15 15:31:46 +00:00
ChrisTitusTech
95988fca80 Deploying to main from @ ChrisTitusTech/winutil@451040b5b1 🚀 2025-11-14 15:33:01 +00:00
ChrisTitusTech
451040b5b1 Deploying to main from @ ChrisTitusTech/winutil@47cb6b9273 🚀 2025-11-08 15:31:28 +00:00
ChrisTitusTech
47cb6b9273 Deploying to main from @ ChrisTitusTech/winutil@69233b1d8a 🚀 2025-11-01 15:30:51 +00:00
Gabi
69233b1d8a
Update Disable Edge Tweak (#3649)
* Update tweaks.json

* Update tweaks.json

* Update tweaks.json

* Remove Disable edge invoke script

Removed scripts for disabling and enabling Microsoft Edge Update tasks.

* Update tweaks.json

* Update tweaks.json
2025-10-23 13:55:52 -05:00
ChrisTitusTech
b621d9104e Deploying to main from @ ChrisTitusTech/winutil@1f81eec8f1 🚀 2025-10-20 15:33:21 +00:00
Viktor Szépe
1f81eec8f1
Fix typos (#3637) 2025-10-14 12:51:53 -05:00
Robyn C. Maehl
72cbdca556
Fix christitustech.github.io 404 links (#3629)
* Fix Contributing Link in Pull Request Template

* Update 404 to christitustech.github.io
2025-10-14 12:44:36 -05:00
CatBraaain
d5127b14a3
fix(tweaks): remove duplicated (#3626) 2025-10-14 12:43:03 -05:00
Gabi
e2c84d9834
Add Disable Edge Tweak (#3613)
* Update tweaks.json

* Update tweaks.json

* Update tweaks.json
2025-10-14 12:20:00 -05:00
ChrisTitusTech
c454c93563 Deploying to main from @ ChrisTitusTech/winutil@70b1274425 🚀 2025-10-14 15:33:52 +00:00
ChrisTitusTech
70b1274425 Deploying to main from @ ChrisTitusTech/winutil@3b26620627 🚀 2025-10-08 15:33:58 +00:00
Chris Titus Tech
3b26620627 fix missing file paths for unit test during prepossess 2025-10-06 10:05:36 -05:00
Chris Titus Tech
eeee941eb3 fix formatting 2025-10-06 09:57:32 -05:00
Chris Titus Tech
242fa6f210 temp disable of offline for online users 2025-10-06 09:55:25 -05:00
Chris Titus Tech
634ef3266c add windows restore to config tab 2025-10-06 09:51:48 -05:00
ChrisTitusTech
a87c301636 Deploying to main from @ ChrisTitusTech/winutil@674d1368bb 🚀 2025-10-01 15:33:36 +00:00
CodingWonders
674d1368bb
[Offline] Fixed invalid command in PWSH 5 (#3604)
-TimeoutSeconds is not a parameter in Test-Connection for PWSH 5
2025-09-21 16:21:18 -05:00
Chris Titus Tech
c7495059fd Offline Capabilities 2025-09-18 10:26:11 -05:00
41 changed files with 354 additions and 1293 deletions

View File

@ -87,7 +87,7 @@ graph TD
### Testing your changes ### Testing your changes
* To test to see if your changes work as intended run following commands in a powershell teminal as admin: * To test to see if your changes work as intended run following commands in a powershell terminal as admin:
* Change the directory where you are running the commands to the forked project. * Change the directory where you are running the commands to the forked project.
* `cd {path to the folder with the compile.ps1}` * `cd {path to the folder with the compile.ps1}`

View File

@ -1,4 +1,4 @@
<!--Before you make this PR have you followed the docs here? - https://christitustech.github.io/winutil/contribute/ --> <!--Before you make this PR have you followed the docs here? - https://winutil.christitus.com/contributing/ -->
## Type of Change ## Type of Change
- [ ] New feature - [ ] New feature

View File

@ -9,7 +9,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Check if PR was merged - name: Check if PR was merged
if: github.event.pull_request.merged == true if: github.event.pull_request.merged == true

View File

@ -13,7 +13,7 @@ jobs:
runs-on: windows-latest runs-on: windows-latest
steps: steps:
- name: Checkout Sources - name: Checkout Sources
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Compile and Syntaxcheck winutil.ps1 - name: Compile and Syntaxcheck winutil.ps1
shell: pwsh shell: pwsh

View File

@ -14,7 +14,7 @@ jobs:
CERTIFICATE_BASE64: ${{ secrets.CERTIFICATE_BASE64 }} CERTIFICATE_BASE64: ${{ secrets.CERTIFICATE_BASE64 }}
steps: steps:
- name: Checkout Repository - name: Checkout Repository
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Compile project - name: Compile project
shell: pwsh shell: pwsh

View File

@ -11,7 +11,7 @@ jobs:
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Check if winutil.ps1 exists - name: Check if winutil.ps1 exists
id: check_existence id: check_existence

View File

@ -11,7 +11,7 @@ jobs:
if: (github.event_name == 'schedule' && github.repository == 'ChrisTitusTech/winutil') || (github.event_name != 'schedule') if: (github.event_name == 'schedule' && github.repository == 'ChrisTitusTech/winutil') || (github.event_name != 'schedule')
steps: steps:
- name: Checkout 🛎️ - name: Checkout 🛎️
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Generate Sponsors 💖 - name: Generate Sponsors 💖
uses: JamesIves/github-sponsors-readme-action@v1 uses: JamesIves/github-sponsors-readme-action@v1

View File

@ -8,7 +8,7 @@ jobs:
name: PS Script Analyzer name: PS Script Analyzer
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v5 - uses: actions/checkout@v6
- name: lint - name: lint
uses: devblackops/github-action-psscriptanalyzer@master uses: devblackops/github-action-psscriptanalyzer@master
with: with:
@ -22,7 +22,7 @@ jobs:
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v5 uses: actions/checkout@v6
- name: Install Pester - name: Install Pester
run: | run: |

View File

@ -51,7 +51,24 @@ Update-Progress "Pre-req: Running Preprocessor..." 0
$preprocessingFilePath = ".\tools\Invoke-Preprocessing.ps1" $preprocessingFilePath = ".\tools\Invoke-Preprocessing.ps1"
. $preprocessingFilePath . $preprocessingFilePath
$excludedFiles = @('.\.git\', '.\.gitignore', '.\.gitattributes', '.\.github\CODEOWNERS', '.\LICENSE', "$preprocessingFilePath", '*.png', '*.exe','.\.preprocessor_hashes.json') $excludedFiles = @()
# Add directories only if they exist
if (Test-Path '.\.git\') { $excludedFiles += '.\.git\' }
if (Test-Path '.\binary\') { $excludedFiles += '.\binary\' }
# Add files that should always be excluded
$excludedFiles += @(
'.\.gitignore',
'.\.gitattributes',
'.\.github\CODEOWNERS',
'.\LICENSE',
"$preprocessingFilePath",
'*.png',
'*.exe',
'.\.preprocessor_hashes.json'
)
$msg = "Pre-req: Code Formatting" $msg = "Pre-req: Code Formatting"
Invoke-Preprocessing -WorkingDir "$workingdir" -ExcludedFiles $excludedFiles -ProgressStatusMessage $msg Invoke-Preprocessing -WorkingDir "$workingdir" -ExcludedFiles $excludedFiles -ProgressStatusMessage $msg

View File

@ -35,7 +35,7 @@ irm "https://christitus.com/win" | iex
irm "https://christitus.com/windev" | iex irm "https://christitus.com/windev" | iex
``` ```
If you have Issues, refer to [Known Issues](https://winutil.christitus.com/knownissues/) If you have Issues, refer to [Known Issues](https://winutil.christitus.com/knownissues/) or [Create Issue](https://github.com/ChrisTitusTech/winutil/issues)
## 🎓 Documentation ## 🎓 Documentation
@ -79,7 +79,7 @@ You'll see a new file named `winutil.ps1`, which's created by `Compile.ps1` scri
These are the sponsors that help keep this project alive with monthly contributions. These are the sponsors that help keep this project alive with monthly contributions.
<!-- sponsors --><a href="https://github.com/TriHydera"><img src="https:&#x2F;&#x2F;github.com&#x2F;TriHydera.png" width="60px" alt="User avatar: TriHydera" /></a><a href="https://github.com/DelDongo"><img src="https:&#x2F;&#x2F;github.com&#x2F;DelDongo.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/markamos"><img src="https:&#x2F;&#x2F;github.com&#x2F;markamos.png" width="60px" alt="User avatar: Mark Amos" /></a><a href="https://github.com/dwelfusius"><img src="https:&#x2F;&#x2F;github.com&#x2F;dwelfusius.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/mews-se"><img src="https:&#x2F;&#x2F;github.com&#x2F;mews-se.png" width="60px" alt="User avatar: Martin Stockzell" /></a><a href="https://github.com/jdiegmueller"><img src="https:&#x2F;&#x2F;github.com&#x2F;jdiegmueller.png" width="60px" alt="User avatar: Jason A. Diegmueller" /></a><a href="https://github.com/robertsandrock"><img src="https:&#x2F;&#x2F;github.com&#x2F;robertsandrock.png" width="60px" alt="User avatar: RMS" /></a><a href="https://github.com/KenichiQaz"><img src="https:&#x2F;&#x2F;github.com&#x2F;KenichiQaz.png" width="60px" alt="User avatar: Stefan" /></a><a href="https://github.com/paulsheets"><img src="https:&#x2F;&#x2F;github.com&#x2F;paulsheets.png" width="60px" alt="User avatar: Paul" /></a><a href="https://github.com/djones369"><img src="https:&#x2F;&#x2F;github.com&#x2F;djones369.png" width="60px" alt="User avatar: Dave J. - WhamGeek" /></a><a href="https://github.com/anthonymendez"><img src="https:&#x2F;&#x2F;github.com&#x2F;anthonymendez.png" width="60px" alt="User avatar: Anthony Mendez" /></a><a href="https://github.com/FatBastard0"><img src="https:&#x2F;&#x2F;github.com&#x2F;FatBastard0.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/DursleyGuy"><img src="https:&#x2F;&#x2F;github.com&#x2F;DursleyGuy.png" width="60px" alt="User avatar: DursleyGuy" /></a><a href="https://github.com/realmuddy"><img src="https:&#x2F;&#x2F;github.com&#x2F;realmuddy.png" width="60px" alt="User avatar: Phillip Waters" /></a><a href="https://github.com/quaszi"><img src="https:&#x2F;&#x2F;github.com&#x2F;quaszi.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/DwayneTheRockLobster1"><img src="https:&#x2F;&#x2F;github.com&#x2F;DwayneTheRockLobster1.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/KieraKujisawa"><img src="https:&#x2F;&#x2F;github.com&#x2F;KieraKujisawa.png" width="60px" alt="User avatar: Kiera Meredith" /></a><a href="https://github.com/danhively"><img src="https:&#x2F;&#x2F;github.com&#x2F;danhively.png" width="60px" alt="User avatar: Dan Hively" /></a><!-- sponsors --> <!-- sponsors --><a href="https://github.com/markamos"><img src="https:&#x2F;&#x2F;github.com&#x2F;markamos.png" width="60px" alt="User avatar: Mark Amos" /></a><a href="https://github.com/dwelfusius"><img src="https:&#x2F;&#x2F;github.com&#x2F;dwelfusius.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/mews-se"><img src="https:&#x2F;&#x2F;github.com&#x2F;mews-se.png" width="60px" alt="User avatar: Martin Stockzell" /></a><a href="https://github.com/jdiegmueller"><img src="https:&#x2F;&#x2F;github.com&#x2F;jdiegmueller.png" width="60px" alt="User avatar: Jason A. Diegmueller" /></a><a href="https://github.com/robertsandrock"><img src="https:&#x2F;&#x2F;github.com&#x2F;robertsandrock.png" width="60px" alt="User avatar: RMS" /></a><a href="https://github.com/KenichiQaz"><img src="https:&#x2F;&#x2F;github.com&#x2F;KenichiQaz.png" width="60px" alt="User avatar: Stefan" /></a><a href="https://github.com/paulsheets"><img src="https:&#x2F;&#x2F;github.com&#x2F;paulsheets.png" width="60px" alt="User avatar: Paul" /></a><a href="https://github.com/djones369"><img src="https:&#x2F;&#x2F;github.com&#x2F;djones369.png" width="60px" alt="User avatar: Dave J (WhamGeek)" /></a><a href="https://github.com/anthonymendez"><img src="https:&#x2F;&#x2F;github.com&#x2F;anthonymendez.png" width="60px" alt="User avatar: Anthony Mendez" /></a><a href="https://github.com/FatBastard0"><img src="https:&#x2F;&#x2F;github.com&#x2F;FatBastard0.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/DursleyGuy"><img src="https:&#x2F;&#x2F;github.com&#x2F;DursleyGuy.png" width="60px" alt="User avatar: DursleyGuy" /></a><a href="https://github.com/realmuddy"><img src="https:&#x2F;&#x2F;github.com&#x2F;realmuddy.png" width="60px" alt="User avatar: Phillip Waters" /></a><a href="https://github.com/quaszi"><img src="https:&#x2F;&#x2F;github.com&#x2F;quaszi.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/DwayneTheRockLobster1"><img src="https:&#x2F;&#x2F;github.com&#x2F;DwayneTheRockLobster1.png" width="60px" alt="User avatar: " /></a><a href="https://github.com/KieraKujisawa"><img src="https:&#x2F;&#x2F;github.com&#x2F;KieraKujisawa.png" width="60px" alt="User avatar: Kiera Meredith" /></a><a href="https://github.com/IsaacThoman"><img src="https:&#x2F;&#x2F;github.com&#x2F;IsaacThoman.png" width="60px" alt="User avatar: Isaac Thoman" /></a><!-- sponsors -->
## 🏅 Thanks to all Contributors ## 🏅 Thanks to all Contributors
Thanks a lot for spending your time helping Winutil grow. Thanks a lot! Keep rocking 🍻. Thanks a lot for spending your time helping Winutil grow. Thanks a lot! Keep rocking 🍻.

View File

@ -143,6 +143,15 @@
"link": "https://github.com/sharkdp/bat", "link": "https://github.com/sharkdp/bat",
"winget": "sharkdp.bat" "winget": "sharkdp.bat"
}, },
"beeper": {
"category": "Communications",
"choco": "na",
"content": "Beeper",
"description": "All your chats in one app",
"link": "https://www.beeper.com/",
"winget": "Beeper.Beeper"
},
"bitwarden": { "bitwarden": {
"category": "Utilities", "category": "Utilities",
"choco": "bitwarden", "choco": "bitwarden",
@ -511,6 +520,14 @@
"link": "https://emulationstation.org/", "link": "https://emulationstation.org/",
"winget": "Emulationstation.Emulationstation" "winget": "Emulationstation.Emulationstation"
}, },
"enteauth": {
"category": "Utilities",
"choco": "ente-auth",
"content": "Ente Auth",
"description": "Ente Auth is a free, cross-platform, end-to-end encrypted authenticator app.",
"link": "https://ente.io/auth/",
"winget": "ente-io.auth-desktop"
},
"epicgames": { "epicgames": {
"category": "Games", "category": "Games",
"choco": "epicgameslauncher", "choco": "epicgameslauncher",
@ -983,6 +1000,14 @@
"link": "https://aws.amazon.com/corretto", "link": "https://aws.amazon.com/corretto",
"winget": "Amazon.Corretto.21.JDK" "winget": "Amazon.Corretto.21.JDK"
}, },
"java25": {
"category": "Development",
"choco": "corretto25jdk",
"content": "Amazon Corretto 25 (LTS)",
"description": "Amazon Corretto is a no-cost, multiplatform, production-ready distribution of the Open Java Development Kit (OpenJDK).",
"link": "https://aws.amazon.com/corretto",
"winget": "Amazon.Corretto.25.JDK"
},
"jdownloader": { "jdownloader": {
"category": "Utilities", "category": "Utilities",
"choco": "jdownloader", "choco": "jdownloader",
@ -1703,13 +1728,13 @@
"link": "https://bitsum.com/", "link": "https://bitsum.com/",
"winget": "BitSum.ProcessLasso" "winget": "BitSum.ProcessLasso"
}, },
"spotify": { "protonauth": {
"category": "Multimedia Tools", "category": "Utilities",
"choco": "spotify", "choco": "protonauth",
"content": "Spotify", "content": "Proton Authenticator",
"description": "Spotify is a digital music service that gives you access to millions of songs, podcasts, and videos from artists all over the world.", "description": "2FA app from Proton to securely sync and backup 2FA codes.",
"link": "https://www.spotify.com/", "link": "https://proton.me/authenticator",
"winget": "Spotify.Spotify" "winget": "Proton.ProtonAuthenticator"
}, },
"processmonitor": { "processmonitor": {
"category": "Microsoft Tools", "category": "Microsoft Tools",
@ -2699,7 +2724,7 @@
"category": "Utilities", "category": "Utilities",
"choco": "ultravnc", "choco": "ultravnc",
"content": "UltraVNC", "content": "UltraVNC",
"description": "UltraVNC is a powerful, easy to use and free - remote pc access softwares - that can display the screen of another computer (via internet or network) on your own screen. The program allows you to use your mouse and keyboard to control the other PC remotely. It means that you can work on a remote computer, as if you were sitting in front of it, right from your current location.", "description": "UltraVNC is a powerful, easy to use and free - remote pc access software - that can display the screen of another computer (via internet or network) on your own screen. The program allows you to use your mouse and keyboard to control the other PC remotely. It means that you can work on a remote computer, as if you were sitting in front of it, right from your current location.",
"link": "https://uvnc.com/", "link": "https://uvnc.com/",
"winget": "uvncbvba.UltraVnc" "winget": "uvncbvba.UltraVnc"
}, },
@ -2910,5 +2935,13 @@
"description": "The modern, privacy-focused, performance-driven browser built on Firefox", "description": "The modern, privacy-focused, performance-driven browser built on Firefox",
"link": "https://zen-browser.app/", "link": "https://zen-browser.app/",
"winget": "Zen-Team.Zen-Browser" "winget": "Zen-Team.Zen-Browser"
},
"Zed": {
"category": "Development",
"choco": "na",
"content": "Zed",
"description": "Zed is a modern, high-performance code editor designed from the ground up for speed and collaboration.",
"link": "https://zed.dev/",
"winget": "Zed.Zed"
} }
} }

View File

@ -46,23 +46,5 @@
"Secondary": "94.140.15.16", "Secondary": "94.140.15.16",
"Primary6": "2a10:50c0::bad1:ff", "Primary6": "2a10:50c0::bad1:ff",
"Secondary6": "2a10:50c0::bad2:ff" "Secondary6": "2a10:50c0::bad2:ff"
},
"dns0.eu_Open":{
"Primary": "193.110.81.254",
"Secondary": "185.253.5.254",
"Primary6": "2a0f:fc80::ffff",
"Secondary6": "2a0f:fc81::ffff"
},
"dns0.eu_ZERO":{
"Primary": "193.110.81.9",
"Secondary": "185.253.5.9",
"Primary6": "2a0f:fc80::9",
"Secondary6": "2a0f:fc81::9"
},
"dns0.eu_KIDS":{
"Primary": "193.110.81.1",
"Secondary": "185.253.5.1",
"Primary6": "2a0f:fc80::1",
"Secondary6": "2a0f:fc81::1"
} }
} }

View File

@ -81,42 +81,6 @@
], ],
"link": "https://winutil.christitus.com/dev/features/features/nfs" "link": "https://winutil.christitus.com/dev/features/features/nfs"
}, },
"WPFFeatureEnableSearchSuggestions": {
"Content": "Enable Search Box Web Suggestions in Registry(explorer restart)",
"Description": "Enables web suggestions when searching using Windows Search.",
"category": "Features",
"panel": "1",
"Order": "a015_",
"feature": [],
"InvokeScript": [
"
If (!(Test-Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer')) {
New-Item -Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer' -Force | Out-Null
}
New-ItemProperty -Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer' -Name 'DisableSearchBoxSuggestions' -Type DWord -Value 0 -Force
Stop-Process -name explorer -force
"
],
"link": "https://winutil.christitus.com/dev/features/features/enablesearchsuggestions"
},
"WPFFeatureDisableSearchSuggestions": {
"Content": "Disable Search Box Web Suggestions in Registry(explorer restart)",
"Description": "Disables web suggestions when searching using Windows Search.",
"category": "Features",
"panel": "1",
"Order": "a016_",
"feature": [],
"InvokeScript": [
"
If (!(Test-Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer')) {
New-Item -Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer' -Force | Out-Null
}
New-ItemProperty -Path 'HKCU:\\SOFTWARE\\Policies\\Microsoft\\Windows\\Explorer' -Name 'DisableSearchBoxSuggestions' -Type DWord -Value 1 -Force
Stop-Process -name explorer -force
"
],
"link": "https://winutil.christitus.com/dev/features/features/disablesearchsuggestions"
},
"WPFFeatureRegBackup": { "WPFFeatureRegBackup": {
"Content": "Enable Daily Registry Backup Task 12.30am", "Content": "Enable Daily Registry Backup Task 12.30am",
"Description": "Enables daily registry backup, previously disabled by Microsoft in Windows 10 1803.", "Description": "Enables daily registry backup, previously disabled by Microsoft in Windows 10 1803.",
@ -290,6 +254,14 @@
"ButtonWidth": "300", "ButtonWidth": "300",
"link": "https://winutil.christitus.com/dev/features/legacy-windows-panels/region" "link": "https://winutil.christitus.com/dev/features/legacy-windows-panels/region"
}, },
"WPFPanelRestore": {
"Content": "Windows Restore",
"category": "Legacy Windows Panels",
"panel": "2",
"Type": "Button",
"ButtonWidth": "300",
"link": "https://winutil.christitus.com/dev/features/legacy-windows-panels/restore"
},
"WPFPanelSound": { "WPFPanelSound": {
"Content": "Sound Settings", "Content": "Sound Settings",
"category": "Legacy Windows Panels", "category": "Legacy Windows Panels",
@ -298,7 +270,6 @@
"ButtonWidth": "300", "ButtonWidth": "300",
"link": "https://winutil.christitus.com/dev/features/legacy-windows-panels/user" "link": "https://winutil.christitus.com/dev/features/legacy-windows-panels/user"
}, },
"WPFPanelSystem": { "WPFPanelSystem": {
"Content": "System Properties", "Content": "System Properties",
"category": "Legacy Windows Panels", "category": "Legacy Windows Panels",

View File

@ -1,15 +1,12 @@
{ {
"Standard": [ "Standard": [
"WPFTweaksAH", "WPFTweaksActivity",
"WPFTweaksConsumerFeatures", "WPFTweaksConsumerFeatures",
"WPFTweaksDisableExplorerAutoDiscovery", "WPFTweaksDisableExplorerAutoDiscovery",
"WPFTweaksDVR", "WPFTweaksDVR",
"WPFTweaksHome", "WPFTweaksLocation",
"WPFTweaksLoc",
"WPFTweaksServices", "WPFTweaksServices",
"WPFTweaksStorage",
"WPFTweaksTele", "WPFTweaksTele",
"WPFTweaksWifi",
"WPFTweaksDiskCleanup", "WPFTweaksDiskCleanup",
"WPFTweaksDeleteTempFiles", "WPFTweaksDeleteTempFiles",
"WPFTweaksEndTaskOnTaskbar", "WPFTweaksEndTaskOnTaskbar",
@ -19,7 +16,6 @@
"Minimal": [ "Minimal": [
"WPFTweaksConsumerFeatures", "WPFTweaksConsumerFeatures",
"WPFTweaksDisableExplorerAutoDiscovery", "WPFTweaksDisableExplorerAutoDiscovery",
"WPFTweaksHome",
"WPFTweaksServices", "WPFTweaksServices",
"WPFTweaksTele" "WPFTweaksTele"
] ]

View File

@ -3,7 +3,7 @@
"AppEntryWidth": "130", "AppEntryWidth": "130",
"AppEntryFontSize": "11", "AppEntryFontSize": "11",
"AppEntryMargin": "1,1,1,1", "AppEntryMargin": "1,1,1,1",
"AppEntryBorderTickness": "0", "AppEntryBorderThickness": "0",
"CustomDialogFontSize": "12", "CustomDialogFontSize": "12",
"CustomDialogFontSizeHeader": "14", "CustomDialogFontSizeHeader": "14",
"CustomDialogLogoSize": "25", "CustomDialogLogoSize": "25",

File diff suppressed because it is too large Load Diff

View File

@ -132,7 +132,7 @@ function Invoke-MicrowinGetIso {
if (!$downloadFromGitHub) { if (!$downloadFromGitHub) {
# only show the message to people who did check the box to download from github, if you check the box # only show the message to people who did check the box to download from github, if you check the box
# you consent to downloading it, no need to show extra dialogs # you consent to downloading it, no need to show extra dialogs
[System.Windows.MessageBox]::Show("oscdimge.exe is not found on the system, winutil will now attempt do download and install it using choco. This might take a long time.") [System.Windows.MessageBox]::Show("oscdimg.exe is not found on the system, winutil will now attempt do download and install it using choco. This might take a long time.")
# the step below needs choco to download oscdimg # the step below needs choco to download oscdimg
# Install Choco if not already present # Install Choco if not already present
Install-WinUtilChoco Install-WinUtilChoco
@ -149,7 +149,7 @@ function Invoke-MicrowinGetIso {
[System.Windows.MessageBox]::Show($msg) [System.Windows.MessageBox]::Show($msg)
return return
} else { } else {
[System.Windows.MessageBox]::Show("oscdimge.exe is not found on the system, winutil will now attempt do download and install it from github. This might take a long time.") [System.Windows.MessageBox]::Show("oscdimg.exe is not found on the system, winutil will now attempt do download and install it from github. This might take a long time.")
Invoke-MicrowinBusyInfo -action "wip" -message "Downloading oscdimg.exe..." -interactive $false Invoke-MicrowinBusyInfo -action "wip" -message "Downloading oscdimg.exe..." -interactive $false
Microwin-GetOscdimg -oscdimgPath $oscdimgPath Microwin-GetOscdimg -oscdimgPath $oscdimgPath
$oscdImgFound = Test-Path $oscdimgPath -PathType Leaf $oscdImgFound = Test-Path $oscdimgPath -PathType Leaf
@ -200,7 +200,7 @@ function Invoke-MicrowinGetIso {
$msg = "Failed to mount the image. Error: $($_.Exception.Message)" $msg = "Failed to mount the image. Error: $($_.Exception.Message)"
Write-Error $msg Write-Error $msg
Write-Error "This is NOT winutil's problem, your ISO might be corrupt, or there is a problem on the system" Write-Error "This is NOT winutil's problem, your ISO might be corrupt, or there is a problem on the system"
Write-Host "Please refer to this wiki for more details: https://christitustech.github.io/winutil/KnownIssues/#troubleshoot-errors-during-microwin-usage" -ForegroundColor Red Write-Host "Please refer to this wiki for more details: https://winutil.christitus.com/knownissues/" -ForegroundColor Red
Set-WinUtilTaskbaritem -state "Error" -value 1 -overlay "warning" Set-WinUtilTaskbaritem -state "Error" -value 1 -overlay "warning"
Invoke-MicrowinBusyInfo -action "warning" -message $msg Invoke-MicrowinBusyInfo -action "warning" -message $msg
return return

View File

@ -1,6 +1,6 @@
function Microwin-NewCheckInstall { function Microwin-NewCheckInstall {
# using here string to embedd firstrun # using here string to embed firstrun
$checkInstall = @' $checkInstall = @'
@echo off @echo off
if exist "%HOMEDRIVE%\windows\cpu.txt" ( if exist "%HOMEDRIVE%\windows\cpu.txt" (

View File

@ -1,6 +1,6 @@
function Microwin-NewFirstRun { function Microwin-NewFirstRun {
# using here string to embedd firstrun # using here string to embed firstrun
$firstRun = @' $firstRun = @'
# Set the global error action preference to continue # Set the global error action preference to continue
$ErrorActionPreference = "Continue" $ErrorActionPreference = "Continue"

View File

@ -41,7 +41,7 @@
$selectedAppRemoveButton.Add_MouseEnter({ $this.Foreground = "Red" }) $selectedAppRemoveButton.Add_MouseEnter({ $this.Foreground = "Red" })
$selectedAppRemoveButton.Add_MouseLeave({ $this.SetResourceReference([Windows.Controls.Control]::ForegroundProperty, "MainForegroundColor") }) $selectedAppRemoveButton.Add_MouseLeave({ $this.SetResourceReference([Windows.Controls.Control]::ForegroundProperty, "MainForegroundColor") })
$selectedAppRemoveButton.Add_Click({ $selectedAppRemoveButton.Add_Click({
$sync.($this.Tag).isChecked = $false # On click of the remove button, we only have to uncheck the corresponding checkbox. This will kick of all neccessary changes to update the UI $sync.($this.Tag).isChecked = $false # On click of the remove button, we only have to uncheck the corresponding checkbox. This will kick of all necessary changes to update the UI
}) })
[System.Windows.Controls.Grid]::SetColumn($selectedAppRemoveButton, 1) [System.Windows.Controls.Grid]::SetColumn($selectedAppRemoveButton, 1)
$selectedAppGrid.Children.Add($selectedAppRemoveButton) $selectedAppGrid.Children.Add($selectedAppRemoveButton)

View File

@ -13,7 +13,7 @@ function Get-LocalizedYesNo {
#> #>
# Run choice and capture its options as output # Run choice and capture its options as output
# The output shows the options for Yes and No as "[Y,N]?" in the (partitially) localized format. # The output shows the options for Yes and No as "[Y,N]?" in the (partially) localized format.
# eg. English: [Y,N]? # eg. English: [Y,N]?
# Dutch: [Y,N]? # Dutch: [Y,N]?
# German: [J,N]? # German: [J,N]?

View File

@ -8,7 +8,7 @@
Also creates an overlay with a progress bar and text to indicate that an install or uninstall is in progress Also creates an overlay with a progress bar and text to indicate that an install or uninstall is in progress
.PARAMETER TargetElement .PARAMETER TargetElement
The element to which the AppArea shoud be added The element to which the AppArea should be added
#> #>
param($TargetElement) param($TargetElement)

View File

@ -1,7 +1,7 @@
function Initialize-InstallAppEntry { function Initialize-InstallAppEntry {
<# <#
.SYNOPSIS .SYNOPSIS
Creates the app entry to be placed on the isntall tab for a given app Creates the app entry to be placed on the install tab for a given app
Used to as part of the Install Tab UI generation Used to as part of the Install Tab UI generation
.PARAMETER TargetElement .PARAMETER TargetElement
The Element into which the Apps should be placed The Element into which the Apps should be placed

View File

@ -30,24 +30,16 @@ Function Install-WinUtilProgramWinget {
.PARAMETER wingetId .PARAMETER wingetId
The Id of the Program that Winget should Install/Uninstall The Id of the Program that Winget should Install/Uninstall
.PARAMETER scope
Determines the installation mode. Can be "user" or "machine" (For more info look at the winget documentation)
.PARAMETER credential
The PSCredential Object of the user that should be used to run winget
.NOTES .NOTES
Invoke Winget uses the public variable $Action defined outside the function to determine if a Program should be installed or removed Invoke Winget uses the public variable $Action defined outside the function to determine if a Program should be installed or removed
#> #>
param ( param (
[string]$wingetId, [string]$wingetId
[string]$scope = "",
[PScredential]$credential = $null
) )
$commonArguments = "--id $wingetId --silent" $commonArguments = "--id $wingetId --silent"
$arguments = if ($Action -eq "Install") { $arguments = if ($Action -eq "Install") {
"install $commonArguments --accept-source-agreements --accept-package-agreements $(if ($scope) {" --scope $scope"})" "install $commonArguments --accept-source-agreements --accept-package-agreements"
} else { } else {
"uninstall $commonArguments" "uninstall $commonArguments"
} }
@ -60,10 +52,6 @@ Function Install-WinUtilProgramWinget {
NoNewWindow = $true NoNewWindow = $true
} }
if ($credential) {
$processParams.credential = $credential
}
return (Start-Process @processParams).ExitCode return (Start-Process @processParams).ExitCode
} }
@ -87,28 +75,6 @@ Function Install-WinUtilProgramWinget {
return $true return $true
} }
Write-Host "Attempt installation of $($Program) with User scope"
$status = Invoke-Winget -wingetId $Program -scope "user"
if ($status -eq 0) {
Write-Host "$($Program) installed successfully with User scope."
return $true
} elseif ($status -eq -1978335189) {
Write-Host "$($Program) No applicable update found"
return $true
}
$userAcknowledgment = [System.Windows.MessageBox]::Show("You need to input your password to install $($Program) with specific user credentials.", "User credential Prompt", [System.Windows.MessageBoxButton]::Ok)
if ($userAcknowledgment -eq 'Ok') {
$getcreds = Get-Credential $env:USERNAME
$status = Invoke-Winget -wingetId $Program -credential $getcreds
if ($status -eq 0) {
Write-Host "$($Program) installed successfully with User prompt."
return $true
}
} else {
Write-Host "Skipping installation with specific user credentials."
}
Write-Host "Failed to install $($Program)." Write-Host "Failed to install $($Program)."
return $false return $false
} }

View File

@ -21,10 +21,6 @@ function Invoke-WinUtilTweaks {
$KeepServiceStartup = $true $KeepServiceStartup = $true
) )
if ($Checkbox -contains "Toggle") {
$CheckBox = $sync.configs.tweaks.$CheckBox
}
Write-Debug "Tweaks: $($CheckBox)" Write-Debug "Tweaks: $($CheckBox)"
if($undo) { if($undo) {
$Values = @{ $Values = @{
@ -54,7 +50,7 @@ function Invoke-WinUtilTweaks {
$sync.configs.tweaks.$CheckBox.service | ForEach-Object { $sync.configs.tweaks.$CheckBox.service | ForEach-Object {
$changeservice = $true $changeservice = $true
# The check for !($undo) is required, without it the script will throw an error for accessing unavailable memeber, which's the 'OriginalService' Property # The check for !($undo) is required, without it the script will throw an error for accessing unavailable member, which's the 'OriginalService' Property
if($KeepServiceStartup -AND !($undo)) { if($KeepServiceStartup -AND !($undo)) {
try { try {
# Check if the service exists # Check if the service exists

View File

@ -6,35 +6,35 @@ function Set-PackageManagerPreference {
Reads from preference.ini if no argument sent. Reads from preference.ini if no argument sent.
.PARAMETER preferedPackageManager .PARAMETER preferredPackageManager
The PackageManager that was selected. The PackageManager that was selected.
#> #>
param( param(
[Parameter(Position=0, Mandatory=$false)] [Parameter(Position=0, Mandatory=$false)]
[PackageManagers]$preferedPackageManager [PackageManagers]$preferredPackageManager
) )
$preferencePath = "$env:LOCALAPPDATA\winutil\preferences.ini" $preferencePath = "$env:LOCALAPPDATA\winutil\preferences.ini"
$oldChocoPath = "$env:LOCALAPPDATA\winutil\preferChocolatey.ini" $oldChocoPath = "$env:LOCALAPPDATA\winutil\preferChocolatey.ini"
#Try loading from file if no argument given. #Try loading from file if no argument given.
if ($null -eq $preferedPackageManager) { if ($null -eq $preferredPackageManager) {
# Backwards compat for preferChocolatey.ini # Backwards compat for preferChocolatey.ini
if (Test-Path -Path $oldChocoPath) { if (Test-Path -Path $oldChocoPath) {
$preferedPackageManager = [PackageManagers]::Choco $preferredPackageManager = [PackageManagers]::Choco
Remove-Item -Path $oldChocoPath Remove-Item -Path $oldChocoPath
} }
elseif (Test-Path -Path $preferencePath) { elseif (Test-Path -Path $preferencePath) {
$potential = Get-Content -Path $preferencePath -TotalCount 1 $potential = Get-Content -Path $preferencePath -TotalCount 1
$preferedPackageManager = [PackageManagers]$potential $preferredPackageManager = [PackageManagers]$potential
} }
else { else {
Write-Debug "Creating new preference file, defaulting to winget." Write-Debug "Creating new preference file, defaulting to winget."
$preferedPackageManager = [PackageManagers]::Winget $preferredPackageManager = [PackageManagers]::Winget
} }
} }
$sync["ManagerPreference"] = [PackageManagers]::$preferedPackageManager $sync["ManagerPreference"] = [PackageManagers]::$preferredPackageManager
Write-Debug "Manager Preference changed to '$($sync["ManagerPreference"])'" Write-Debug "Manager Preference changed to '$($sync["ManagerPreference"])'"

View File

@ -4,7 +4,7 @@ function Set-WinUtilProgressbar{
This function is used to Update the Progress Bar displayed in the winutil GUI. This function is used to Update the Progress Bar displayed in the winutil GUI.
It will be automatically hidden if the user clicks something and no process is running It will be automatically hidden if the user clicks something and no process is running
.PARAMETER Label .PARAMETER Label
The Text to be overlayed onto the Progress Bar The Text to be overlaid onto the Progress Bar
.PARAMETER PERCENT .PARAMETER PERCENT
The percentage of the Progress Bar that should be filled (0-100) The percentage of the Progress Bar that should be filled (0-100)
#> #>

View File

@ -24,8 +24,12 @@ Function Set-WinUtilService {
# Check if the service exists # Check if the service exists
$service = Get-Service -Name $Name -ErrorAction Stop $service = Get-Service -Name $Name -ErrorAction Stop
# Service exists, proceed with changing properties # Service exists, proceed with changing properties -- while handling auto delayed start for PWSH 5
$service | Set-Service -StartupType $StartupType -ErrorAction Stop if (($PSVersionTable.PSVersion.Major -lt 7) -and ($StartupType -eq "AutomaticDelayedStart")) {
sc.exe config $Name start=delayed-auto
} else {
$service | Set-Service -StartupType $StartupType -ErrorAction Stop
}
} catch [System.ServiceProcess.ServiceNotFoundException] { } catch [System.ServiceProcess.ServiceNotFoundException] {
Write-Warning "Service $Name was not found" Write-Warning "Service $Name was not found"
} catch { } catch {

View File

@ -0,0 +1,26 @@
function Test-WinUtilInternetConnection {
<#
.SYNOPSIS
Tests if the computer has internet connectivity
.OUTPUTS
Boolean - True if connected, False if offline
#>
try {
# Test multiple reliable endpoints
$testSites = @(
"8.8.8.8", # Google DNS
"1.1.1.1", # Cloudflare DNS
"208.67.222.222" # OpenDNS
)
foreach ($site in $testSites) {
if (Test-Connection -ComputerName $site -Count 1 -Quiet -ErrorAction SilentlyContinue) {
return $true
}
}
return $false
}
catch {
return $false
}
}

View File

@ -33,7 +33,7 @@ function Test-WinUtilPackageManager {
$wingetVersionFull = ($wingetInfo | Select-String -Pattern 'Package Manager v\d+\.\d+\.\d+').Matches.Value.Split(' ')[-1] $wingetVersionFull = ($wingetInfo | Select-String -Pattern 'Package Manager v\d+\.\d+\.\d+').Matches.Value.Split(' ')[-1]
} }
} catch [System.Management.Automation.CommandNotFoundException], [System.Management.Automation.ApplicationFailedException] { } catch [System.Management.Automation.CommandNotFoundException], [System.Management.Automation.ApplicationFailedException] {
Write-Warning "Winget was not found due to un-availablity reasons" Write-Warning "Winget was not found due to un-availability reasons"
$wingetExists = $false $wingetExists = $false
} catch { } catch {
Write-Warning "Winget was not found due to un-known reasons, The Stack Trace is:`n$($psitem.Exception.StackTrace)" Write-Warning "Winget was not found due to un-known reasons, The Stack Trace is:`n$($psitem.Exception.StackTrace)"
@ -41,7 +41,7 @@ function Test-WinUtilPackageManager {
} }
# If Winget is available, Parse it's Version and give proper information to Terminal Output. # If Winget is available, Parse it's Version and give proper information to Terminal Output.
# If it isn't available, the return of this funtion will be "not-installed", indicating that # If it isn't available, the return of this function will be "not-installed", indicating that
# Winget isn't installed/available on The System. # Winget isn't installed/available on The System.
if ($wingetExists) { if ($wingetExists) {
# Check if Preview Version # Check if Preview Version
@ -55,7 +55,7 @@ function Test-WinUtilPackageManager {
# Check if Winget's Version is too old. # Check if Winget's Version is too old.
$wingetCurrentVersion = [System.Version]::Parse($wingetVersion.Trim('v')) $wingetCurrentVersion = [System.Version]::Parse($wingetVersion.Trim('v'))
# Grabs the latest release of Winget from the Github API for version check process. # Grabs the latest release of Winget from the GitHub API for version check process.
$response = winget search -e Microsoft.AppInstaller --accept-source-agreements $response = winget search -e Microsoft.AppInstaller --accept-source-agreements
$wingetLatestVersion = ($response | Select-String -Pattern '\d+\.\d+\.\d+\.\d+').Matches.Value $wingetLatestVersion = ($response | Select-String -Pattern '\d+\.\d+\.\d+\.\d+').Matches.Value
Write-Host "Latest Search Version: $wingetLatestVersion" -ForegroundColor White Write-Host "Latest Search Version: $wingetLatestVersion" -ForegroundColor White

View File

@ -4,7 +4,7 @@ function Invoke-ScratchDialog {
<# <#
.SYNOPSIS .SYNOPSIS
Enable Editable Text box Alternate Scartch path Enable Editable Text box Alternate Scratch path
.PARAMETER Button .PARAMETER Button
#> #>

View File

@ -41,6 +41,7 @@ function Invoke-WPFButton {
"WPFPanelPower" {Invoke-WPFControlPanel -Panel $button} "WPFPanelPower" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelPrinter" {Invoke-WPFControlPanel -Panel $button} "WPFPanelPrinter" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelRegion" {Invoke-WPFControlPanel -Panel $button} "WPFPanelRegion" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelRestore" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelSound" {Invoke-WPFControlPanel -Panel $button} "WPFPanelSound" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelSystem" {Invoke-WPFControlPanel -Panel $button} "WPFPanelSystem" {Invoke-WPFControlPanel -Panel $button}
"WPFPanelTimedate" {Invoke-WPFControlPanel -Panel $button} "WPFPanelTimedate" {Invoke-WPFControlPanel -Panel $button}

View File

@ -17,6 +17,7 @@ function Invoke-WPFControlPanel {
"WPFPanelPower" {powercfg.cpl} "WPFPanelPower" {powercfg.cpl}
"WPFPanelPrinter" {Start-Process "shell:::{A8A91A66-3A7D-4424-8D24-04E180695C7A}"} "WPFPanelPrinter" {Start-Process "shell:::{A8A91A66-3A7D-4424-8D24-04E180695C7A}"}
"WPFPanelRegion" {intl.cpl} "WPFPanelRegion" {intl.cpl}
"WPFPanelRestore" {rstrui.exe}
"WPFPanelSound" {mmsys.cpl} "WPFPanelSound" {mmsys.cpl}
"WPFPanelSystem" {sysdm.cpl} "WPFPanelSystem" {sysdm.cpl}
"WPFPanelTimedate" {timedate.cpl} "WPFPanelTimedate" {timedate.cpl}

View File

@ -33,62 +33,6 @@ function Invoke-WPFInstall {
try { try {
$sync.ProcessRunning = $true $sync.ProcessRunning = $true
if($packagesWinget.Count -gt 0 -and $packagesWinget -ne "0") { if($packagesWinget.Count -gt 0 -and $packagesWinget -ne "0") {
Add-Type -AssemblyName System.DirectoryServices.AccountManagement
Add-Type -assembly System.Windows.Forms
$PrincipalContext = New-Object System.DirectoryServices.AccountManagement.PrincipalContext('Machine')
$user = $env:USERNAME
Get-LocalUser | Where-Object Enabled -eq $true | ForEach-Object {
$validPassword = $false
while (-not $validPassword) {
try {
$myPasswordIsBlank = $PrincipalContext.ValidateCredentials($user, $null)
$validPassword = $true
} catch {
$form = New-Object System.Windows.Forms.Form
$form.Text = "Set password for $user"
$form.Size = New-Object System.Drawing.Size(500, 200)
$label = New-Object System.Windows.Forms.Label
$label.Text = 'Admin mode install failed. Set a USER password for login and user-based installation.'
$label.Size = New-Object System.Drawing.Size(480, 60)
$label.Location = New-Object System.Drawing.Point(10, 10)
$form.Controls.Add($label)
$passwordBox = New-Object System.Windows.Forms.TextBox
$passwordBox.Size = New-Object System.Drawing.Size(380, 20)
$passwordBox.UseSystemPasswordChar = $true
$passwordBox.Location = New-Object System.Drawing.Point(10, 125)
$form.Controls.Add($passwordBox)
$button = New-Object System.Windows.Forms.Button
$button.Text = 'Submit'
$button.Size = New-Object System.Drawing.Size(75, 23)
$button.Location = New-Object System.Drawing.Point(400, 125)
$button.Add_Click({
$password = $passwordBox.Text | ConvertTo-SecureString -AsPlainText -Force
if ($password) {
try {
Set-LocalUser -Name $user -Password $password
$validPassword = $PrincipalContext.ValidateCredentials($user, $passwordBox.Text)
if ($validPassword) {
$form.Close()
} else {
[System.Windows.Forms.MessageBox]::Show('Invalid password! Please try again.')
}
} catch {
[System.Windows.Forms.MessageBox]::Show('Error setting password!')
}
} else {
[System.Windows.Forms.MessageBox]::Show('No password entered!')
}
})
$form.Controls.Add($button)
$form.ShowDialog() | Out-Null
}
}
}
Show-WPFInstallAppBusy -text "Installing apps..." Show-WPFInstallAppBusy -text "Installing apps..."
Install-WinUtilWinget Install-WinUtilWinget
Install-WinUtilProgramWinget -Action Install -Programs $packagesWinget Install-WinUtilProgramWinget -Action Install -Programs $packagesWinget

View File

@ -12,7 +12,7 @@ function Invoke-WPFInstallUpgrade {
Write-Host "Upgrade Successful" Write-Host "Upgrade Successful"
} }
else{ else{
Write-Host "Error Occured. Return Code: $chocoUpgradeStatus" Write-Host "Error Occurred. Return Code: $chocoUpgradeStatus"
} }
} }
else{ else{

View File

@ -156,6 +156,7 @@ function Invoke-WPFUIElements {
$checkBox.Name = $entryInfo.Name $checkBox.Name = $entryInfo.Name
$checkBox.HorizontalAlignment = "Right" $checkBox.HorizontalAlignment = "Right"
$checkBox.UseLayoutRounding = $true $checkBox.UseLayoutRounding = $true
[System.Windows.Automation.AutomationProperties]::SetName($checkBox, $entryInfo.Content)
$dockPanel.Children.Add($checkBox) | Out-Null $dockPanel.Children.Add($checkBox) | Out-Null
$checkBox.Style = $ColorfulToggleSwitchStyle $checkBox.Style = $ColorfulToggleSwitchStyle
@ -191,6 +192,7 @@ function Invoke-WPFUIElements {
$toggleButton.ToolTip = $entryInfo.Description $toggleButton.ToolTip = $entryInfo.Description
$toggleButton.HorizontalAlignment = "Left" $toggleButton.HorizontalAlignment = "Left"
$toggleButton.Style = $ToggleButtonStyle $toggleButton.Style = $ToggleButtonStyle
[System.Windows.Automation.AutomationProperties]::SetName($toggleButton, $entryInfo.Content[0])
$toggleButton.Tag = @{ $toggleButton.Tag = @{
contentOn = if ($entryInfo.Content.Count -ge 1) { $entryInfo.Content[0] } else { "" } contentOn = if ($entryInfo.Content.Count -ge 1) { $entryInfo.Content[0] } else { "" }
@ -232,6 +234,7 @@ function Invoke-WPFUIElements {
$comboBox.SetResourceReference([Windows.Controls.Control]::MarginProperty, "ButtonMargin") $comboBox.SetResourceReference([Windows.Controls.Control]::MarginProperty, "ButtonMargin")
$comboBox.SetResourceReference([Windows.Controls.Control]::FontSizeProperty, "ButtonFontSize") $comboBox.SetResourceReference([Windows.Controls.Control]::FontSizeProperty, "ButtonFontSize")
$comboBox.UseLayoutRounding = $true $comboBox.UseLayoutRounding = $true
[System.Windows.Automation.AutomationProperties]::SetName($comboBox, $entryInfo.Content)
foreach ($comboitem in ($entryInfo.ComboItems -split " ")) { foreach ($comboitem in ($entryInfo.ComboItems -split " ")) {
$comboBoxItem = New-Object Windows.Controls.ComboBoxItem $comboBoxItem = New-Object Windows.Controls.ComboBoxItem
@ -273,6 +276,7 @@ function Invoke-WPFUIElements {
$baseWidth = [int]$entryInfo.ButtonWidth $baseWidth = [int]$entryInfo.ButtonWidth
$button.Width = [math]::Max($baseWidth, 350) $button.Width = [math]::Max($baseWidth, 350)
} }
[System.Windows.Automation.AutomationProperties]::SetName($button, $entryInfo.Content)
$itemsControl.Items.Add($button) | Out-Null $itemsControl.Items.Add($button) | Out-Null
$sync[$entryInfo.Name] = $button $sync[$entryInfo.Name] = $button
@ -303,6 +307,7 @@ function Invoke-WPFUIElements {
$radioButton.SetResourceReference([Windows.Controls.Control]::FontSizeProperty, "ButtonFontSize") $radioButton.SetResourceReference([Windows.Controls.Control]::FontSizeProperty, "ButtonFontSize")
$radioButton.ToolTip = $entryInfo.Description $radioButton.ToolTip = $entryInfo.Description
$radioButton.UseLayoutRounding = $true $radioButton.UseLayoutRounding = $true
[System.Windows.Automation.AutomationProperties]::SetName($radioButton, $entryInfo.Content)
if ($entryInfo.Checked -eq $true) { if ($entryInfo.Checked -eq $true) {
$radioButton.IsChecked = $true $radioButton.IsChecked = $true
@ -324,6 +329,7 @@ function Invoke-WPFUIElements {
$checkBox.ToolTip = $entryInfo.Description $checkBox.ToolTip = $entryInfo.Description
$checkBox.SetResourceReference([Windows.Controls.Control]::MarginProperty, "CheckBoxMargin") $checkBox.SetResourceReference([Windows.Controls.Control]::MarginProperty, "CheckBoxMargin")
$checkBox.UseLayoutRounding = $true $checkBox.UseLayoutRounding = $true
[System.Windows.Automation.AutomationProperties]::SetName($checkBox, $entryInfo.Content)
if ($entryInfo.Checked -eq $true) { if ($entryInfo.Checked -eq $true) {
$checkBox.IsChecked = $entryInfo.Checked $checkBox.IsChecked = $entryInfo.Checked
} }

View File

@ -24,7 +24,7 @@ function Invoke-WPFtweaksbutton {
Write-Debug "Number of tweaks to process: $($Tweaks.Count)" Write-Debug "Number of tweaks to process: $($Tweaks.Count)"
# The leading "," in the ParameterList is nessecary because we only provide one argument and powershell cannot be convinced that we want a nested loop with only one argument otherwise # The leading "," in the ParameterList is necessary because we only provide one argument and powershell cannot be convinced that we want a nested loop with only one argument otherwise
Invoke-WPFRunspace -ParameterList @(,("tweaks",$tweaks)) -DebugPreference $DebugPreference -ScriptBlock { Invoke-WPFRunspace -ParameterList @(,("tweaks",$tweaks)) -DebugPreference $DebugPreference -ScriptBlock {
param( param(
$tweaks, $tweaks,

View File

@ -310,7 +310,36 @@ $sync["Form"].Add_ContentRendered({
Write-Debug "Unable to retrieve information about the primary monitor." Write-Debug "Unable to retrieve information about the primary monitor."
} }
Invoke-WPFTab "WPFTab1BT" # Check internet connectivity and disable install tab if offline
#$isOnline = Test-WinUtilInternetConnection
$isOnline = $true # Temporarily force online mode until we can resolve false negatives
if (-not $isOnline) {
# Disable the install tab
$sync.WPFTab1BT.IsEnabled = $false
$sync.WPFTab1BT.Opacity = 0.5
$sync.WPFTab1BT.ToolTip = "Internet connection required for installing applications"
# Disable install-related buttons
$sync.WPFInstall.IsEnabled = $false
$sync.WPFUninstall.IsEnabled = $false
$sync.WPFInstallUpgrade.IsEnabled = $false
$sync.WPFGetInstalled.IsEnabled = $false
# Show offline indicator
Write-Host "Offline mode detected - Install tab disabled" -ForegroundColor Yellow
# Optionally switch to a different tab if install tab was going to be default
Invoke-WPFTab "WPFTab2BT" # Switch to Tweaks tab instead
}
else {
# Online - ensure install tab is enabled
$sync.WPFTab1BT.IsEnabled = $true
$sync.WPFTab1BT.Opacity = 1.0
$sync.WPFTab1BT.ToolTip = $null
Invoke-WPFTab "WPFTab1BT" # Default to install tab
}
$sync["Form"].Focus() $sync["Form"].Focus()
# maybe this is not the best place to load and execute config file? # maybe this is not the best place to load and execute config file?
@ -422,13 +451,11 @@ $NavLogoPanel.Children.Add((Invoke-WinUtilAssets -Type "logo" -Size 25)) | Out-N
$winutildir = @{} $winutildir = @{}
# Set the path for the winutil directory # Set the path for the winutil directory
$winutildir["path"] = "$env:LOCALAPPDATA\winutil\" $winutildir = "$env:LocalAppData\winutil\"
[System.IO.Directory]::CreateDirectory($winutildir["path"]) | Out-Null New-Item $winutildir -ItemType Directory -Force | Out-Null
$winutildir["logo.ico"] = $winutildir["path"] + "cttlogo.ico" if (Test-Path "$winutildir\logo.ico") {
$sync["logorender"] = "$winutildir\logo.ico"
if (Test-Path $winutildir["logo.ico"]) {
$sync["logorender"] = $winutildir["logo.ico"]
} else { } else {
$sync["logorender"] = (Invoke-WinUtilAssets -Type "Logo" -Size 90 -Render) $sync["logorender"] = (Invoke-WinUtilAssets -Type "Logo" -Size 90 -Render)
} }

View File

@ -80,7 +80,7 @@ if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]:
$dateTime = Get-Date -Format "yyyy-MM-dd_HH-mm-ss" $dateTime = Get-Date -Format "yyyy-MM-dd_HH-mm-ss"
$logdir = "$env:localappdata\winutil\logs" $logdir = "$env:localappdata\winutil\logs"
[System.IO.Directory]::CreateDirectory("$logdir") | Out-Null New-Item $logdir -ItemType Directory -Force | Out-Null
Start-Transcript -Path "$logdir\winutil_$dateTime.log" -Append -NoClobber | Out-Null Start-Transcript -Path "$logdir\winutil_$dateTime.log" -Append -NoClobber | Out-Null
# Set PowerShell window title # Set PowerShell window title

View File

@ -23,7 +23,7 @@ function Invoke-Preprocessing {
.EXAMPLE .EXAMPLE
Invoke-Preprocessing -WorkingDir "DRIVE:\Path\To\Folder\" -ExcludedFiles @('file.txt', '.\.git\', '*.png') -ProgressStatusMessage "Doing Preprocessing" Invoke-Preprocessing -WorkingDir "DRIVE:\Path\To\Folder\" -ExcludedFiles @('file.txt', '.\.git\', '*.png') -ProgressStatusMessage "Doing Preprocessing"
Calls 'Invoke-Preprocessing' function using Named Paramters, with 'WorkingDir' (Mandatory Parameter) which's used as the base folder when searching for files recursively (using 'Get-ChildItem'), other two paramters are, in order from right to left, the Optional 'ExcludeFiles', which can be a path to a file, folder, or pattern-matched (like '*.png'), and the 'ProgressStatusMessage', which's used in Progress Bar. Calls 'Invoke-Preprocessing' function using Named Parameters, with 'WorkingDir' (Mandatory Parameter) which's used as the base folder when searching for files recursively (using 'Get-ChildItem'), other two parameters are, in order from right to left, the Optional 'ExcludeFiles', which can be a path to a file, folder, or pattern-matched (like '*.png'), and the 'ProgressStatusMessage', which's used in Progress Bar.
.EXAMPLE .EXAMPLE
Invoke-Preprocessing -WorkingDir "DRIVE:\Path\To\Folder\" -ExcludedFiles @('file.txt', '.\.git\', '*.png') -ProgressStatusMessage "Doing Preprocessing" -ProgressActivity "Re-Formatting Code" Invoke-Preprocessing -WorkingDir "DRIVE:\Path\To\Folder\" -ExcludedFiles @('file.txt', '.\.git\', '*.png') -ProgressStatusMessage "Doing Preprocessing" -ProgressActivity "Re-Formatting Code"
@ -51,7 +51,7 @@ function Invoke-Preprocessing {
) )
if (-NOT (Test-Path -PathType Container -Path "$WorkingDir")) { if (-NOT (Test-Path -PathType Container -Path "$WorkingDir")) {
throw "[Invoke-Preprocessing] Invalid Paramter Value for 'WorkingDir', passed value: '$WorkingDir'. Either the path is a File or Non-Existing/Invlid, please double check your code." throw "[Invoke-Preprocessing] Invalid Parameter Value for 'WorkingDir', passed value: '$WorkingDir'. Either the path is a File or Non-Existing/Invlid, please double check your code."
} }
$InternalExcludedFiles = [System.Collections.Generic.List[string]]::new($ExcludedFiles.Count) $InternalExcludedFiles = [System.Collections.Generic.List[string]]::new($ExcludedFiles.Count)
@ -63,6 +63,10 @@ function Invoke-Preprocessing {
if ($ExcludedFiles.Count -gt 0) { if ($ExcludedFiles.Count -gt 0) {
ForEach ($excludedFile in $ExcludedFiles) { ForEach ($excludedFile in $ExcludedFiles) {
$filePath = "$(($WorkingDir -replace ('\\$', '')) + '\' + ($excludedFile -replace ('\.\\', '')))" $filePath = "$(($WorkingDir -replace ('\\$', '')) + '\' + ($excludedFile -replace ('\.\\', '')))"
# Only attempt to create the directory if the excludedFile ends with '\'
if ($excludedFile -match '\\$' -and -not (Test-Path "$filePath")) {
New-Item -Path "$filePath" -ItemType Directory -Force | Out-Null
}
$files = Get-ChildItem -Recurse -Path "$filePath" -File -Force $files = Get-ChildItem -Recurse -Path "$filePath" -File -Force
if ($files.Count -gt 0) { if ($files.Count -gt 0) {
ForEach ($file in $files) { ForEach ($file in $files) {

View File

@ -1350,7 +1350,7 @@
HorizontalAlignment="Stretch"> HorizontalAlignment="Stretch">
<StackPanel Name="MicrowinMain" Background="{DynamicResource MainBackgroundColor}" SnapsToDevicePixels="True" Grid.Column="0" Grid.Row="0"> <StackPanel Name="MicrowinMain" Background="{DynamicResource MainBackgroundColor}" SnapsToDevicePixels="True" Grid.Column="0" Grid.Row="0">
<StackPanel Name="MicrowinISOPanel" Background="Transparent" SnapsToDevicePixels="True" Margin="1"> <StackPanel Name="MicrowinISOPanel" Background="Transparent" SnapsToDevicePixels="True" Margin="1">
<CheckBox x:Name="WPFMicrowinDownloadFromGitHub" Content="Download oscdimg.exe from CTT Github repo" IsChecked="True" Margin="{DynamicResource MicrowinCheckBoxMargin}" /> <CheckBox x:Name="WPFMicrowinDownloadFromGitHub" Content="Download oscdimg.exe from CTT GitHub repo" IsChecked="True" Margin="{DynamicResource MicrowinCheckBoxMargin}" />
<TextBlock Margin="5" Padding="1" TextWrapping="Wrap" Foreground="{DynamicResource ComboBoxForegroundColor}"> <TextBlock Margin="5" Padding="1" TextWrapping="Wrap" Foreground="{DynamicResource ComboBoxForegroundColor}">
Choose a Windows ISO file that you've downloaded <LineBreak/> Choose a Windows ISO file that you've downloaded <LineBreak/>
Check the status in the console Check the status in the console