Add PowerShell scripts for Windows auto-update

This commit is contained in:
Lizandro Guarnizo
2026-06-17 13:41:04 -05:00
parent f2564db6ee
commit a49a6626d3
2 changed files with 52 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
Set-Location $PSScriptRoot
$python = Get-Command python -ErrorAction SilentlyContinue
if (-not $python) {
Write-Host "Descargando Python 3.12..."
Invoke-WebRequest -Uri "https://www.python.org/ftp/python/3.12.9/python-3.12.9-amd64.exe" -OutFile "$env:TEMP\python-installer.exe"
Write-Host "Instalando Python..."
Start-Process -Wait -FilePath "$env:TEMP\python-installer.exe" -ArgumentList "/quiet InstallAllUsers=0 PrependPath=1 Include_test=0"
Write-Host "Python instalado. Cerrá y abrí PowerShell de nuevo, o ejecutá este script otra vez."
Read-Host "Enter para salir"
exit
}
Write-Host "Pull inicial..."
git pull
python -m pip install -q -r requirements.txt
Write-Host "`n=========================================="
Write-Host " Servidor: http://localhost:8080"
Write-Host " Auto-update cada 60 segundos"
Write-Host "=========================================="
python auto_update.py