mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-07-01 02:22:34 -05:00
Compare commits
24 Commits
31ec62f00b
...
24.08.30
Author | SHA1 | Date | |
---|---|---|---|
7e1c593510 | |||
b6141808af | |||
a21845327b | |||
2a355c00c8 | |||
2d3dbe4f6a | |||
d315963693 | |||
6c82adbdc9 | |||
c1dd88d84a | |||
b67ec35cbb | |||
c45f36d58f | |||
1fc79bccf2 | |||
2b7d0b6c4b | |||
42061faa81 | |||
889ec8f57d | |||
be6b5b3aa0 | |||
90ddfb02a4 | |||
ece57f8ee2 | |||
6a99be9e05 | |||
488cd8dd98 | |||
7eed393902 | |||
97876348d9 | |||
f8db21bbee | |||
3697be1be4 | |||
51068d9670 |
8
.github/ISSUE_TEMPLATE/bug_report.md
vendored
8
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@ -7,7 +7,7 @@ assignees: ''
|
|||||||
---
|
---
|
||||||
|
|
||||||
## Describe the bug
|
## Describe the bug
|
||||||
A clear and concise description of what the bug is.
|
<!-- A clear and concise description of what the bug is. -->
|
||||||
|
|
||||||
## To Reproduce
|
## To Reproduce
|
||||||
Steps to reproduce the behavior:
|
Steps to reproduce the behavior:
|
||||||
@ -17,10 +17,10 @@ Steps to reproduce the behavior:
|
|||||||
4. See error
|
4. See error
|
||||||
|
|
||||||
## Expected behavior
|
## Expected behavior
|
||||||
A clear and concise description of what you expected to happen.
|
<!-- A clear and concise description of what you expected to happen. -->
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
If applicable, add screenshots to help explain your problem.
|
<!-- If applicable, add screenshots to help explain your problem. -->
|
||||||
|
|
||||||
## Additional context
|
## Additional context
|
||||||
Add any other context about the problem here.
|
<!-- Add any other context about the problem here. -->
|
||||||
|
8
.github/ISSUE_TEMPLATE/feature_request.md
vendored
8
.github/ISSUE_TEMPLATE/feature_request.md
vendored
@ -8,13 +8,13 @@ assignees: ''
|
|||||||
---
|
---
|
||||||
|
|
||||||
**Is your feature request related to a problem? Please describe.**
|
**Is your feature request related to a problem? Please describe.**
|
||||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] -->
|
||||||
|
|
||||||
**Describe the solution you'd like**
|
**Describe the solution you'd like**
|
||||||
A clear and concise description of what you want to happen.
|
<!-- A clear and concise description of what you want to happen. -->
|
||||||
|
|
||||||
**Describe alternatives you've considered**
|
**Describe alternatives you've considered**
|
||||||
A clear and concise description of any alternative solutions or features you've considered.
|
<!-- A clear and concise description of any alternative solutions or features you've considered. -->
|
||||||
|
|
||||||
**Additional context**
|
**Additional context**
|
||||||
Add any other context or screenshots about the feature request here.
|
<!-- Add any other context or screenshots about the feature request here. -->
|
||||||
|
14
.github/PULL_REQUEST_TEMPLATE.md
vendored
14
.github/PULL_REQUEST_TEMPLATE.md
vendored
@ -1,7 +1,9 @@
|
|||||||
# Pull Request
|
# Pull Request
|
||||||
|
|
||||||
|
<!--Before you make this PR have you followed the docs here? - https://christitustech.github.io/winutil/contribute/ -->
|
||||||
|
|
||||||
## Title
|
## Title
|
||||||
[Provide a succinct and descriptive title for the pull request.]
|
<!--[Provide a succinct and descriptive title for the pull request.]-->
|
||||||
|
|
||||||
## Type of Change
|
## Type of Change
|
||||||
- [ ] New feature
|
- [ ] New feature
|
||||||
@ -13,20 +15,20 @@
|
|||||||
- [ ] UI/UX improvement
|
- [ ] UI/UX improvement
|
||||||
|
|
||||||
## Description
|
## Description
|
||||||
[Provide a detailed explanation of the changes you have made. Include the reasons behind these changes and any relevant context. Link any related issues.]
|
<!--[Provide a detailed explanation of the changes you have made. Include the reasons behind these changes and any relevant context. Link any related issues.]-->
|
||||||
|
|
||||||
## Testing
|
## Testing
|
||||||
[Detail the testing you have performed to ensure that these changes function as intended. Include information about any added tests.]
|
<!--[Detail the testing you have performed to ensure that these changes function as intended. Include information about any added tests.]-->
|
||||||
|
|
||||||
## Impact
|
## Impact
|
||||||
[Discuss the impact of your changes on the project. This might include effects on performance, new dependencies, or changes in behaviour.]
|
<!--[Discuss the impact of your changes on the project. This might include effects on performance, new dependencies, or changes in behaviour.]-->
|
||||||
|
|
||||||
## Issue related to PR
|
## Issue related to PR
|
||||||
[What issue/discussion is related to this PR (if any)]
|
<!--[What issue/discussion is related to this PR (if any)]-->
|
||||||
- Resolves #
|
- Resolves #
|
||||||
|
|
||||||
## Additional Information
|
## Additional Information
|
||||||
[Any additional information that reviewers should be aware of.]
|
<!--[Any additional information that reviewers should be aware of.]-->
|
||||||
|
|
||||||
## Checklist
|
## Checklist
|
||||||
- [ ] My code adheres to the coding and style guidelines of the project.
|
- [ ] My code adheres to the coding and style guidelines of the project.
|
||||||
|
24
.github/release-drafter.yml
vendored
Normal file
24
.github/release-drafter.yml
vendored
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
name-template: '$RESOLVED_VERSION'
|
||||||
|
tag-template: '$RESOLVED_VERSION'
|
||||||
|
tag-prefix: ""
|
||||||
|
categories:
|
||||||
|
- title: '🚀 Features'
|
||||||
|
labels:
|
||||||
|
- 'feature'
|
||||||
|
- 'enhancement'
|
||||||
|
- title: '🐛 Bug Fixes'
|
||||||
|
labels:
|
||||||
|
- 'fix'
|
||||||
|
- 'bugfix'
|
||||||
|
- 'bug'
|
||||||
|
- title: '🧰 Maintenance'
|
||||||
|
label: 'chore'
|
||||||
|
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
|
||||||
|
template: |
|
||||||
|
## Changes
|
||||||
|
|
||||||
|
$CHANGES
|
||||||
|
|
||||||
|
## Contributors
|
||||||
|
|
||||||
|
$CONTRIBUTORS
|
4
.github/workflows/close-old-issues.yaml
vendored
4
.github/workflows/close-old-issues.yaml
vendored
@ -22,8 +22,8 @@ jobs:
|
|||||||
exempt-issue-labels: "Keep Issue Open"
|
exempt-issue-labels: "Keep Issue Open"
|
||||||
# Split it into two weeks, after one week the issue will be marked as stale,
|
# Split it into two weeks, after one week the issue will be marked as stale,
|
||||||
# after another week have pasted without any update.. the issue will then be closed.
|
# after another week have pasted without any update.. the issue will then be closed.
|
||||||
days-before-issue-stale: 7
|
days-before-issue-stale: 90
|
||||||
days-before-issue-close: 7
|
days-before-issue-close: 365
|
||||||
# NEVER mark PRs as Stale or Close + this workflow should never have write permissions on PRs, EVER!
|
# NEVER mark PRs as Stale or Close + this workflow should never have write permissions on PRs, EVER!
|
||||||
days-before-pr-stale: -1
|
days-before-pr-stale: -1
|
||||||
days-before-pr-close: -1
|
days-before-pr-close: -1
|
||||||
|
1
.github/workflows/github-pages.yaml
vendored
1
.github/workflows/github-pages.yaml
vendored
@ -7,6 +7,7 @@ on:
|
|||||||
- '.github/requirements.txt'
|
- '.github/requirements.txt'
|
||||||
- 'docs/**'
|
- 'docs/**'
|
||||||
- 'overrides/**'
|
- 'overrides/**'
|
||||||
|
- '.github/CONTRIBUTING.md'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
44
.github/workflows/pre-release.yaml
vendored
44
.github/workflows/pre-release.yaml
vendored
@ -74,16 +74,52 @@ jobs:
|
|||||||
name: winutil
|
name: winutil
|
||||||
path: ./winutil.ps1
|
path: ./winutil.ps1
|
||||||
|
|
||||||
|
- name: Get latest release tag
|
||||||
|
id: get_latest_release
|
||||||
|
run: |
|
||||||
|
git fetch --tags --force
|
||||||
|
$latestTag = git for-each-ref --sort=-creatordate --format '%(refname:short)' refs/tags --count 1
|
||||||
|
if ($LASTEXITCODE -ne 0 -or [string]::IsNullOrEmpty($latestTag)) {
|
||||||
|
Write-Error "Failed to get latest tag. Error code: $LASTEXITCODE"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
Write-Host "Latest tag: $latestTag"
|
||||||
|
echo "LATEST_TAG=$latestTag" >> $env:GITHUB_ENV
|
||||||
|
shell: pwsh
|
||||||
|
|
||||||
|
- name: Generate Release Notes
|
||||||
|
id: generate_notes
|
||||||
|
uses: release-drafter/release-drafter@v5
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
config-name: release-drafter.yml
|
||||||
|
version: ${{ env.version }}
|
||||||
|
tag: ${{ env.LATEST_TAG }}
|
||||||
|
|
||||||
|
- name: Prepare Release Body
|
||||||
|
id: prepare_body
|
||||||
|
run: |
|
||||||
|
$newChanges = @'
|
||||||
|
${{ steps.generate_notes.outputs.body }}
|
||||||
|
'@
|
||||||
|
$formattedChanges = "Changes since ${{ env.LATEST_TAG }}:`n`n$newChanges"
|
||||||
|
$encodedChanges = [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($formattedChanges))
|
||||||
|
echo "body=$encodedChanges" >> $env:GITHUB_OUTPUT
|
||||||
|
shell: pwsh
|
||||||
|
|
||||||
- name: Create and Upload Release
|
- name: Create and Upload Release
|
||||||
id: create_release
|
id: create_release
|
||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ env.VERSION }}
|
tag_name: ${{ env.version }}
|
||||||
name: Pre-Release ${{ env.VERSION }}
|
name: Pre-Release ${{ env.version }}
|
||||||
body: ""
|
body: |
|
||||||
|
${{ '{{' }} fromJson(format('"{0}"', steps.prepare_body.outputs.body)) | base64decode {{ '}}' }}
|
||||||
|
|
||||||
|

|
||||||
append_body: false
|
append_body: false
|
||||||
files: ./winutil.ps1
|
files: ./winutil.ps1
|
||||||
prerelease: true
|
prerelease: true
|
||||||
generate_release_notes: true
|
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
@ -87,14 +87,6 @@
|
|||||||
"link": "https://anydesk.com/",
|
"link": "https://anydesk.com/",
|
||||||
"winget": "AnyDeskSoftwareGmbH.AnyDesk"
|
"winget": "AnyDeskSoftwareGmbH.AnyDesk"
|
||||||
},
|
},
|
||||||
"ATLauncher": {
|
|
||||||
"category": "Games",
|
|
||||||
"choco": "na",
|
|
||||||
"content": "ATLauncher",
|
|
||||||
"description": "ATLauncher is a Launcher for Minecraft which integrates multiple different ModPacks to allow you to download and install ModPacks easily and quickly.",
|
|
||||||
"link": "https://github.com/ATLauncher/ATLauncher",
|
|
||||||
"winget": "ATLauncher.ATLauncher"
|
|
||||||
},
|
|
||||||
"audacity": {
|
"audacity": {
|
||||||
"category": "Multimedia Tools",
|
"category": "Multimedia Tools",
|
||||||
"choco": "audacity",
|
"choco": "audacity",
|
||||||
@ -511,14 +503,6 @@
|
|||||||
"link": "https://www.epicgames.com/store/en-US/",
|
"link": "https://www.epicgames.com/store/en-US/",
|
||||||
"winget": "EpicGames.EpicGamesLauncher"
|
"winget": "EpicGames.EpicGamesLauncher"
|
||||||
},
|
},
|
||||||
"errorlookup": {
|
|
||||||
"category": "Utilities",
|
|
||||||
"choco": "na",
|
|
||||||
"content": "Windows Error Code Lookup",
|
|
||||||
"description": "ErrorLookup is a tool for looking up Windows error codes and their descriptions.",
|
|
||||||
"link": "https://github.com/HenryPP/ErrorLookup",
|
|
||||||
"winget": "Henry++.ErrorLookup"
|
|
||||||
},
|
|
||||||
"esearch": {
|
"esearch": {
|
||||||
"category": "Utilities",
|
"category": "Utilities",
|
||||||
"choco": "everything",
|
"choco": "everything",
|
||||||
|
@ -2713,6 +2713,9 @@
|
|||||||
reg delete \"HKEY_USERS\\Default\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run\" /v \"OneDriveSetup\" /f
|
reg delete \"HKEY_USERS\\Default\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run\" /v \"OneDriveSetup\" /f
|
||||||
reg unload \"hku\\Default\"
|
reg unload \"hku\\Default\"
|
||||||
|
|
||||||
|
Write-Host \"Removing autostart key\"
|
||||||
|
reg delete \"HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Run\" /v \"OneDrive\" /f
|
||||||
|
|
||||||
Write-Host \"Removing startmenu entry\"
|
Write-Host \"Removing startmenu entry\"
|
||||||
Remove-Item -Force -ErrorAction SilentlyContinue \"$env:userprofile\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\OneDrive.lnk\"
|
Remove-Item -Force -ErrorAction SilentlyContinue \"$env:userprofile\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\OneDrive.lnk\"
|
||||||
|
|
||||||
@ -3399,22 +3402,6 @@
|
|||||||
"ComboItems": "Default DHCP Google Cloudflare Cloudflare_Malware Cloudflare_Malware_Adult Open_DNS Quad9 AdGuard_Ads_Trackers AdGuard_Ads_Trackers_Malware_Adult",
|
"ComboItems": "Default DHCP Google Cloudflare Cloudflare_Malware Cloudflare_Malware_Adult Open_DNS Quad9 AdGuard_Ads_Trackers AdGuard_Ads_Trackers_Malware_Adult",
|
||||||
"link": "https://christitustech.github.io/winutil/dev/tweaks/z--Advanced-Tweaks---CAUTION/changedns"
|
"link": "https://christitustech.github.io/winutil/dev/tweaks/z--Advanced-Tweaks---CAUTION/changedns"
|
||||||
},
|
},
|
||||||
"WPFTweaksbutton": {
|
|
||||||
"Content": "Run Tweaks",
|
|
||||||
"category": "z__Advanced Tweaks - CAUTION",
|
|
||||||
"panel": "1",
|
|
||||||
"Order": "a041_",
|
|
||||||
"Type": "Button",
|
|
||||||
"link": "https://christitustech.github.io/winutil/dev/tweaks/z--Advanced-Tweaks---CAUTION/button"
|
|
||||||
},
|
|
||||||
"WPFUndoall": {
|
|
||||||
"Content": "Undo Selected Tweaks",
|
|
||||||
"category": "z__Advanced Tweaks - CAUTION",
|
|
||||||
"panel": "1",
|
|
||||||
"Order": "a042_",
|
|
||||||
"Type": "Button",
|
|
||||||
"link": "https://christitustech.github.io/winutil/dev/tweaks/z--Advanced-Tweaks---CAUTION/Undoall"
|
|
||||||
},
|
|
||||||
"WPFAddUltPerf": {
|
"WPFAddUltPerf": {
|
||||||
"Content": "Add and Activate Ultimate Performance Profile",
|
"Content": "Add and Activate Ultimate Performance Profile",
|
||||||
"category": "Performance Plans",
|
"category": "Performance Plans",
|
||||||
|
@ -7,7 +7,9 @@ function Invoke-WinUtilGPU {
|
|||||||
"*NVIDIA GeForce*Laptop*",
|
"*NVIDIA GeForce*Laptop*",
|
||||||
"*NVIDIA GeForce*GT*",
|
"*NVIDIA GeForce*GT*",
|
||||||
"*AMD Radeon(TM)*",
|
"*AMD Radeon(TM)*",
|
||||||
|
"*Intel(R) HD Graphics*",
|
||||||
"*UHD*"
|
"*UHD*"
|
||||||
|
|
||||||
)
|
)
|
||||||
|
|
||||||
foreach ($gpu in $gpuInfo) {
|
foreach ($gpu in $gpuInfo) {
|
||||||
|
@ -248,7 +248,7 @@ function Remove-FileOrDirectory([string]$pathToDelete, [string]$mask = "", [swit
|
|||||||
function New-Unattend {
|
function New-Unattend {
|
||||||
|
|
||||||
param (
|
param (
|
||||||
[Parameter(Mandatory, Position = 0)] [string] $userName,
|
[Parameter(Mandatory, Position = 0)] [string]$userName,
|
||||||
[Parameter(Position = 1)] [string] $userPassword
|
[Parameter(Position = 1)] [string] $userPassword
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ Function Update-WinUtilProgramWinget {
|
|||||||
|
|
||||||
$host.ui.RawUI.WindowTitle = """Winget Install"""
|
$host.ui.RawUI.WindowTitle = """Winget Install"""
|
||||||
|
|
||||||
Start-Transcript $ENV:TEMP\winget-update.log -Append
|
Start-Transcript "$logdir\winget-update_$dateTime.log" -Append
|
||||||
winget upgrade --all --accept-source-agreements --accept-package-agreements --scope=machine --silent
|
winget upgrade --all --accept-source-agreements --accept-package-agreements --scope=machine --silent
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -21,13 +21,13 @@ function Invoke-WPFButton {
|
|||||||
Switch -Wildcard ($Button) {
|
Switch -Wildcard ($Button) {
|
||||||
|
|
||||||
"WPFTab?BT" {Invoke-WPFTab $Button}
|
"WPFTab?BT" {Invoke-WPFTab $Button}
|
||||||
"WPFinstall" {Invoke-WPFInstall}
|
"WPFInstall" {Invoke-WPFInstall}
|
||||||
"WPFuninstall" {Invoke-WPFUnInstall}
|
"WPFUninstall" {Invoke-WPFUnInstall}
|
||||||
"WPFInstallUpgrade" {Invoke-WPFInstallUpgrade}
|
"WPFInstallUpgrade" {Invoke-WPFInstallUpgrade}
|
||||||
"WPFstandard" {Invoke-WPFPresets "Standard"}
|
"WPFStandard" {Invoke-WPFPresets "Standard" -checkboxfilterpattern "WPFTweak*"}
|
||||||
"WPFminimal" {Invoke-WPFPresets "Minimal"}
|
"WPFMinimal" {Invoke-WPFPresets "Minimal" -checkboxfilterpattern "WPFTweak*"}
|
||||||
"WPFclear" {Invoke-WPFPresets -preset $null -imported $true}
|
"WPFClearTweaksSelection" {Invoke-WPFPresets -imported $true -checkboxfilterpattern "WPFTweak*"}
|
||||||
"WPFclearWinget" {Invoke-WPFPresets -preset $null -imported $true -CheckBox "WPFInstall"}
|
"WPFClearInstallSelection" {Invoke-WPFPresets -imported $true -checkboxfilterpattern "WPFInstall*"}
|
||||||
"WPFtweaksbutton" {Invoke-WPFtweaksbutton}
|
"WPFtweaksbutton" {Invoke-WPFtweaksbutton}
|
||||||
"WPFOOSUbutton" {Invoke-WPFOOSU}
|
"WPFOOSUbutton" {Invoke-WPFOOSU}
|
||||||
"WPFAddUltPerf" {Invoke-WPFUltimatePerformance -State "Enable"}
|
"WPFAddUltPerf" {Invoke-WPFUltimatePerformance -State "Enable"}
|
||||||
|
@ -10,29 +10,36 @@ function Invoke-WPFPresets {
|
|||||||
.PARAMETER imported
|
.PARAMETER imported
|
||||||
If the preset is imported from a file, defaults to false
|
If the preset is imported from a file, defaults to false
|
||||||
|
|
||||||
.PARAMETER checkbox
|
.PARAMETER checkboxfilterpattern
|
||||||
The checkbox to set the options to, defaults to 'WPFTweaks'
|
The Pattern to use when filtering through CheckBoxes, defaults to "**"
|
||||||
|
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param(
|
param (
|
||||||
$preset,
|
[Parameter(position=0)]
|
||||||
[bool]$imported = $false
|
[string]$preset = "",
|
||||||
|
|
||||||
|
[Parameter(position=1)]
|
||||||
|
[bool]$imported = $false,
|
||||||
|
|
||||||
|
[Parameter(position=2)]
|
||||||
|
[string]$checkboxfilterpattern = "**"
|
||||||
)
|
)
|
||||||
|
|
||||||
if($imported -eq $true) {
|
if ($imported -eq $true) {
|
||||||
$CheckBoxesToCheck = $preset
|
$CheckBoxesToCheck = $preset
|
||||||
} else {
|
} else {
|
||||||
$CheckBoxesToCheck = $sync.configs.preset.$preset
|
$CheckBoxesToCheck = $sync.configs.preset.$preset
|
||||||
}
|
}
|
||||||
|
|
||||||
$CheckBoxes = $sync.GetEnumerator() | Where-Object { $_.Value -is [System.Windows.Controls.CheckBox] -and $_.Name -notlike "WPFToggle*" }
|
$CheckBoxes = ($sync.GetEnumerator()).where{ $_.Value -is [System.Windows.Controls.CheckBox] -and $_.Name -notlike "WPFToggle*" -and $_.Name -like "$checkboxfilterpattern"}
|
||||||
Write-Debug "Getting checkboxes to set $($CheckBoxes.Count)"
|
Write-Debug "Getting checkboxes to set, number of checkboxes: $($CheckBoxes.Count)"
|
||||||
|
|
||||||
$CheckBoxesToCheck | ForEach-Object {
|
if ($CheckBoxesToCheck -ne "") {
|
||||||
if ($_ -ne $null) {
|
$debugMsg = "CheckBoxes to Check are: "
|
||||||
Write-Debug $_
|
$CheckBoxesToCheck | ForEach-Object { $debugMsg += "$_, " }
|
||||||
}
|
$debugMsg = $debugMsg -replace (',\s*$', '')
|
||||||
|
Write-Debug "$debugMsg"
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach ($CheckBox in $CheckBoxes) {
|
foreach ($CheckBox in $CheckBoxes) {
|
||||||
|
@ -186,6 +186,7 @@ function Invoke-WPFUIElements {
|
|||||||
$label.ToolTip = $entryInfo.Description
|
$label.ToolTip = $entryInfo.Description
|
||||||
$label.HorizontalAlignment = "Left"
|
$label.HorizontalAlignment = "Left"
|
||||||
$label.FontSize = $theme.FontSize
|
$label.FontSize = $theme.FontSize
|
||||||
|
$label.Foreground = $theme.MainForegroundColor
|
||||||
$dockPanel.Children.Add($label) | Out-Null
|
$dockPanel.Children.Add($label) | Out-Null
|
||||||
$stackPanel.Children.Add($dockPanel) | Out-Null
|
$stackPanel.Children.Add($dockPanel) | Out-Null
|
||||||
|
|
||||||
|
@ -1,5 +1,12 @@
|
|||||||
{% extends "base.html" %}
|
{% extends "base.html" %}
|
||||||
|
|
||||||
|
{% block header %}
|
||||||
|
{{ super() }}
|
||||||
|
<div style="color: red; text-align: center; padding: 10px; font-size: 20px;">
|
||||||
|
<strong>Announcement:</strong> We are currently not adding any applications to WinUtil and any apps that will be added through a PR will be declined by the maintainer.
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
{% block footer %}
|
{% block footer %}
|
||||||
{# Empty block to override the footer #}
|
{# Empty block to override the footer #}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
@ -37,6 +37,12 @@ Describe "Config Files" -ForEach @(
|
|||||||
$result = New-Object System.Collections.Generic.List[System.Object]
|
$result = New-Object System.Collections.Generic.List[System.Object]
|
||||||
Foreach ($application in $applications) {
|
Foreach ($application in $applications) {
|
||||||
$compare = $global:importedconfigs.$name.$application | Get-Member -MemberType NoteProperty | Select-Object -ExpandProperty name
|
$compare = $global:importedconfigs.$name.$application | Get-Member -MemberType NoteProperty | Select-Object -ExpandProperty name
|
||||||
|
if (-not $compare) {
|
||||||
|
throw "Comparison object for application '$application' is null."
|
||||||
|
}
|
||||||
|
if (-not $template) {
|
||||||
|
throw "Template object for application '$application' is null."
|
||||||
|
}
|
||||||
if ($(Compare-Object $compare $template) -ne $null) {
|
if ($(Compare-Object $compare $template) -ne $null) {
|
||||||
$result.Add($application)
|
$result.Add($application)
|
||||||
}
|
}
|
||||||
|
@ -85,22 +85,16 @@ try {
|
|||||||
$sync["Form"] = [Windows.Markup.XamlReader]::Load( $reader )
|
$sync["Form"] = [Windows.Markup.XamlReader]::Load( $reader )
|
||||||
$readerOperationSuccessful = $true
|
$readerOperationSuccessful = $true
|
||||||
} catch [System.Management.Automation.MethodInvocationException] {
|
} catch [System.Management.Automation.MethodInvocationException] {
|
||||||
Write-Warning "We ran into a problem with the XAML code. Check the syntax for this control..."
|
Write-Host "We ran into a problem with the XAML code. Check the syntax for this control..." -ForegroundColor Red
|
||||||
Write-Host $error[0].Exception.Message -ForegroundColor Red
|
Write-Host $error[0].Exception.Message -ForegroundColor Red
|
||||||
|
|
||||||
If ($error[0].Exception.Message -like "*button*") {
|
If ($error[0].Exception.Message -like "*button*") {
|
||||||
write-warning "Ensure your <button in the `$inputXML does NOT have a Click=ButtonClick property. PS can't handle this`n`n`n`n"
|
write-Host "Ensure your <button in the `$inputXML does NOT have a Click=ButtonClick property. PS can't handle this`n`n`n`n" -ForegroundColor Red
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
Write-Host "Unable to load Windows.Markup.XamlReader. Double-check syntax and ensure .net is installed."
|
Write-Host "Unable to load Windows.Markup.XamlReader. Double-check syntax and ensure .net is installed." -ForegroundColor Red
|
||||||
}
|
}
|
||||||
|
|
||||||
# Load the configuration files
|
|
||||||
#Invoke-WPFUIElements -configVariable $sync.configs.nav -targetGridName "WPFMainGrid"
|
|
||||||
Invoke-WPFUIElements -configVariable $sync.configs.applications -targetGridName "appspanel" -columncount 5
|
|
||||||
Invoke-WPFUIElements -configVariable $sync.configs.tweaks -targetGridName "tweakspanel" -columncount 2
|
|
||||||
Invoke-WPFUIElements -configVariable $sync.configs.feature -targetGridName "featurespanel" -columncount 2
|
|
||||||
|
|
||||||
if (-NOT ($readerOperationSuccessful)) {
|
if (-NOT ($readerOperationSuccessful)) {
|
||||||
Write-Host "Failed to parse xaml content using Windows.Markup.XamlReader's Load Method." -ForegroundColor Red
|
Write-Host "Failed to parse xaml content using Windows.Markup.XamlReader's Load Method." -ForegroundColor Red
|
||||||
Write-Host "Quitting winutil..." -ForegroundColor Red
|
Write-Host "Quitting winutil..." -ForegroundColor Red
|
||||||
@ -110,6 +104,12 @@ if (-NOT ($readerOperationSuccessful)) {
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Load the configuration files
|
||||||
|
#Invoke-WPFUIElements -configVariable $sync.configs.nav -targetGridName "WPFMainGrid"
|
||||||
|
Invoke-WPFUIElements -configVariable $sync.configs.applications -targetGridName "appspanel" -columncount 5
|
||||||
|
Invoke-WPFUIElements -configVariable $sync.configs.tweaks -targetGridName "tweakspanel" -columncount 2
|
||||||
|
Invoke-WPFUIElements -configVariable $sync.configs.feature -targetGridName "featurespanel" -columncount 2
|
||||||
|
|
||||||
#===========================================================================
|
#===========================================================================
|
||||||
# Store Form Objects In PowerShell
|
# Store Form Objects In PowerShell
|
||||||
#===========================================================================
|
#===========================================================================
|
||||||
|
@ -27,11 +27,11 @@ if ($Run) {
|
|||||||
$PARAM_RUN = $true
|
$PARAM_RUN = $true
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(Test-Path -Path $ENV:TEMP)) {
|
$dateTime = Get-Date -Format "yyyy-MM-dd_HH-mm-ss"
|
||||||
New-Item -ItemType Directory -Force -Path $ENV:TEMP
|
|
||||||
}
|
|
||||||
|
|
||||||
Start-Transcript $ENV:TEMP\Winutil.log -Append
|
$logdir = "$env:localappdata\winutil\logs"
|
||||||
|
[System.IO.Directory]::CreateDirectory("$logdir")
|
||||||
|
Start-Transcript -Path "$logdir\winutil_$dateTime.log" -Append
|
||||||
|
|
||||||
# Load DLLs
|
# Load DLLs
|
||||||
Add-Type -AssemblyName PresentationFramework
|
Add-Type -AssemblyName PresentationFramework
|
||||||
|
@ -315,7 +315,7 @@
|
|||||||
Margin="2"
|
Margin="2"
|
||||||
SnapsToDevicePixels="True"/>
|
SnapsToDevicePixels="True"/>
|
||||||
<Path x:Name="CheckMark"
|
<Path x:Name="CheckMark"
|
||||||
Stroke="{TemplateBinding Foreground}"
|
Stroke="{ToggleButtonOnColor}"
|
||||||
StrokeThickness="2"
|
StrokeThickness="2"
|
||||||
Data="M 0 5 L 5 10 L 12 0"
|
Data="M 0 5 L 5 10 L 12 0"
|
||||||
Visibility="Collapsed"/>
|
Visibility="Collapsed"/>
|
||||||
@ -427,7 +427,11 @@
|
|||||||
Width="34" Height="17">
|
Width="34" Height="17">
|
||||||
<Ellipse x:Name="Ellipse" Fill="{MainForegroundColor}" Stretch="Uniform"
|
<Ellipse x:Name="Ellipse" Fill="{MainForegroundColor}" Stretch="Uniform"
|
||||||
Margin="2,2,2,1"
|
Margin="2,2,2,1"
|
||||||
HorizontalAlignment="Left" Width="12">
|
HorizontalAlignment="Left" Width="10.8"
|
||||||
|
RenderTransformOrigin="0.5, 0.5">
|
||||||
|
<Ellipse.RenderTransform>
|
||||||
|
<ScaleTransform ScaleX="1" ScaleY="1" />
|
||||||
|
</Ellipse.RenderTransform>
|
||||||
</Ellipse>
|
</Ellipse>
|
||||||
</Border>
|
</Border>
|
||||||
</Grid>
|
</Grid>
|
||||||
@ -438,12 +442,35 @@
|
|||||||
<Setter TargetName="Border" Property="Background" Value="{LinkHoverForegroundColor}"/>
|
<Setter TargetName="Border" Property="Background" Value="{LinkHoverForegroundColor}"/>
|
||||||
<Setter Property="Cursor" Value="Hand" />
|
<Setter Property="Cursor" Value="Hand" />
|
||||||
<Setter Property="Panel.ZIndex" Value="1000"/>
|
<Setter Property="Panel.ZIndex" Value="1000"/>
|
||||||
|
<Trigger.EnterActions>
|
||||||
|
<BeginStoryboard>
|
||||||
|
<Storyboard>
|
||||||
|
<DoubleAnimation Storyboard.TargetName="Ellipse"
|
||||||
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleX)"
|
||||||
|
To="1.1" Duration="0:0:0.1" />
|
||||||
|
<DoubleAnimation Storyboard.TargetName="Ellipse"
|
||||||
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleY)"
|
||||||
|
To="1.1" Duration="0:0:0.1" />
|
||||||
|
</Storyboard>
|
||||||
|
</BeginStoryboard>
|
||||||
|
</Trigger.EnterActions>
|
||||||
|
<Trigger.ExitActions>
|
||||||
|
<BeginStoryboard>
|
||||||
|
<Storyboard>
|
||||||
|
<DoubleAnimation Storyboard.TargetName="Ellipse"
|
||||||
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleX)"
|
||||||
|
To="1.0" Duration="0:0:0.1" />
|
||||||
|
<DoubleAnimation Storyboard.TargetName="Ellipse"
|
||||||
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleY)"
|
||||||
|
To="1.0" Duration="0:0:0.1" />
|
||||||
|
</Storyboard>
|
||||||
|
</BeginStoryboard>
|
||||||
|
</Trigger.ExitActions>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="ToggleButton.IsChecked" Value="False">
|
<Trigger Property="ToggleButton.IsChecked" Value="False">
|
||||||
<Setter TargetName="Border" Property="Background" Value="{MainBackgroundColor}" />
|
<Setter TargetName="Border" Property="Background" Value="{MainBackgroundColor}" />
|
||||||
<Setter TargetName="Border" Property="BorderBrush" Value="{MainForegroundColor}" />
|
<Setter TargetName="Border" Property="BorderBrush" Value="#707070" />
|
||||||
<Setter TargetName="Ellipse" Property="Fill" Value="{MainForegroundColor}" />
|
<Setter TargetName="Ellipse" Property="Fill" Value="#707070" />
|
||||||
|
|
||||||
</Trigger>
|
</Trigger>
|
||||||
|
|
||||||
<Trigger Property="ToggleButton.IsChecked" Value="True">
|
<Trigger Property="ToggleButton.IsChecked" Value="True">
|
||||||
@ -787,11 +814,11 @@
|
|||||||
<RowDefinition Height="0.95*"/>
|
<RowDefinition Height="0.95*"/>
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
<StackPanel Background="{MainBackgroundColor}" Orientation="Horizontal" Grid.Row="0" HorizontalAlignment="Left" VerticalAlignment="Top" Grid.Column="0" Grid.ColumnSpan="3" Margin="{TabContentMargin}">
|
<StackPanel Background="{MainBackgroundColor}" Orientation="Horizontal" Grid.Row="0" HorizontalAlignment="Left" VerticalAlignment="Top" Grid.Column="0" Grid.ColumnSpan="3" Margin="{TabContentMargin}">
|
||||||
<Button Name="WPFinstall" Content=" Install/Upgrade Selected" Margin="2" />
|
<Button Name="WPFInstall" Content=" Install/Upgrade Selected" Margin="2" />
|
||||||
<Button Name="WPFInstallUpgrade" Content=" Upgrade All" Margin="2"/>
|
<Button Name="WPFInstallUpgrade" Content=" Upgrade All" Margin="2"/>
|
||||||
<Button Name="WPFuninstall" Content=" Uninstall Selected" Margin="2"/>
|
<Button Name="WPFUninstall" Content=" Uninstall Selected" Margin="2"/>
|
||||||
<Button Name="WPFGetInstalled" Content=" Get Installed" Margin="2"/>
|
<Button Name="WPFGetInstalled" Content=" Get Installed" Margin="2"/>
|
||||||
<Button Name="WPFclearWinget" Content=" Clear Selection" Margin="2"/>
|
<Button Name="WPFClearInstallSelection" Content=" Clear Selection" Margin="2"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
<ScrollViewer x:Name="scrollViewer" Grid.Row="1" Grid.Column="0" Margin="{TabContentMargin}" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto"
|
<ScrollViewer x:Name="scrollViewer" Grid.Row="1" Grid.Column="0" Margin="{TabContentMargin}" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto"
|
||||||
@ -842,6 +869,20 @@
|
|||||||
</Border>
|
</Border>
|
||||||
</Grid>
|
</Grid>
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
|
<Border Grid.Row="1" Background="{MainBackgroundColor}" BorderBrush="{BorderColor}" BorderThickness="1" CornerRadius="5" HorizontalAlignment="Stretch" Padding="10">
|
||||||
|
<Grid>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="1*" />
|
||||||
|
<ColumnDefinition Width="1*" />
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
|
||||||
|
<!-- Buttons on the left half -->
|
||||||
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Left" VerticalAlignment="Center" Grid.Column="0">
|
||||||
|
<Button Name="WPFTweaksbutton" Content="Run Tweaks" Margin="5"/>
|
||||||
|
<Button Name="WPFUndoall" Content="Undo Selected Tweaks" Margin="5"/>
|
||||||
|
</StackPanel>
|
||||||
|
</Grid>
|
||||||
|
</Border>
|
||||||
</Grid>
|
</Grid>
|
||||||
</TabItem>
|
</TabItem>
|
||||||
<TabItem Header="Config" Visibility="Collapsed" Name="WPFTab3">
|
<TabItem Header="Config" Visibility="Collapsed" Name="WPFTab3">
|
||||||
|
Reference in New Issue
Block a user