Skip to content

Commit 67ea973

Browse files
authored
chore: Add generic plugin package release artifact (#1184)
* chore: Add generic plugin package release artifact * Update changelog * Formatting
1 parent 2f27620 commit 67ea973

File tree

2 files changed

+24
-4
lines changed

2 files changed

+24
-4
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@
22

33
## Unreleased
44

5+
> [!NOTE]
6+
> Starting with this release, a generic package is published alongside the engine-specific ones.
7+
> It omits the `EngineVersion` key in the plugin descriptor so it can be used in licensee engine builds without triggering warnings or requiring manual changes.
8+
>
9+
> Note that the generic package uses the `TObjectPtr` syntax which is only available in UE5.
10+
> If you are using UE 4.27 or earlier, it’s better to continue using the corresponding engine-specific package as removing the version key manually will be the simpler approach.
11+
512
### Features
613

714
- Add plugin setting to opt out of automatic Crash Reporter context propagation ([#1178](https://github.com/getsentry/sentry-unreal/pull/1178))

scripts/packaging/pack.ps1

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,30 @@ function packFiles()
2626

2727
$pluginSpec = Get-Content (Get-PluginSpecPath)
2828
$pluginVersion = Get-PluginVersion
29+
2930
$engineVersions = Get-Content "$PSScriptRoot/engine-versions.txt"
31+
$engineVersions += "generic"
32+
3033
foreach ($engineVersion in $engineVersions)
3134
{
32-
$packageName = "sentry-unreal-$pluginVersion-engine$engineVersion.zip"
33-
Write-Host "Creating a release package for Unreal $engineVersion as $packageName"
35+
# Adding the EngineVersion key to Sentry.uplugin may trigger warnings in licensee engine builds (https://github.com/getsentry/sentry-unreal/issues/811)
36+
# Therefore, we include this key only in engine-specific packages.
37+
# The generic package omits it so that users can download a ready-to-use artifact without having to remove the key manually for that use-case.
3438

3539
$newPluginSpec = $pluginSpec
3640

37-
# Adding EngineVersion key may cause warnings when using package in licensee engine builds (https://github.com/getsentry/sentry-unreal/issues/811)
41+
if ($engineVersion -ne "generic")
42+
{
43+
$packageName = "sentry-unreal-$pluginVersion-engine$engineVersion.zip"
44+
Write-Host "Creating a release package for Unreal $engineVersion as $packageName"
3845

39-
$newPluginSpec = @($pluginSpec[0..0]) + @(' "EngineVersion" : "' + $engineVersion + '.0",') + @($pluginSpec[1..($pluginSpec.count)])
46+
$newPluginSpec = @($pluginSpec[0..0]) + @(' "EngineVersion" : "' + $engineVersion + '.0",') + @($pluginSpec[1..($pluginSpec.count)])
47+
}
48+
else
49+
{
50+
$packageName = "sentry-unreal-$pluginVersion.zip"
51+
Write-Host "Creating a generic release package as $packageName"
52+
}
4053

4154
# Handle platform name difference for UE 4.27
4255
if ($engineVersion -eq "4.27")

0 commit comments

Comments
 (0)