v1.1.0 - Update author, include UIExtension features in manual manifest
This commit is contained in:
+15
-6
@@ -109,14 +109,27 @@ if (-not $useManifestGen) {
|
||||
$manifest = [ordered]@{
|
||||
Id = $PluginName
|
||||
Name = "AD Compare"
|
||||
Author = "Jess"
|
||||
Author = "Jess Rogerson"
|
||||
Url = "https://gitea.hideawaygaming.com.au/jessikitty/disco-ad-compare-plugin"
|
||||
Version = $version.ToString()
|
||||
AssemblyPath = "$PluginName.dll"
|
||||
TypeName = "Disco.Plugins.ADCompare.ADComparePlugin"
|
||||
ConfigurationHandlerTypeName = "Disco.Plugins.ADCompare.ConfigurationHandler.ADCompareConfigurationHandler"
|
||||
WebHandlerTypeName = "Disco.Plugins.ADCompare.WebHandler.ADCompareWebHandler"
|
||||
Features = @()
|
||||
Features = @(
|
||||
[ordered]@{
|
||||
Id = "ADCompareDeviceUI"
|
||||
Name = "Device Page - AD Compare"
|
||||
TypeName = "Disco.Plugins.ADCompare.Features.DeviceUIExtension"
|
||||
CategoryName = "User Interface Extensions"
|
||||
},
|
||||
[ordered]@{
|
||||
Id = "ADCompareUserUI"
|
||||
Name = "User Page - AD Compare"
|
||||
TypeName = "Disco.Plugins.ADCompare.Features.UserUIExtension"
|
||||
CategoryName = "User Interface Extensions"
|
||||
}
|
||||
)
|
||||
}
|
||||
$manifest | ConvertTo-Json -Depth 5 | Set-Content (Join-Path $buildOutput "manifest.json") -Encoding UTF8
|
||||
Write-Host "Manual manifest.json created" -ForegroundColor Green
|
||||
@@ -125,7 +138,6 @@ if (-not $useManifestGen) {
|
||||
# --- Package ---
|
||||
Write-Host "`nPackaging .discoPlugin file..." -ForegroundColor Yellow
|
||||
|
||||
# Only include the plugin DLL, PDB, and manifest - nothing else
|
||||
$includeFiles = @("$PluginName.dll", "$PluginName.pdb", "manifest.json")
|
||||
|
||||
if (-not $version) {
|
||||
@@ -135,11 +147,9 @@ if (-not $version) {
|
||||
$packageName = "$PluginName-$($version.ToString()).discoPlugin"
|
||||
$packagePath = Join-Path $PluginDir $packageName
|
||||
|
||||
# Clean old packages
|
||||
Get-ChildItem $PluginDir -Filter "*.discoPlugin" | Remove-Item -Force
|
||||
Get-ChildItem $PluginDir -Filter "*.zip" | Where-Object { $_.Name -like "$PluginName*" } | Remove-Item -Force
|
||||
|
||||
# Build clean temp folder with only plugin files
|
||||
$tempPkg = Join-Path $env:TEMP "discoplugin_$([guid]::NewGuid().ToString('N'))"
|
||||
New-Item -ItemType Directory -Path $tempPkg -Force | Out-Null
|
||||
foreach ($f in $includeFiles) {
|
||||
@@ -154,7 +164,6 @@ Get-ChildItem $tempPkg -File | ForEach-Object {
|
||||
Write-Host " $($_.Name)" -ForegroundColor Gray
|
||||
}
|
||||
|
||||
# Create as .zip first (Compress-Archive requires .zip), then rename
|
||||
$zipPath = Join-Path $PluginDir "$PluginName-$($version.ToString()).zip"
|
||||
Compress-Archive -Path "$tempPkg\*" -DestinationPath $zipPath -Force
|
||||
Rename-Item $zipPath $packageName -Force
|
||||
|
||||
Reference in New Issue
Block a user