mirror of
https://github.com/PlayCover/PlayCover.git
synced 2026-04-26 00:05:52 +03:00
[PR #1517] [MERGED] Auto re-sign app on launch #1873
Labels
No labels
UI
app-support
bug
bug
documentation
duplicate
enhancement
game-support
good first issue
help wanted / caution
inactive
invalid
macos-beta
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/PlayCover#1873
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/PlayCover/PlayCover/pull/1517
Author: @XuYicong
Created: 6/16/2024
Status: ✅ Merged
Merged: 8/13/2024
Merged by: @Depal1
Base:
develop← Head:develop📝 Commits (5)
7a0b0e8check Info.plist signature on launch476fc9eAdded PlayApp view state persistence (#1)d37aae0FIxed progress view UId38378fIncluded PlayAppVM.swift in project file2af5192Merge branch 'develop' of github.com:PlayCover/PlayCover into develop📊 Changes
5 files changed (+140 additions, -77 deletions)
View changed files
📝
PlayCover.xcodeproj/project.pbxproj(+4 -0)📝
PlayCover/Model/PlayApp.swift(+6 -4)➕
PlayCover/ViewModel/PlayAppVM.swift(+22 -0)📝
PlayCover/Views/App Views/PlayAppView.swift(+60 -49)📝
PlayCover/Views/Sidebar Views/AppLibraryView.swift(+48 -24)📄 Description
When running
codesign -dvon some game, its signature info would be displayed. If theInfo.plisthas bad signature, a line would beInfo.plist=not bound. If it's good, the line would be likeInfo.plist entries=56. In this way we can quickly check for a signature failure that would lead to anOSStatus-67030error and cause a crash. So we can re-sign the app if such case is detected.The shell command part is working perfectly, but I have some problems regarding SwiftUI and need help.
Now that it would auto re-sign app on launch, a launch could take a long time. Therefore, a progress view is needed to give the user some feedback.


This works perfectly with a
showStartingProgressvariable, but whenisListis changed during starting,showStartingProgressis reset tofalse.I then decide to rely on
app.isStartingand updateshowStartingProgressfrom it, but something I don't understand happens:app.isStartingalso resets tofalse. This not only lead to the not showing of the progress view when switching between List view and Grid view, but also makes the app can be launched multiple times during launching. This seems an existing issue, but it was not severe because launch time was short. But now it becomes severe, I don't know why it would reset and don't know how to fix it.Edit: Thanks to @Wind-Explorer the above issue is fixed.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.