mirror of
https://github.com/Finesssee/ProxyPilot.git
synced 2026-11-20 20:34:36 +00:00
branding: rename tray app to ProxyPilot
This commit is contained in:
@@ -14,7 +14,7 @@ import (
|
||||
"github.com/router-for-me/CLIProxyAPI/v6/internal/desktopctl"
|
||||
)
|
||||
|
||||
const autostartAppName = "CLIProxyAPI Manager"
|
||||
const autostartAppName = "ProxyPilot"
|
||||
|
||||
func main() {
|
||||
var repoRoot string
|
||||
@@ -30,23 +30,23 @@ func main() {
|
||||
|
||||
func run(repoRoot, configPath, exePath string) {
|
||||
systray.Run(func() {
|
||||
systray.SetTitle("CLIProxyAPI")
|
||||
systray.SetTooltip("CLIProxyAPI")
|
||||
systray.SetTitle("ProxyPilot")
|
||||
systray.SetTooltip("ProxyPilot")
|
||||
|
||||
statusItem := systray.AddMenuItem("Status: …", "Current status")
|
||||
statusItem.Disable()
|
||||
systray.AddSeparator()
|
||||
|
||||
startItem := systray.AddMenuItem("Start", "Start CLIProxyAPI")
|
||||
stopItem := systray.AddMenuItem("Stop", "Stop CLIProxyAPI")
|
||||
restartItem := systray.AddMenuItem("Restart", "Restart CLIProxyAPI")
|
||||
startItem := systray.AddMenuItem("Start", "Start CLIProxyAPI (proxy server)")
|
||||
stopItem := systray.AddMenuItem("Stop", "Stop CLIProxyAPI (proxy server)")
|
||||
restartItem := systray.AddMenuItem("Restart", "Restart CLIProxyAPI (proxy server)")
|
||||
systray.AddSeparator()
|
||||
|
||||
autoOn, _, _ := desktopctl.IsWindowsRunAutostartEnabled(autostartAppName)
|
||||
autoStartItem := systray.AddMenuItemCheckbox("Launch on login", "Start this tray app when you log in", autoOn)
|
||||
systray.AddSeparator()
|
||||
|
||||
openProxyUI := systray.AddMenuItem("Open Proxy UI", "Open the built-in management UI")
|
||||
openProxyUI := systray.AddMenuItem("Open Proxy UI", "Open CLIProxyAPI built-in management UI")
|
||||
openLogs := systray.AddMenuItem("Open Logs", "Open logs folder")
|
||||
systray.AddSeparator()
|
||||
|
||||
@@ -62,7 +62,7 @@ func run(repoRoot, configPath, exePath string) {
|
||||
title = title + " — " + shorten(lastErr, 80)
|
||||
}
|
||||
statusItem.SetTitle("Status: " + title)
|
||||
systray.SetTooltip("CLIProxyAPI — " + title)
|
||||
systray.SetTooltip("ProxyPilot — " + title)
|
||||
|
||||
if st.Running {
|
||||
startItem.Disable()
|
||||
|
||||
@@ -11,9 +11,9 @@ if (-not (Test-Path -LiteralPath $outDir)) {
|
||||
New-Item -ItemType Directory -Path $outDir | Out-Null
|
||||
}
|
||||
|
||||
$outPath = Join-Path $outDir "CLIProxyAPI-Manager.exe"
|
||||
$outPath = Join-Path $outDir "ProxyPilot.exe"
|
||||
|
||||
Write-Host "Building CLIProxyAPI Manager (tray)..."
|
||||
Write-Host "Building ProxyPilot (tray)..."
|
||||
Write-Host " out: $outPath"
|
||||
|
||||
Push-Location $repoRoot
|
||||
@@ -25,4 +25,3 @@ try {
|
||||
}
|
||||
|
||||
Write-Host "Done."
|
||||
|
||||
|
||||
@@ -24,16 +24,16 @@ if (-not (Test-Path -LiteralPath $iexpress)) {
|
||||
$distRoot = Join-Path $repoRoot "dist"
|
||||
Ensure-Dir $distRoot
|
||||
|
||||
$staging = Join-Path $distRoot "CLIProxyAPI-Manager-Staging"
|
||||
$staging = Join-Path $distRoot "ProxyPilot-Staging"
|
||||
if (Test-Path -LiteralPath $staging) { Remove-Item -Recurse -Force -LiteralPath $staging }
|
||||
Ensure-Dir $staging
|
||||
|
||||
# Payload files
|
||||
$mgrExe = Join-Path $repoRoot "bin\\CLIProxyAPI-Manager.exe"
|
||||
$mgrExe = Join-Path $repoRoot "bin\\ProxyPilot.exe"
|
||||
$srvExe = Join-Path $repoRoot "bin\\cliproxyapi-latest.exe"
|
||||
$cfgSrc = Join-Path $repoRoot "config.example.yaml"
|
||||
|
||||
Copy-Item -Force -LiteralPath $mgrExe -Destination (Join-Path $staging "CLIProxyAPI-Manager.exe")
|
||||
Copy-Item -Force -LiteralPath $mgrExe -Destination (Join-Path $staging "ProxyPilot.exe")
|
||||
Copy-Item -Force -LiteralPath $srvExe -Destination (Join-Path $staging "cliproxyapi-latest.exe")
|
||||
if (Test-Path -LiteralPath $cfgSrc) {
|
||||
Copy-Item -Force -LiteralPath $cfgSrc -Destination (Join-Path $staging "config.example.yaml")
|
||||
@@ -44,12 +44,12 @@ $runCmd = Join-Path $staging "run-manager.cmd"
|
||||
@"
|
||||
@echo off
|
||||
setlocal
|
||||
start """" ""%~dp0CLIProxyAPI-Manager.exe""
|
||||
start """" ""%~dp0ProxyPilot.exe""
|
||||
"@ | Set-Content -Encoding ASCII -LiteralPath $runCmd
|
||||
|
||||
# IExpress configuration (SED)
|
||||
$sedPath = Join-Path $staging "package.sed"
|
||||
$outExe = Join-Path $distRoot "CLIProxyAPI-Manager-Setup.exe"
|
||||
$outExe = Join-Path $distRoot "ProxyPilot-Setup.exe"
|
||||
if (Test-Path -LiteralPath $outExe) { Remove-Item -Force -LiteralPath $outExe }
|
||||
|
||||
$escapedStaging = $staging.Replace("\", "\\")
|
||||
@@ -72,7 +72,7 @@ InstallPrompt=
|
||||
DisplayLicense=
|
||||
FinishMessage=
|
||||
TargetName=$escapedOutExe
|
||||
FriendlyName=CLIProxyAPI Manager
|
||||
FriendlyName=ProxyPilot
|
||||
AppLaunched=run-manager.cmd
|
||||
PostInstallCmd=
|
||||
AdminQuietInstCmd=
|
||||
@@ -81,12 +81,12 @@ SourceFiles=SourceFiles
|
||||
[SourceFiles]
|
||||
SourceFiles0=$escapedStaging
|
||||
[SourceFiles0]
|
||||
%FILE0%=CLIProxyAPI-Manager.exe
|
||||
%FILE0%=ProxyPilot.exe
|
||||
%FILE1%=cliproxyapi-latest.exe
|
||||
%FILE2%=config.example.yaml
|
||||
%FILE3%=run-manager.cmd
|
||||
[Strings]
|
||||
FILE0=CLIProxyAPI-Manager.exe
|
||||
FILE0=ProxyPilot.exe
|
||||
FILE1=cliproxyapi-latest.exe
|
||||
FILE2=config.example.yaml
|
||||
FILE3=run-manager.cmd
|
||||
@@ -108,4 +108,3 @@ if (-not (Test-Path -LiteralPath $outExe)) {
|
||||
|
||||
Write-Host "Built installer:"
|
||||
Write-Host " $outExe"
|
||||
|
||||
|
||||
@@ -9,21 +9,20 @@ $repoRoot = Get-RepoRoot
|
||||
|
||||
& (Join-Path $repoRoot "scripts\\windows\\build-cliproxytray.ps1")
|
||||
|
||||
$distDir = Join-Path $repoRoot "dist\\CLIProxyAPI-Manager"
|
||||
$distDir = Join-Path $repoRoot "dist\\ProxyPilot"
|
||||
if (Test-Path -LiteralPath $distDir) {
|
||||
Remove-Item -Recurse -Force -LiteralPath $distDir
|
||||
}
|
||||
New-Item -ItemType Directory -Path $distDir | Out-Null
|
||||
|
||||
$exeSrc = Join-Path $repoRoot "bin\\CLIProxyAPI-Manager.exe"
|
||||
$exeDst = Join-Path $distDir "CLIProxyAPI-Manager.exe"
|
||||
$exeSrc = Join-Path $repoRoot "bin\\ProxyPilot.exe"
|
||||
$exeDst = Join-Path $distDir "ProxyPilot.exe"
|
||||
Copy-Item -Force -LiteralPath $exeSrc -Destination $exeDst
|
||||
|
||||
$zipPath = Join-Path $repoRoot "dist\\CLIProxyAPI-Manager.zip"
|
||||
$zipPath = Join-Path $repoRoot "dist\\ProxyPilot.zip"
|
||||
if (Test-Path -LiteralPath $zipPath) { Remove-Item -Force -LiteralPath $zipPath }
|
||||
|
||||
Compress-Archive -Path $distDir\\* -DestinationPath $zipPath
|
||||
|
||||
Write-Host "Packaged:"
|
||||
Write-Host " $zipPath"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user