Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to work on device #9

Closed
wants to merge 67 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
0c32df1
Standalone injection with Swift concurrency.
johnno1962 Nov 28, 2022
91f97ee
Update SwiftUI code.
johnno1962 Nov 29, 2022
ce4e7f3
Tighten-up build.
johnno1962 Nov 29, 2022
1ddc331
Re-organise README.
johnno1962 Nov 30, 2022
1ba9e79
Don't use device injection for iOS on Mac.
johnno1962 Dec 7, 2022
709cf92
Update README.md (#431)
vikas171999 Jan 6, 2023
5b6a2d6
Filter out stray carriage return.
johnno1962 Jan 10, 2023
e327dff
Update device injection driections.
johnno1962 Jan 14, 2023
f2810dc
Fixes for ivar offsets & Objective-C on-device injection.
johnno1962 Jan 17, 2023
66bd835
Re-enable injecting getters on device.
johnno1962 Jan 17, 2023
b92af30
Make dlsym() handles non-optional.
johnno1962 Jan 18, 2023
50b9494
Re-enable swizzling getters/setters on device.
johnno1962 Jan 18, 2023
c962d0e
Consolidation of ivar offset code for on-device injection.
johnno1962 Jan 20, 2023
69e0702
Option to initialise class meta-data for on-device injection.
johnno1962 Jan 27, 2023
aceaf62
Format README_Chinese markdown document. (#423)
raykle Jan 29, 2023
375f183
Ignore class references inside comments.
johnno1962 Feb 8, 2023
6ae8c63
Restoration of dlopen() based on-device injection.
johnno1962 Feb 9, 2023
8ec24a3
Cut down chatter and macCatalyst
johnno1962 Feb 10, 2023
55bb2d0
Detect when categories injected.
johnno1962 Feb 24, 2023
2e6a20f
Remove dependency on DLKit.
johnno1962 Feb 28, 2023
120804a
Move away from Objective-C runtime, More use of disk cache.
johnno1962 Mar 13, 2023
583bba7
Per-platform disk caches now that it is used more.
johnno1962 Mar 23, 2023
1e8f43c
Recover working directory.
johnno1962 May 12, 2023
bc97aad
Working directory follow-up.
johnno1962 May 14, 2023
1b86357
Move temporary -filelist to /tmp.
johnno1962 May 15, 2023
c235a15
More escaping edge cases.
johnno1962 May 16, 2023
81d9646
Only compile #if DEBUG || !SWIFT_PACKAGE
johnno1962 May 16, 2023
161878b
Reinstate Bazel.
johnno1962 May 16, 2023
7b0cbe8
Retry if using cached compilation command.
johnno1962 May 17, 2023
02905bf
Tested on Xcode 15.
johnno1962 Jun 6, 2023
975c1c1
Overhaul of README. (#449)
johnno1962 Jun 8, 2023
618d5e2
INJECTION_TRACE, INJECTION_HOST env vars.
johnno1962 Jun 10, 2023
217c9de
INJECTION_REPLAY env var.
johnno1962 Jun 11, 2023
f90378c
New swift-frontend option with Xcode 15.
johnno1962 Jun 14, 2023
276107e
New swift-frontend option revisted
johnno1962 Jun 14, 2023
33e3113
Update HotSwiftUI code.
johnno1962 Jun 14, 2023
4b37b47
Xprobe on device.
johnno1962 Jun 15, 2023
757f8c9
Retry on codesign failure.
johnno1962 Jun 16, 2023
0469832
README Tweaks.
johnno1962 Jun 19, 2023
b3ab34d
XROS
johnno1962 Jun 22, 2023
7a79d58
Tweak code signing.
johnno1962 Jul 13, 2023
44e269e
Xcode 15 adds new preamble.
johnno1962 Jul 23, 2023
5f4205a
Auto-patch to property wrapper.
johnno1962 Jul 26, 2023
26d2b48
Handling Package.swift.
johnno1962 Sep 2, 2023
9c24d2a
Vapor Swift Package projects.
johnno1962 Sep 4, 2023
350b860
Standalone Vapor injection.
johnno1962 Sep 5, 2023
4000eb4
Retry on network error using device injection.
johnno1962 Sep 8, 2023
1c513a1
Make CodeMirror sub-repo of Xprobe.
johnno1962 Sep 8, 2023
8e6a717
Don't code sign iOS simulator, threading.
johnno1962 Sep 8, 2023
1b77a9b
Reorganisation.
johnno1962 Sep 11, 2023
1db8896
Code signing problem.
johnno1962 Sep 12, 2023
f2f9991
Load XCTest libraries only on demand.
johnno1962 Sep 14, 2023
75318df
Remove legacy DerivedData fallback.
johnno1962 Sep 15, 2023
fb9d4e6
Prevent duplicated "cd" commands.
johnno1962 Sep 17, 2023
48b0079
Re-reorganisation
johnno1962 Sep 20, 2023
e4c119f
Relative paths...
johnno1962 Sep 21, 2023
6694629
More DerivedData
johnno1962 Sep 24, 2023
e6dc56d
XCTest feedback.
johnno1962 Sep 26, 2023
9e83efa
xrOS and Swift Macros.
johnno1962 Oct 8, 2023
3dfbd8c
Housekeeping.
johnno1962 Oct 11, 2023
1e591d3
iOS running on Mac.
johnno1962 Oct 12, 2023
7d0b9e9
iOS running on Mac II
johnno1962 Oct 12, 2023
526e779
Filelist/Broadcst (#467)
johnno1962 Nov 17, 2023
b055aa0
Device bundles.
johnno1962 Nov 27, 2023
bbb252f
Simulator bundles too.
johnno1962 Nov 27, 2023
320b035
++Hotreloading.
oryonatan Nov 30, 2023
edf425b
build_bundles: revert to Ben's version.
oryonatan Nov 30, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions InjectionIII.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
BB16654025EC6163001407AE /* Xprobe.mm in Sources */ = {isa = PBXBuildFile; fileRef = BBB64FE91FD583B60020BE47 /* Xprobe.mm */; };
BB16654425ECD828001407AE /* ClientBoot.mm in Sources */ = {isa = PBXBuildFile; fileRef = BB16654325ECD827001407AE /* ClientBoot.mm */; };
BB18D2E8274E1748004BB4A5 /* DynamicCast.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB18D2E7274E1746004BB4A5 /* DynamicCast.swift */; };
BB19058C26D0C59200D57FB7 /* DLKit.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBD0AB3D262F24E4003ED7B1 /* DLKit.swift */; };
BB19058D26D0C62F00D57FB7 /* DLKitC.c in Sources */ = {isa = PBXBuildFile; fileRef = BBD0AB40262F2549003ED7B1 /* DLKitC.c */; };
BB1A84072522703C003873C3 /* macOSInjection.bundle in Resources */ = {isa = PBXBuildFile; fileRef = BBCA02451FB1065D00E45F0F /* macOSInjection.bundle */; };
BB1A840A25227535003873C3 /* SwiftTrace.h in Resources */ = {isa = PBXBuildFile; fileRef = BB6C87C62520D0D2005AFCFC /* SwiftTrace.h */; };
BB1BA90B251DC54100044608 /* SwiftUISupport.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB1BA90A251DC54100044608 /* SwiftUISupport.swift */; };
Expand All @@ -32,8 +30,6 @@
BB4EC3FC244FA3C40079E244 /* RMDeviceController.m in Sources */ = {isa = PBXBuildFile; fileRef = BB4EC3F8244FA3C30079E244 /* RMDeviceController.m */; };
BB4EC3FD244FA3C40079E244 /* RMImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = BB4EC3F9244FA3C40079E244 /* RMImageView.m */; };
BB4EC3FE244FA3C40079E244 /* RMWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = BB4EC3FA244FA3C40079E244 /* RMWindowController.m */; };
BB53B642244FC08F00F006E3 /* RemoteCapture.h in Resources */ = {isa = PBXBuildFile; fileRef = BB4EC3FF244FA42A0079E244 /* RemoteCapture.h */; };
BB53B648244FC32C00F006E3 /* RemoteHeaders.h in Resources */ = {isa = PBXBuildFile; fileRef = BB53B647244FC2F800F006E3 /* RemoteHeaders.h */; };
BB56393C1FD5C25A002FFCEF /* SignerService.m in Sources */ = {isa = PBXBuildFile; fileRef = BB67DBB61FB0D0F2000EAC8A /* SignerService.m */; };
BB6306FE1FCD1A410021D30C /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = BB6306FD1FCD1A410021D30C /* Credits.rtf */; };
BB6446202545831400A83098 /* StringIndex.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB64461F2545831200A83098 /* StringIndex.swift */; };
Expand Down Expand Up @@ -102,6 +98,7 @@
BBCA02621FB1312A00E45F0F /* SimpleSocket.mm in Sources */ = {isa = PBXBuildFile; fileRef = BB67DBB31FB0CDA8000EAC8A /* SimpleSocket.mm */; };
BBCB31C9281677C900081CB6 /* SwiftInterpose.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBCB31C8281677C700081CB6 /* SwiftInterpose.swift */; };
BBD0AB52263298D9003ED7B1 /* SwiftLifetime.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBD0AB51263298D7003ED7B1 /* SwiftLifetime.swift */; };
BBD3B4FA2936552E006E7DB4 /* TupleRegex.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBB2C6FD26FC9C2900E91E67 /* TupleRegex.swift */; };
BBE3B2E72524915A00300BF8 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBE3B2E62524915A00300BF8 /* AppDelegate.swift */; };
BBE3B2E92524916000300BF8 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = BBE3B2E82524916000300BF8 /* Assets.xcassets */; };
BBE3B2EC2524916000300BF8 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = BBE3B2EA2524916000300BF8 /* MainMenu.xib */; };
Expand All @@ -113,6 +110,7 @@
BBE64E5D2524D1B50049B6D4 /* SwiftEval.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB439B8A1FABA65D00B4F50B /* SwiftEval.swift */; };
BBEB704C1FD28C6F00127711 /* XcodeHash.m in Sources */ = {isa = PBXBuildFile; fileRef = BBEB704B1FD28C6F00127711 /* XcodeHash.m */; };
BBF3D62B2851E6DF0070356F /* ReducerInjection.swift in Sources */ = {isa = PBXBuildFile; fileRef = BBF3D62A2851E6DC0070356F /* ReducerInjection.swift */; };
BBFE27EA2B148E7400E47E61 /* copy_bundle.sh in Resources */ = {isa = PBXBuildFile; fileRef = BBFE27E92B148E7400E47E61 /* copy_bundle.sh */; };
BD35949E21A6C5DE0020EB94 /* Vaccine.swift in Sources */ = {isa = PBXBuildFile; fileRef = BD35949D21A6C5DE0020EB94 /* Vaccine.swift */; };
CEC1702A253ED117002E823F /* Experimental.swift in Sources */ = {isa = PBXBuildFile; fileRef = CEC17029253ED117002E823F /* Experimental.swift */; };
/* End PBXBuildFile section */
Expand Down Expand Up @@ -306,7 +304,7 @@
BBCB31C8281677C700081CB6 /* SwiftInterpose.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = SwiftInterpose.swift; path = HotReloading/Sources/HotReloading/SwiftInterpose.swift; sourceTree = SOURCE_ROOT; };
BBCB5BE927E7D849005E8AF6 /* StandaloneInjection.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = StandaloneInjection.swift; path = HotReloading/Sources/HotReloading/StandaloneInjection.swift; sourceTree = SOURCE_ROOT; };
BBD0AB3D262F24E4003ED7B1 /* DLKit.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = DLKit.swift; path = DLKit/Sources/DLKit/DLKit.swift; sourceTree = SOURCE_ROOT; };
BBD0AB3F262F2549003ED7B1 /* fishhook.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fishhook.c; path = DLKit/Sources/DLKitC/fishhook.c; sourceTree = SOURCE_ROOT; };
BBD0AB3F262F2549003ED7B1 /* fishhook.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fishhook.c; path = SwiftTrace/SwiftTraceGuts/fishhook.c; sourceTree = SOURCE_ROOT; };
BBD0AB40262F2549003ED7B1 /* DLKitC.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = DLKitC.c; path = DLKit/Sources/DLKitC/DLKitC.c; sourceTree = SOURCE_ROOT; };
BBD0AB43262F256B003ED7B1 /* DLKitC.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DLKitC.h; path = DLKit/Sources/DLKitC/include/DLKitC.h; sourceTree = SOURCE_ROOT; };
BBD0AB51263298D7003ED7B1 /* SwiftLifetime.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = SwiftLifetime.swift; path = SwiftTrace/SwiftLifetime.swift; sourceTree = "<group>"; };
Expand All @@ -323,6 +321,7 @@
BBEB704A1FD28C6F00127711 /* XcodeHash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XcodeHash.h; sourceTree = "<group>"; };
BBEB704B1FD28C6F00127711 /* XcodeHash.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XcodeHash.m; sourceTree = "<group>"; };
BBF3D62A2851E6DC0070356F /* ReducerInjection.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = ReducerInjection.swift; path = HotReloading/Sources/HotReloading/ReducerInjection.swift; sourceTree = SOURCE_ROOT; };
BBFE27E92B148E7400E47E61 /* copy_bundle.sh */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; path = copy_bundle.sh; sourceTree = "<group>"; };
BD35949D21A6C5DE0020EB94 /* Vaccine.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = Vaccine.swift; path = ../HotReloading/Sources/HotReloading/Vaccine.swift; sourceTree = "<group>"; };
BDB6A7CE21824C800001CF95 /* UserDefaults.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = UserDefaults.h; path = ../HotReloading/Sources/HotReloadingGuts/include/UserDefaults.h; sourceTree = "<group>"; };
CEC17029253ED117002E823F /* Experimental.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = Experimental.swift; path = ../HotReloading/Sources/injectiond/Experimental.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -581,6 +580,7 @@
BBCA02581FB112F500E45F0F /* App.icns */,
BBCA020B1FB0F10400E45F0F /* InjectionIII.entitlements */,
BBA7BE0223473D660067124D /* build_bundles.sh */,
BBFE27E92B148E7400E47E61 /* copy_bundle.sh */,
BBDF943C2349277A00334E08 /* InjectionIII-Bridging-Header.h */,
BB4EC3FF244FA42A0079E244 /* RemoteCapture.h */,
BB53B647244FC2F800F006E3 /* RemoteHeaders.h */,
Expand Down Expand Up @@ -895,10 +895,9 @@
buildActionMask = 2147483647;
files = (
BB1EBC50258EA273001F2AA4 /* fishhook.h in Resources */,
BBFE27EA2B148E7400E47E61 /* copy_bundle.sh in Resources */,
BB1A840A25227535003873C3 /* SwiftTrace.h in Resources */,
BB1A84072522703C003873C3 /* macOSInjection.bundle in Resources */,
BB53B648244FC32C00F006E3 /* RemoteHeaders.h in Resources */,
BB53B642244FC08F00F006E3 /* RemoteCapture.h in Resources */,
BBB64FDE1FD5744A0020BE47 /* XprobeConsole.xib in Resources */,
BBB64FDF1FD5744A0020BE47 /* XprobePluginMenuController.xib in Resources */,
BBB64DDC1FD570220020BE47 /* graph-xdot.gv in Resources */,
Expand Down Expand Up @@ -1082,7 +1081,6 @@
BB16653E25EC5FE0001407AE /* InjectionClient.swift in Sources */,
BBC03BC12625F27C005C1A06 /* UnhidingEval.swift in Sources */,
BBCA02501FB107AF00E45F0F /* SwiftEval.swift in Sources */,
BB19058C26D0C59200D57FB7 /* DLKit.swift in Sources */,
BD35949E21A6C5DE0020EB94 /* Vaccine.swift in Sources */,
BBCA02511FB107AF00E45F0F /* SwiftInjection.swift in Sources */,
BB9642A627E339BE00C61CB7 /* ObjcInjection.swift in Sources */,
Expand All @@ -1091,7 +1089,6 @@
BB16654425ECD828001407AE /* ClientBoot.mm in Sources */,
BB16653F25EC6158001407AE /* Xprobe+Service.mm in Sources */,
BBCA02621FB1312A00E45F0F /* SimpleSocket.mm in Sources */,
BB19058D26D0C62F00D57FB7 /* DLKitC.c in Sources */,
BBBE71BB260652E000F45DE2 /* SweepSeeding.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand All @@ -1102,6 +1099,7 @@
files = (
BBE3B2F2252491BC00300BF8 /* SwiftEval.swift in Sources */,
BBE3B2E72524915A00300BF8 /* AppDelegate.swift in Sources */,
BBD3B4FA2936552E006E7DB4 /* TupleRegex.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -1479,7 +1477,7 @@
INFOPLIST_FILE = InjectionIII/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks";
MACOSX_DEPLOYMENT_TARGET = 10.12;
MARKETING_VERSION = 4.5.3;
MARKETING_VERSION = 4.8.0;
PRODUCT_BUNDLE_IDENTIFIER = com.johnholdsworth.InjectionIII;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand All @@ -1503,7 +1501,7 @@
INFOPLIST_FILE = InjectionIII/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks";
MACOSX_DEPLOYMENT_TARGET = 10.12;
MARKETING_VERSION = 4.5.3;
MARKETING_VERSION = 4.8.0;
PRODUCT_BUNDLE_IDENTIFIER = com.johnholdsworth.InjectionIII;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1150"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "BBCA01FD1FB0F10300E45F0F"
BuildableName = "InjectionIII.app"
BlueprintName = "InjectionIII"
ReferencedContainer = "container:InjectionIII.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "BBCA01FD1FB0F10300E45F0F"
BuildableName = "InjectionIII.app"
BlueprintName = "InjectionIII"
ReferencedContainer = "container:InjectionIII.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "BBCA01FD1FB0F10300E45F0F"
BuildableName = "InjectionIII.app"
BlueprintName = "InjectionIII"
ReferencedContainer = "container:InjectionIII.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
2 changes: 1 addition & 1 deletion InjectionIII/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleVersion</key>
<string>7584</string>
<string>7918</string>
<key>LSApplicationCategoryType</key>
<string>public.app-category.developer-tools</string>
<key>LSMinimumSystemVersion</key>
Expand Down
22 changes: 22 additions & 0 deletions InjectionIII/copy_bundle.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash -x
#
# copy_bundle.sh
# InjectionIII
#
# Copies injection bundle for on-device injection.
# Thanks @oryonatan
#
if [ "$CONFIGURATION" == "Debug" ]; then
RESOURCES="$(dirname "$0")"
if [ "$PLATFORM_NAME" == "iphonesimulator" ]; then
BUNDLE=${1:-iOSInjection}
else
BUNDLE=${1:-maciOSInjection}
fi
COPY="$CODESIGNING_FOLDER_PATH/iOSInjection.bundle"
rsync -a "$RESOURCES/$BUNDLE.bundle"/* "$COPY/" &&
/usr/libexec/PlistBuddy -c "Add :UserHome string $HOME" "$COPY/Info.plist" &&
codesign -f --sign "$EXPANDED_CODE_SIGN_IDENTITY" --timestamp\=none --preserve-metadata\=identifier,entitlements,flags --generate-entitlement-der "$COPY/Frameworks/SwiftTrace.framework/SwiftTrace" &&
codesign -f --sign "$EXPANDED_CODE_SIGN_IDENTITY" --timestamp\=none --preserve-metadata\=identifier,entitlements,flags --generate-entitlement-der "$COPY" &&
defaults write com.johnholdsworth.InjectionIII "$PROJECT_FILE_PATH" $EXPANDED_CODE_SIGN_IDENTITY
fi
Loading
Loading