mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-08 22:33:26 +01:00
[Beta-Suuport]: Added commit ID appending to version if in beta track build
This commit is contained in:
@@ -83,6 +83,13 @@ final class VerifyAppOperation: ResultOperation<Void>
|
||||
{
|
||||
guard let ipaURL = self.context.ipaURL else { throw OperationError.appNotFound(name: app.name) }
|
||||
|
||||
|
||||
// TODO: @mahee96: appVersion is instantiated source info as AppVersion incoming from source json
|
||||
// app is the instantiated ipa downloaded from the specified in the source json in temp dir
|
||||
//
|
||||
// For alpha and beta/nightly releases, the CFBundleShortVersionString which is the
|
||||
// $(MARKETING_VERSION) will be overriden with the commit id before invoking xcode build
|
||||
//
|
||||
try await self.verifyHash(of: app, at: ipaURL, matches: appVersion)
|
||||
try await self.verifyDownloadedVersion(of: app, matches: appVersion)
|
||||
try await self.verifyPermissions(of: app, match: appVersion)
|
||||
|
||||
@@ -46,6 +46,7 @@ public class AppVersion: NSManagedObject, Decodable, Fetchable
|
||||
|
||||
@NSManaged public var appBundleID: String
|
||||
@NSManaged public var sourceID: String?
|
||||
@NSManaged public var isBeta: Bool
|
||||
|
||||
/* Relationships */
|
||||
@NSManaged public private(set) var app: StoreApp?
|
||||
@@ -67,6 +68,7 @@ public class AppVersion: NSManagedObject, Decodable, Fetchable
|
||||
case sha256
|
||||
case minOSVersion
|
||||
case maxOSVersion
|
||||
case isBeta
|
||||
}
|
||||
|
||||
public required init(from decoder: Decoder) throws
|
||||
|
||||
29
Makefile
29
Makefile
@@ -156,7 +156,31 @@ test:
|
||||
|
||||
## -- Building --
|
||||
|
||||
build:
|
||||
# Fetch the latest commit ID if IS_BETA is defined
|
||||
fetch_commit_id:
|
||||
@echo ""
|
||||
@if [ -n "$$IS_BETA" ]; then \
|
||||
echo "'IS_BETA' is defined. Fetching the latest commit ID from HEAD..."; \
|
||||
export COMMIT_ID=$$(git rev-parse --short HEAD); \
|
||||
echo "Commit ID: $$COMMIT_ID"; \
|
||||
else \
|
||||
echo "'IS_BETA' is not defined. Skipping commit ID fetch."; \
|
||||
fi
|
||||
@echo ""
|
||||
|
||||
# Print release type based on the presence of COMMIT_ID
|
||||
print_release_type:
|
||||
@if [ -z "$$COMMIT_ID" ]; then \
|
||||
echo ">>>>>>>> This is STABLE release <<<<<<<<<"; \
|
||||
echo " Using default MARKETING_VERSION from project.pbxproj."; \
|
||||
else \
|
||||
echo ">>>>>>>> This is ALPHA/BETA release for commitID = $$COMMIT_ID <<<<<<<<<"; \
|
||||
echo " Building with MARKETING_VERSION=$$COMMIT_ID"; \
|
||||
fi
|
||||
@echo ""
|
||||
|
||||
# Build target with the fetch_commit_id dependency
|
||||
build: fetch_commit_id print_release_type
|
||||
@xcodebuild -workspace AltStore.xcworkspace \
|
||||
-scheme SideStore \
|
||||
-sdk iphoneos \
|
||||
@@ -166,7 +190,8 @@ build:
|
||||
CODE_SIGNING_ALLOWED=NO \
|
||||
DEVELOPMENT_TEAM=XYZ0123456 \
|
||||
ORG_IDENTIFIER=com.SideStore \
|
||||
DWARF_DSYM_FOLDER_PATH="."
|
||||
DWARF_DSYM_FOLDER_PATH="." \
|
||||
MARKETING_VERSION=$$COMMIT_ID
|
||||
|
||||
fakesign:
|
||||
rm -rf archive.xcarchive/Products/Applications/SideStore.app/Frameworks/AltStoreCore.framework/Frameworks/
|
||||
|
||||
Reference in New Issue
Block a user