Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
9d50b8c
GameBoost v2 Fase 0: fundacao e reconstrucao da v1
alemavaz1-afk Sep 14, 2026
1eaeb88
Fase 0: destrava a execucao do exe e corrige a regra 3
alemavaz1-afk Sep 14, 2026
49624fc
Shell de navegacao da secao 6
alemavaz1-afk Sep 14, 2026
2795dc0
Fase 1: diagnostico de gargalos e relatorio de saude
alemavaz1-afk Sep 14, 2026
94f6d0c
Corrige cinco problemas achados no teste com privilegios
alemavaz1-afk Sep 14, 2026
86f24ea
Corrige crash ao renderizar lista e o passo do instalador no CI
alemavaz1-afk Sep 14, 2026
a7e9390
QA real do ciclo de reversibilidade, e corrige AppPaths em single-file
alemavaz1-afk Sep 14, 2026
2c3071d
Fase 2: modulo de limpeza
alemavaz1-afk Sep 14, 2026
b07afcf
Fase 2: ferramentas rapidas, fechando a fase
alemavaz1-afk Sep 14, 2026
c93d259
Fase 3: varredura de disco, e a MFT crua nao foi necessaria
alemavaz1-afk Sep 14, 2026
019c6a6
Fase 3: treemap, listas e biblioteca de jogos
alemavaz1-afk Sep 14, 2026
2b45ec9
Fase 4: inventario de apps e restos de apps antigos
alemavaz1-afk Sep 14, 2026
0bc5323
Fase 4: desinstalador em lote e gerenciador de inicializacao
alemavaz1-afk Sep 14, 2026
8d0dfc7
Fase 5: tweaks, servicos, rede com NAT e drivers de video
alemavaz1-afk Sep 14, 2026
8984de6
Complemento da Fase 4: aba Atualizacoes (winget) e aba Restos na tela
alemavaz1-afk Sep 14, 2026
c95011d
Fase 6: perfis por jogo, bandeja e onboarding
alemavaz1-afk Sep 14, 2026
73c25c0
Fase 7: auto-update, CI de release, portatil e assinatura
alemavaz1-afk Sep 14, 2026
db779e9
QA manual: seis correcoes achadas rodando o app de verdade
alemavaz1-afk Sep 14, 2026
f98b305
QA manual: o teste de velocidade media a rajada, nao a linha
alemavaz1-afk Sep 14, 2026
eb02d55
QA manual: um Pack = 1 apagava a Lixeira do aplicativo inteiro
alemavaz1-afk Sep 14, 2026
d2bfc49
QA manual: o Reverter da inicializacao devolvia sucesso sem reverter
alemavaz1-afk Sep 14, 2026
ffd6b56
QA manual: a deteccao de jogo funcionava, era tudo depois dela que nao
alemavaz1-afk Sep 14, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
102 changes: 102 additions & 0 deletions .github/workflows/gameboost-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
name: build

on:
push:
branches: [main]
paths: ['GameBoost/**', '.github/workflows/build.yml']
pull_request:
paths: ['GameBoost/**']
workflow_dispatch:

defaults:
run:
working-directory: GameBoost

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Restaurar
run: dotnet restore GameBoost.sln

- name: Compilar
run: dotnet build GameBoost.sln -c Release --no-restore -warnaserror

- name: Testar
run: dotnet test GameBoost.sln -c Release --no-build --logger "trx;LogFileName=testes.trx"

- name: Publicar testes
if: always()
uses: actions/upload-artifact@v4
with:
name: resultado-testes
path: GameBoost/**/TestResults/*.trx

- name: Publicar executavel
run: >
dotnet publish src/GameBoost.App/GameBoost.App.csproj
-c Release -r win-x64 --self-contained
-p:PublishSingleFile=true
-p:IncludeNativeLibrariesForSelfExtract=true
-p:PublishReadyToRun=true
-o publish

# Trimming quebra WPF e reflexao (secao 10 do spec). Falha a build se alguem ligar.
- name: Conferir que o trimming segue desligado
shell: pwsh
run: |
$props = Get-Content Directory.Build.props -Raw
if ($props -notmatch '<PublishTrimmed>false</PublishTrimmed>') {
throw 'PublishTrimmed precisa continuar false: trimming quebra WPF.'
}

- name: Montar o instalador
shell: pwsh
run: |
choco install innosetup --no-progress -y --no-color

# $env:ProgramFiles(x86) nao e sintaxe valida: o PowerShell le
# "$env:ProgramFiles" e deixa "(x86)" solto, virando
# "C:\Program Files(x86)". A forma correta e ${env:...}.
# O ISCC tambem muda de lugar conforme a instalacao, entao vale
# procurar em vez de fixar um caminho.
$candidatos = @(
"${env:ProgramFiles(x86)}\Inno Setup 6\ISCC.exe",
"$env:ProgramFiles\Inno Setup 6\ISCC.exe",
"$env:LOCALAPPDATA\Programs\Inno Setup 6\ISCC.exe"
)

$iscc = $candidatos | Where-Object { Test-Path $_ } | Select-Object -First 1
if (-not $iscc) {
throw "ISCC.exe nao encontrado. Procurado em: $($candidatos -join '; ')"
}

Write-Host "Usando $iscc"
& $iscc installer\GameBoost.iss
if ($LASTEXITCODE -ne 0) { throw "ISCC falhou com codigo $LASTEXITCODE" }

- name: Gerar SHA256SUMS
shell: pwsh
run: |
$arquivos = @(Get-ChildItem publish\GameBoost.exe, installer\Output\*.exe -ErrorAction SilentlyContinue)
$arquivos | ForEach-Object {
$h = (Get-FileHash $_.FullName -Algorithm SHA256).Hash.ToLower()
"$h $($_.Name)"
} | Set-Content SHA256SUMS.txt -Encoding utf8
Get-Content SHA256SUMS.txt

- name: Publicar artefatos
uses: actions/upload-artifact@v4
with:
name: gameboost
path: |
GameBoost/publish/GameBoost.exe
GameBoost/installer/Output/*.exe
GameBoost/SHA256SUMS.txt
220 changes: 220 additions & 0 deletions .github/workflows/gameboost-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,220 @@
name: release

# Dispara só em tag `gameboost-vX.Y.Z`. O repositório guarda mais de um
# projeto, então a tag carrega o nome do produto: uma tag `v2.0.0` solta
# construiria o GameBoost por engano quando outro projeto for versionado.
on:
push:
tags: ['gameboost-v*']
workflow_dispatch:
inputs:
versao:
description: 'Versão a empacotar (ex.: 2.0.0). Só para teste manual.'
required: true

defaults:
run:
working-directory: GameBoost

permissions:
contents: write

jobs:
release:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Descobrir a versao
id: versao
shell: pwsh
run: |
if ($env:GITHUB_REF -like 'refs/tags/gameboost-v*') {
$v = $env:GITHUB_REF -replace '.*/gameboost-v', ''
} else {
$v = '${{ github.event.inputs.versao }}'
}

if ($v -notmatch '^\d+\.\d+\.\d+$') {
throw "Versao invalida: '$v'. Esperado X.Y.Z."
}

# A tag e o Directory.Build.props precisam concordar. Publicar uma
# tag 2.1.0 com o assembly dizendo 2.0.0 deixaria o auto-update
# comparando numeros que nao batem com o que o usuario tem.
$props = Get-Content Directory.Build.props -Raw
if ($props -notmatch "<VersionPrefix>$([regex]::Escape($v))</VersionPrefix>") {
throw "A tag diz $v mas o Directory.Build.props diz outra coisa. Alinhe os dois."
}

"versao=$v" >> $env:GITHUB_OUTPUT
Write-Host "Versao: $v"

- name: Restaurar
run: dotnet restore GameBoost.sln

- name: Testar
run: dotnet test GameBoost.sln -c Release --logger "trx;LogFileName=testes.trx"

- name: Publicar executavel
run: >
dotnet publish src/GameBoost.App/GameBoost.App.csproj
-c Release -r win-x64 --self-contained
-p:PublishSingleFile=true
-p:IncludeNativeLibrariesForSelfExtract=true
-p:PublishReadyToRun=true
-p:Version=${{ steps.versao.outputs.versao }}
-o publish

# ------------------------------------------------------------------
# Assinatura de codigo
# ------------------------------------------------------------------
#
# Condicional de proposito. O certificado OV vive num token USB ou HSM
# (exigencia das CAs desde jun/2023), entao nem sempre esta disponivel
# para o CI. Sem o segredo, a release sai **sem assinatura** e o passo
# seguinte avisa em alto e bom som, em vez de falhar a build inteira.
#
# Ver docs/ASSINATURA.md para o que foi apurado sobre as opcoes.
- name: Assinar o executavel
if: ${{ secrets.GAMEBOOST_CERT_PFX != '' }}
env:
CERT_PFX: ${{ secrets.GAMEBOOST_CERT_PFX }}
CERT_SENHA: ${{ secrets.GAMEBOOST_CERT_SENHA }}
shell: pwsh
run: |
$pfx = "$env:RUNNER_TEMP\cert.pfx"
[IO.File]::WriteAllBytes($pfx, [Convert]::FromBase64String($env:CERT_PFX))

$signtool = Get-ChildItem "${env:ProgramFiles(x86)}\Windows Kits\10\bin" -Recurse -Filter signtool.exe |
Where-Object { $_.FullName -like '*\x64\*' } |
Select-Object -First 1 -ExpandProperty FullName

if (-not $signtool) { throw 'signtool.exe nao encontrado no runner.' }

& $signtool sign /f $pfx /p $env:CERT_SENHA `
/fd SHA256 /tr http://timestamp.sectigo.com /td SHA256 `
publish\GameBoost.exe

if ($LASTEXITCODE -ne 0) { throw "signtool falhou com codigo $LASTEXITCODE" }
Remove-Item $pfx -Force

- name: Avisar que a release sai sem assinatura
if: ${{ !secrets.GAMEBOOST_CERT_PFX }}
shell: pwsh
run: |
Write-Host '::warning::Sem certificado configurado: esta release sai SEM assinatura de codigo. O SmartScreen vai avisar no primeiro download. Ver docs/ASSINATURA.md.'

# ------------------------------------------------------------------
# Pacote de atualizacao (Velopack)
# ------------------------------------------------------------------
- name: Empacotar com o Velopack
shell: pwsh
run: |
dotnet tool install -g vpk
$env:PATH = "$env:USERPROFILE\.dotnet\tools;$env:PATH"

vpk pack `
--packId GameBoost `
--packVersion ${{ steps.versao.outputs.versao }} `
--packDir publish `
--mainExe GameBoost.exe `
--packTitle GameBoost `
--packAuthors "Jonathan Vaz" `
--outputDir velopack

if ($LASTEXITCODE -ne 0) { throw "vpk pack falhou com codigo $LASTEXITCODE" }

- name: Montar o instalador
shell: pwsh
run: |
choco install innosetup --no-progress -y --no-color

$candidatos = @(
"${env:ProgramFiles(x86)}\Inno Setup 6\ISCC.exe",
"$env:ProgramFiles\Inno Setup 6\ISCC.exe",
"$env:LOCALAPPDATA\Programs\Inno Setup 6\ISCC.exe"
)

$iscc = $candidatos | Where-Object { Test-Path $_ } | Select-Object -First 1
if (-not $iscc) { throw "ISCC.exe nao encontrado. Procurado em: $($candidatos -join '; ')" }

& $iscc /DAppVersion=${{ steps.versao.outputs.versao }} installer\GameBoost.iss
if ($LASTEXITCODE -ne 0) { throw "ISCC falhou com codigo $LASTEXITCODE" }

# ------------------------------------------------------------------
# Portatil
# ------------------------------------------------------------------
#
# O mesmo exe, mais um portable.txt vazio ao lado. O AppPaths procura
# esse arquivo e, achando, guarda tudo em .\data\ em vez de
# %LOCALAPPDATA%. Nada muda no codigo.
- name: Montar o portatil
shell: pwsh
run: |
$pasta = "portatil\GameBoost-${{ steps.versao.outputs.versao }}-portatil"
New-Item -ItemType Directory -Force $pasta | Out-Null

Copy-Item publish\GameBoost.exe $pasta
Copy-Item README.md "$pasta\LEIA-ME.txt"

@(
'Este arquivo faz o GameBoost guardar tudo em .\data\, ao lado do executavel,'
'em vez de %LOCALAPPDATA%\GameBoost.'
''
'Apague este arquivo para voltar ao comportamento normal.'
''
'O modo portatil nao tem atualizacao automatica: baixe a versao nova pela'
'pagina de releases quando quiser trocar.'
) | Set-Content "$pasta\portable.txt" -Encoding utf8

Compress-Archive -Path "$pasta\*" -DestinationPath "portatil\GameBoost-${{ steps.versao.outputs.versao }}-portatil.zip" -Force

- name: Gerar SHA256SUMS
shell: pwsh
run: |
$arquivos = @(
Get-ChildItem publish\GameBoost.exe -ErrorAction SilentlyContinue
Get-ChildItem installer\Output\*.exe -ErrorAction SilentlyContinue
Get-ChildItem portatil\*.zip -ErrorAction SilentlyContinue
Get-ChildItem velopack\*.nupkg, velopack\*.exe -ErrorAction SilentlyContinue
)

if ($arquivos.Count -eq 0) { throw 'Nenhum artefato para somar.' }

$arquivos | ForEach-Object {
$h = (Get-FileHash $_.FullName -Algorithm SHA256).Hash.ToLower()
"$h $($_.Name)"
} | Set-Content SHA256SUMS.txt -Encoding utf8

Get-Content SHA256SUMS.txt

- name: Anexar tudo ao Release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
name: GameBoost ${{ steps.versao.outputs.versao }}
body_path: GameBoost/installer/NOTAS-DA-RELEASE.md
files: |
GameBoost/publish/GameBoost.exe
GameBoost/installer/Output/*.exe
GameBoost/portatil/*.zip
GameBoost/velopack/*
GameBoost/SHA256SUMS.txt

- name: Guardar artefatos da execucao manual
if: ${{ !startsWith(github.ref, 'refs/tags/') }}
uses: actions/upload-artifact@v4
with:
name: gameboost-${{ steps.versao.outputs.versao }}
path: |
GameBoost/publish/GameBoost.exe
GameBoost/installer/Output/*.exe
GameBoost/portatil/*.zip
GameBoost/velopack/*
GameBoost/SHA256SUMS.txt
16 changes: 16 additions & 0 deletions GameBoost/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Build
bin/
obj/
publish/
*.user
*.suo
.vs/

# Publish e instalador
installer/Output/
*.exe
*.msi

# Dados locais do app em modo portatil
data/
*.log
Loading
Loading