logiguard fork v3: full patch set on verified 8c74db0 tree
Includes prior-session patches (carry forward so the app compiles): - crates/gpui/build.rs: cross-compile manifest fix - crates/gpui/src/platform.rs: PlatformWindow::activate_with_token trait method - crates/gpui/src/window.rs: Window::activate_with_token public API - crates/gpui_linux/src/linux/wayland/window.rs: WaylandWindow::activate_with_token + activate() keyboard-serial fix Plus the focus-serial fix: - serial.rs: SerialKind::KeyboardEnter - client.rs: store wl_keyboard.enter serial; latest_serial_of() Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
56
script/generate-licenses.ps1
Normal file
56
script/generate-licenses.ps1
Normal file
@@ -0,0 +1,56 @@
|
||||
$ErrorActionPreference = 'Stop'
|
||||
$PSNativeCommandUseErrorActionPreference = $true
|
||||
|
||||
$CARGO_ABOUT_VERSION="0.8.2"
|
||||
$outputFile=$args[0] ? $args[0] : "$(Get-Location)/assets/licenses.md"
|
||||
$templateFile="script/licenses/template.md.hbs"
|
||||
|
||||
New-Item -Path "$outputFile" -ItemType File -Value "" -Force
|
||||
|
||||
@(
|
||||
"# ###### THEME LICENSES ######\n"
|
||||
Get-Content assets/themes/LICENSES
|
||||
"\n# ###### ICON LICENSES ######\n"
|
||||
Get-Content assets/icons/LICENSES
|
||||
"\n# ###### CODE LICENSES ######\n"
|
||||
) | Add-Content -Path $outputFile
|
||||
|
||||
$needsInstall = $false
|
||||
try {
|
||||
$versionOutput = cargo about --version
|
||||
if (-not ($versionOutput -match "cargo-about $CARGO_ABOUT_VERSION")) {
|
||||
$needsInstall = $true
|
||||
} else {
|
||||
Write-Host "cargo-about@$CARGO_ABOUT_VERSION is already installed"
|
||||
}
|
||||
} catch {
|
||||
$needsInstall = $true
|
||||
}
|
||||
|
||||
if ($needsInstall) {
|
||||
Write-Host "Installing cargo-about@$CARGO_ABOUT_VERSION..."
|
||||
cargo install "cargo-about@$CARGO_ABOUT_VERSION"
|
||||
}
|
||||
|
||||
Write-Host "Generating cargo licenses"
|
||||
|
||||
$failFlag = $env:ALLOW_MISSING_LICENSES ? "--fail" : ""
|
||||
$args = @('about', 'generate', $failFlag, '-c', 'script/licenses/zed-licenses.toml', $templateFile, '-o', $outputFile) | Where-Object { $_ }
|
||||
cargo @args
|
||||
|
||||
Write-Host "Applying replacements"
|
||||
$replacements = @{
|
||||
'"' = '"'
|
||||
''' = "'"
|
||||
'=' = '='
|
||||
'`' = '`'
|
||||
'<' = '<'
|
||||
'>' = '>'
|
||||
}
|
||||
$content = Get-Content $outputFile
|
||||
foreach ($find in $replacements.keys) {
|
||||
$content = $content -replace $find, $replacements[$find]
|
||||
}
|
||||
$content | Set-Content $outputFile
|
||||
|
||||
Write-Host "generate-licenses completed. See $outputFile"
|
||||
Reference in New Issue
Block a user