Skip to content

Instantly share code, notes, and snippets.

@tnhung2011
Last active February 8, 2026 11:08
Show Gist options
  • Select an option

  • Save tnhung2011/6e1d40a917c2819654ea16e478ae620e to your computer and use it in GitHub Desktop.

Select an option

Save tnhung2011/6e1d40a917c2819654ea16e478ae620e to your computer and use it in GitHub Desktop.
Uninstall FluentFlyout along with its certificate
<# :
@echo off
setlocal enableextensions
:: net session depends on Server service, so this method is used instead
reg query HKEY_USERS\S-1-5-19\Environment /v TEMP >nul 2>nul || (
choice /M "Relaunch the script as administrator"
if errorlevel 2 goto :eof
mshta vbscript:Execute("CreateObject(""Shell.Application"").ShellExecute ""%~f0"", """", """", ""runas"", 1:code close"^)
goto :eof
)
powershell -NoProfile -NoLogo "iex (${%~f0} | out-string)"
pause
goto :eof
#>
$app = Get-AppxPackage unchihugo.FluentFlyout -AllUsers -ErrorAction Stop
if ($app -eq $null) {
[Console]::Error.WriteLine("Package not found: unchihugo.FluentFlyout")
exit 1
} else {
Write-Output "Found package: unchihugo.FluentFlyout"
}
$loc = $app.InstallLocation
choice /M "Do you want to remove unchihugo.FluentFlyout"
# Selected no or error?
if ($LASTEXITCODE -in 2, 255) { exit 1 }
Write-Output "Stopping FluentFlyout process..."
$process = Get-Process FluentFlyout -ea SilentlyContinue
if ($process -ne $null) { $process | Stop-Process }
Write-Output "Removing package..."
$NoCert = $false
$cert = Join-Path $loc "AppxSignature.p7x"
$thumb = [System.Security.Cryptography.X509Certificates.X509Certificate2]::new($cert).thumbprint
if ($? -eq $false) {
[Console]::Error.WriteLine("Can't find certificate at: $cert")
$NoCert = $true
}
$app | Remove-AppxPackage -AllUsers -ErrorAction Stop
if ($NoCert) { exit }
Write-Output "Removing associated certificate..."
Remove-Item Cert:\LocalMachine\TrustedPeople\$thumb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment