From a1cba88b9498e8ef3a5d36b30de7b0f90f5c8d91 Mon Sep 17 00:00:00 2001 From: Joe Date: Sat, 24 Jan 2026 04:41:05 -0600 Subject: [PATCH] Enhance installation script for conditional build modes - Updated the installation script to conditionally handle release builds by enabling debug information in the release profile. - Added logic to copy the PDB file alongside the executable to the installation directory, improving debugging capabilities. --- install.ps1 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/install.ps1 b/install.ps1 index b203f9bb..ad2e4ede 100644 --- a/install.ps1 +++ b/install.ps1 @@ -5,7 +5,11 @@ param([string]$Mode = "release") $InstallDir = "C:\Program Files\Rojo" Set-Location $PSScriptRoot -cargo build "--$Mode" +if ($Mode -eq "release") { + cargo build --release --config "profile.release.debug=true" +} else { + cargo build "--$Mode" +} $Rojo = ".\target\$Mode\rojo.exe" & "$Rojo" build plugin.project.json --plugin Rojo.rbxm if ($LASTEXITCODE -ne 0) { throw "Plugin build failed" } @@ -13,6 +17,7 @@ if ($LASTEXITCODE -ne 0) { throw "Plugin build failed" } gsudo Stop-Process -Name "rojo" -Force -ErrorAction SilentlyContinue gsudo New-Item -ItemType Directory -Path $InstallDir -Force | Out-Null gsudo Copy-Item "$Rojo" "$InstallDir\" +gsudo Copy-Item ".\target\$Mode\rojo.pdb" "$InstallDir\" $MachinePath = [Environment]::GetEnvironmentVariable("Path", "Machine") if ($MachinePath -notlike "*$InstallDir*") {