Skip to content

Commit

Permalink
Merge pull request #186 from Realzzz1874/master
Browse files Browse the repository at this point in the history
appt 添加 x64 版本;修改iOS图标文件的校验规则
  • Loading branch information
zakiso authored Mar 7, 2023
2 parents 8fd1607 + aefd7d7 commit bbe43c7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion server/controllers/upload.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ async function extractIpaIcon(filename, guid, team) {
var data = await unzip.Open.buffer(buffer)
await new Promise((resolve, reject) => {
data.files.forEach(file => {
if (file.path.indexOf(iconName + '60x60@2x.png') != -1) {
if (file.path.indexOf(iconName) != -1 && file.path.indexOf(".png") != -1) {
found = true
file.stream()
.pipe(fs.createWriteStream(tmpOut))
Expand Down
Binary file added server/library/apkparser/aapt-osx_64
Binary file not shown.
5 changes: 3 additions & 2 deletions server/library/apkparser/apkparser.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ var parseOutput;
parseApk = function(filename, cb) {
var exeName = null;
if (os.type() === 'Darwin') {
exeName = 'aapt-osx';
// exeName = 'aapt-osx';
exeName = 'aapt-osx_x64'; // macOS High Sierra 10.13.4 及更新的系统需要改成 x64 版本
} else if (os.type() === 'Linux') {
exeName = 'aapt-linux';
} else {
Expand Down Expand Up @@ -44,4 +45,4 @@ parseOutput = function(text, cb) {

parseApk.parseOutput = parseOutput;

module.exports = parseApk;
module.exports = parseApk;

0 comments on commit bbe43c7

Please sign in to comment.