Skip to content

Commit eb9c8e8

Browse files
committed
move samples in to package folder before packing
1 parent d9ab449 commit eb9c8e8

File tree

3 files changed

+23
-4
lines changed

3 files changed

+23
-4
lines changed

.yamato/wrench/package-pack-jobs.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ package_pack_-_inputsystem:
1616
- command: 7z x -aoa wrench-localapv.zip
1717
- command: pip install semver requests --index-url https://artifactory-slo.bf.unity3d.com/artifactory/api/pypi/pypi/simple
1818
- command: python PythonScripts/print_machine_info.py
19+
- command: move /Y .\Assets\Samples .\Packages\com.unity.inputsystem
20+
- command: move /Y .\Assets\Samples.meta .\Packages\com.unity.inputsystem
1921
- command: upm-ci package pack --package-path Packages/com.unity.inputsystem
2022
- command: cp upm-ci~/packages/packages.json upm-ci~/packages/com.unity.inputsystem_packages.json
2123
after:

.yamato/wrench/wrench_config.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@
44
"packages": {
55
"com.unity.inputsystem": {
66
"directory": "Packages/com.unity.inputsystem/",
7-
"prePackCommands": [],
7+
"prePackCommands": [
8+
"move /Y .\\Assets\\Samples .\\Packages\\com.unity.inputsystem",
9+
"move /Y .\\Assets\\Samples.meta .\\Packages\\com.unity.inputsystem"
10+
],
811
"preTestCommands": {
912
"MacOS": [],
1013
"Ubuntu": [],

Tools/CI/Settings/InputSystemSettings.cs

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
using RecipeEngine.Api.Settings;
1+
using RecipeEngine.Api.Commands;
2+
using RecipeEngine.Api.Settings;
23
using RecipeEngine.Modules.Wrench.Models;
34
using RecipeEngine.Modules.Wrench.Settings;
45

@@ -14,7 +15,20 @@ public class InputSystemSettings : AnnotatedSettingsBase
1415
{
1516
{
1617
"com.unity.inputsystem",
17-
new PackageOptions() { ReleaseOptions = new ReleaseOptions() { IsReleasing = true } }
18+
new PackageOptions()
19+
{
20+
ReleaseOptions = new ReleaseOptions() { IsReleasing = true },
21+
PackJobOptions = new PackJobOptions()
22+
{
23+
PrePackCommands = new List<Command>()
24+
{
25+
// We keep the samples in Assets/ as they otherwise won't get imported and you can't
26+
// really work with them. Move them into the package for when we pack the package.
27+
new Command("move /Y .\\Assets\\Samples .\\Packages\\com.unity.inputsystem"),
28+
new Command("move /Y .\\Assets\\Samples.meta .\\Packages\\com.unity.inputsystem"),
29+
}
30+
}
31+
}
1832
}
1933
};
2034

@@ -24,7 +38,7 @@ public InputSystemSettings()
2438
PackagesRootPaths,
2539
PackageOptions,
2640
useLocalPvpExemptions: true
27-
);
41+
);
2842

2943
Wrench.PvpProfilesToCheck = new HashSet<string>() { "supported" };
3044
}

0 commit comments

Comments
 (0)