Téléverser les fichiers vers "/"

This commit is contained in:
2026-06-11 12:14:35 +02:00
parent f1563c7c04
commit 029707a4cd
+38
View File
@@ -0,0 +1,38 @@
# ============================================================
# CONFIG
# ============================================================
$BaseUrl = "https://repo.luckyden.org/admin_tan/PowerBGInfoGlobal/src/branch/main/PowerBGInfoGlobal.zip"
$ModuleZip = "$env:TEMP\PowerBGInfoGlobal.zip"
$ModuleDest = "$Env:ProgramFiles\WindowsPowerShell\Modules"
$DataPath = "C:\ProgramData\PowerBGInfo"
$WallpaperPath = "C:\Windows\Web\Wallpaper\Windows\img19-resize.jpg"
# ============================================================
# DOSSIERS
# ============================================================
New-Item -Path $DataPath -ItemType Directory -Force | Out-Null
# ============================================================
# DOWNLOAD
# ============================================================
Invoke-WebRequest "$BaseUrl/PowerBGInfoGlobal.zip" -OutFile $ModuleZip
Invoke-WebRequest "$BaseUrl/Set-WallpaperPowerBGInfoGlobal.ps1" -OutFile "$DataPath\Set-WallpaperPowerBGInfoGlobal.ps1"
Invoke-WebRequest "$BaseUrl/Set-ScheduledTaskPowerBGInfo.ps1" -OutFile "$DataPath\Set-ScheduledTaskPowerBGInfo.ps1"
Invoke-WebRequest "$BaseUrl/img19-resize.jpg" -OutFile $WallpaperPath
# ============================================================
# INSTALL MODULE
# ============================================================
Expand-Archive $ModuleZip -DestinationPath $ModuleDest -Force
# ============================================================
# CREATE SCHEDULED TASK
# ============================================================
& "$DataPath\Set-ScheduledTaskPowerBGInfo.ps1"
# ============================================================
# FIRST RUN
# ============================================================
& "$DataPath\Set-WallpaperPowerBGInfoGlobal.ps1"