easyci 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/easyci/command/unitydraw.rb +3 -3
- data/lib/easyci/unity_exe_helper.rb +16 -0
- data/lib/easyci/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ad95be0f7bbfcd56c10ee8bb7cc8593b50e169601b2ed7c1f9be37ba8def4cd4
|
4
|
+
data.tar.gz: b1e0b30cb955bf1139c25049d783e1edd56f45743f5e835421f63cab9c048cff
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f835032e51afb9bc6ccf19993a9a933d49827c18a51188502d73c73ac8e26a90f91f21095f0e552c1dde85014ce9812e3375644ab8245dc89d4ec2201055d857
|
7
|
+
data.tar.gz: 4765d4151b5252ba1e6f1cebb1744ff7453acd46876511fb2fa08c5b5ec16c07c0ba257e50d700142da4063e6804a992873cbb125b9ddbd55031b469dde65074
|
@@ -78,14 +78,14 @@ module EasyCI
|
|
78
78
|
unity_path = find_unity_path(runner_dir)
|
79
79
|
puts "运行Unity截图任务..."
|
80
80
|
FileUtils.chdir(runner_dir)
|
81
|
-
system("#{unity_path} -projectPath
|
81
|
+
system("#{unity_path} -projectPath #{runner_dir} -executeMethod -logFile screenshot-log.txt")
|
82
82
|
|
83
83
|
# 压缩截图
|
84
84
|
puts "开始压缩截图..."
|
85
|
-
system("find . -path \"*/Screenshots/*.png\" -exec pngquant --quality=70-95 --ext .png --force {} \\;")
|
85
|
+
system("cd #{runner_dir} && find . -path \"*/Screenshots/*.png\" -exec pngquant --quality=70-95 --ext .png --force {} \\;")
|
86
86
|
# 运行Node脚本(如果需要)
|
87
87
|
puts "运行后处理脚本..."
|
88
|
-
system("docker run --rm -v \"$(pwd):/app\" -w /app node:22.0.0 bash -c \"cd Scripts && yarn install && npx ts-node index.ts\"")
|
88
|
+
system("cd #{runner_dir} && docker run --rm -v \"$(pwd):/app\" -w /app node:22.0.0 bash -c \"cd Scripts && yarn install && npx ts-node index.ts\"")
|
89
89
|
|
90
90
|
end
|
91
91
|
|
@@ -1,6 +1,22 @@
|
|
1
1
|
module EasyCI
|
2
2
|
# UnityExeHelper模块,用于查找和验证Unity可执行文件路径
|
3
3
|
module UnityExeHelper
|
4
|
+
# Unity可执行文件的可能路径 (使用通配符)
|
5
|
+
UNITY_MAC_PATHS = [
|
6
|
+
"/Applications/Unity/Unity.app/Contents/MacOS/Unity",
|
7
|
+
"/Applications/Unity/Hub/Editor/*/Unity.app/Contents/MacOS/Unity"
|
8
|
+
]
|
9
|
+
|
10
|
+
UNITY_WINDOWS_PATHS = [
|
11
|
+
"C:/Program Files/Unity/Editor/Unity.exe",
|
12
|
+
"C:/Program Files/Unity/Hub/Editor/*/Editor/Unity.exe"
|
13
|
+
]
|
14
|
+
|
15
|
+
UNITY_LINUX_PATHS = [
|
16
|
+
"/opt/Unity/Editor/Unity",
|
17
|
+
"/opt/unity/hub/editor/*/Editor/Unity"
|
18
|
+
]
|
19
|
+
|
4
20
|
# 查找Unity可执行文件路径
|
5
21
|
# @param project_path [String] Unity项目路径
|
6
22
|
# @param verbose [Boolean] 是否显示详细信息
|
data/lib/easyci/version.rb
CHANGED