Skip to content

Commit 7bed678

Browse files
committed
version 2.4.5.18
1: fix spinlock panic for ios15 arm64e devices 2: support tweak injection for WebContent process on ios16 more info: https://github.com/roothide/Dopamine2-roothide/releases/tag/18
1 parent ae0db14 commit 7bed678

File tree

10 files changed

+48
-100
lines changed

10 files changed

+48
-100
lines changed

.github/workflows/roothide.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,14 @@ jobs:
6969
for ((i=0; i<$itemcount; i++)); do if [ "$(plutil -extract items.$i.headerCellClass raw ./Application/Dopamine/UI/Settings/Credits.plist)" = "DOCreditsCell" ]; then DOCreditsCellIndex=$i; break; fi; done;
7070
plutil -insert items.$DOCreditsCellIndex.names -xml "<dict><key>name</key><string>${{ github.actor }}</string><key>link</key><string>https://github.com/${{ github.repository }}</string></dict>" -append ./Application/Dopamine/UI/Settings/Credits.plist
7171
gmake -j$(sysctl -n hw.physicalcpu)
72-
TAG=$(git describe --tags --abbrev=0)
73-
mv ./Application/Dopamine.tipa "./Application/roothide-Dopamine2-v${TAG}.tipa"
74-
echo "tag=${TAG}" >> $GITHUB_ENV
72+
VERSION=$(cat ./BaseBin/_external/basebin/.version).$(git rev-parse --short HEAD)
73+
mv ./Application/Dopamine.tipa "./Application/roothide-Dopamine-${VERSION}.tipa"
74+
echo "version=${VERSION}" >> $GITHUB_ENV
7575
7676
- name: Upload Artifact
7777
id: dopamine-latest-upload
7878
uses: actions/upload-artifact@v4
7979
with:
80-
name: roothide-Dopamine2-v${{ env.tag }}.tipa
80+
name: roothide-Dopamine-${{ env.version }}.tipa
8181
path: |
82-
${{ github.workspace }}/Application/roothide-Dopamine2-v${{ env.tag }}.tipa
82+
${{ github.workspace }}/Application/roothide-Dopamine-${{ env.version }}.tipa

Application/Dopamine/Extensions/NSString+Version.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ - (NSInteger)numericalVersionRepresentation
1616
NSArray *components = [self componentsSeparatedByCharactersInSet:[[NSCharacterSet decimalDigitCharacterSet] invertedSet]];
1717

1818
components = [components filteredArrayUsingPredicate:[NSPredicate predicateWithFormat:@"SELF != ''"]];
19-
assert(components.count <= 3);
19+
assert(components.count == 1);
2020

2121
while (components.count < 3)
2222
components = [components arrayByAddingObject:@"0"];

Application/Dopamine/Jailbreak/DOEnvironmentManager.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ - (NSString *)jailbrokenVersion
251251
version = [NSString stringWithContentsOfFile:JBROOT_PATH(@"/basebin/.version") encoding:NSUTF8StringEncoding error:nil];
252252
}];
253253
}];
254-
return version;
254+
return [[version componentsSeparatedByString:@"."] lastObject];
255255
}
256256

257257
- (BOOL)isBootstrapped

Application/Dopamine/UI/DOUIManager.m

Lines changed: 2 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,12 @@ - (NSArray *)getUpdatesInRange:(NSString *)start end:(NSString *)end
6363
return updates;
6464
}
6565

66-
/*
6766
- (NSArray *)getLatestReleases
6867
{
6968
static dispatch_once_t onceToken;
7069
static NSArray *releases;
7170
dispatch_once(&onceToken, ^{
72-
NSURL *url = [NSURL URLWithString:@"https://api.github.com/repos/opa334/Dopamine/releases"];
71+
NSURL *url = [NSURL URLWithString:@"https://api.github.com/repos/roothide/Dopamine2-roothide/releases"];
7372
NSData *data = [NSData dataWithContentsOfURL:url];
7473
if (data) {
7574
NSError *error;
@@ -83,60 +82,6 @@ - (NSArray *)getLatestReleases
8382
});
8483
return releases;
8584
}
86-
*/
87-
- (NSArray *)getLatestReleases
88-
{
89-
static NSLock* reqLock=nil;
90-
static NSArray *releases=nil;
91-
static dispatch_once_t onceToken;
92-
dispatch_once(&onceToken, ^{
93-
reqLock = [NSLock new];
94-
});
95-
96-
[reqLock lock];
97-
98-
if(!releases) {
99-
100-
NSURL *url = [NSURL URLWithString:@"https://api.github.com/repos/roothide/Dopamine2-roothide/tags"];
101-
NSData *data = [NSData dataWithContentsOfURL:url];
102-
if (!data) {
103-
return nil;
104-
}
105-
106-
NSError *error=nil;
107-
NSArray* tags = [NSJSONSerialization JSONObjectWithData:data options:kNilOptions error:&error];
108-
if (error) {
109-
return nil;
110-
}
111-
112-
if(!tags || tags.count==0) {
113-
return nil;
114-
}
115-
116-
NSData* data2 = [NSData dataWithContentsOfURL:[NSURL URLWithString:tags[0][@"commit"][@"url"]]];
117-
if(!data2) {
118-
return nil;
119-
}
120-
121-
NSError *error2=nil;
122-
NSDictionary* commit = [NSJSONSerialization JSONObjectWithData:data2 options:kNilOptions error:&error2];
123-
if(error2) {
124-
return nil;
125-
}
126-
127-
NSMutableDictionary* newcommit = [tags[0] mutableCopy];
128-
newcommit[@"tag_name"] = tags[0][@"name"];
129-
newcommit[@"body"] = commit[@"commit"][@"message"];
130-
newcommit[@"name"] = [NSString stringWithFormat:@"Version %@", newcommit[@"tag_name"]];
131-
newcommit[@"assets"] = @[@{@"browser_download_url":@"https://github.com/roothide/Dopamine2-roothide"}];
132-
releases = @[newcommit.copy];
133-
134-
}
135-
136-
[reqLock unlock];
137-
138-
return releases;
139-
}
14085

14186
- (BOOL)environmentUpdateAvailable
14287
{
@@ -146,7 +91,7 @@ - (BOOL)environmentUpdateAvailable
14691
NSString *jailbrokenVersion = [[DOEnvironmentManager sharedManager] jailbrokenVersion];
14792
NSString *launchedVersion = [self getLaunchedReleaseTag];
14893

149-
return [launchedVersion numericalVersionRepresentation] > [jailbrokenVersion numericalVersionRepresentation];
94+
return [launchedVersion numericalVersionRepresentation] != [jailbrokenVersion numericalVersionRepresentation];
15095
}
15196

15297
- (bool)launchedReleaseNeedsManualUpdate

Application/Dopamine/UI/Update/DOUpdateViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ - (void)viewDidLoad {
138138
}
139139
else
140140
{
141-
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"https://github.com/roothide/Dopamine2-roothide"] options:@{} completionHandler:nil];
141+
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"https://github.com/roothide/Dopamine2-roothide/releases"] options:@{} completionHandler:nil];
142142
}
143143

144144
}] chevron:NO];

Application/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ build/Build/Products/Debug-iphoneos/Dopamine.app: FORCE
2020
xcodebuild -scheme Dopamine -derivedDataPath build -destination 'generic/platform=iOS' CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO GCC_PREPROCESSOR_DEFINITIONS='NIGHTLY=1 COMMIT_HASH=\"$(COMMIT_HASH)\"'
2121
else
2222
build/Build/Products/Debug-iphoneos/Dopamine.app: FORCE
23-
xcodebuild -scheme Dopamine -derivedDataPath build -destination 'generic/platform=iOS' CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO MARKETING_VERSION="$(shell cat ../BaseBin/_external/basebin/.version).$(shell git -C .. describe --tags --abbrev=0 | grep -E '^[0-9]+$$' || echo 0)"
23+
xcodebuild -scheme Dopamine -derivedDataPath build -destination 'generic/platform=iOS' CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO MARKETING_VERSION="$(shell cat ../BaseBin/_external/basebin/.version)"
2424
endif
2525
touch build/Build/Products/Debug-iphoneos/Dopamine.app/Dopamine.roothide
2626
cp -a Dopamine/Resources/*.deb build/Build/Products/Debug-iphoneos/Dopamine.app/

BUILD.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
2+
# How To Build Your Own tipa on github action
3+
4+
fork this repo then goto tab [Actions] -> [All Workflows] -> [build tip file] -> [Run Workflow] to build tipa file.
5+
6+
- step 1: Login your github account and fork this project
7+
8+
![text](/.pictures/m1.png)
9+
![text](/.pictures/m2.png)
10+
11+
12+
- step 2: Goto the github Actions tab of your forked project and run workflow to build tip file
13+
14+
![text](/.pictures/m3.png)
15+
![text](/.pictures/m4.png)
16+
17+
18+
- step 3: Refresh the page and you will see the progress of the build, wait a few minutes
19+
20+
![text](/.pictures/m5.png)
21+
22+
23+
- step 4: when the build is complete, go to the bottom of the build page to download the tipa file.
24+
25+
(***NOTE: The downloaded file is in zip format, you need to unzip it on your device to get the tipa file***)
26+
27+
![text](/.pictures/m6.png)
28+
29+
30+
***and you will get the contributor with your name on Credits***
31+
32+
![text](/.pictures/m7.png)

BaseBin/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ jailbreakd: .build .include libjailbreak
8383
mkdir -p .build
8484
cp -r _external/basebin/* .build
8585
cp _external/basebin/.version .build
86-
echo "$(shell git -C .. describe --tags --abbrev=0 | grep -E '^[0-9]+$$' || echo 0)" > .build/.version
8786

8887
.include:
8988
rm -rf .include

BaseBin/_external/basebin/.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.4.5
1+
2.4.5.18

README.md

Lines changed: 4 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Dopamine2-roothide
1+
# roothide Dopamine 2
22

33
- Document: https://github.com/roothide/Developer
44

@@ -7,37 +7,9 @@
77
- Discord: https://discord.gg/ZvY2Yjw8GA
88

99

10-
# How To Build tipa file
10+
# How To Build
1111

12-
fork this repo then goto tab [Actions] -> [All Workflows] -> [build tip file] -> [Run Workflow] to build tipa file.
12+
- [build your own tipa on github action](BUILD.md).
1313

14-
- step 1: Login your github account and fork this project
14+
- or ref to [.github/workflows/main.yml](.github/workflows/main.yml) if you want to build it on macOS.
1515

16-
![text](/.pictures/m1.png)
17-
![text](/.pictures/m2.png)
18-
19-
20-
- step 2: Goto the github Actions tab of your forked project and run workflow to build tip file
21-
22-
![text](/.pictures/m3.png)
23-
![text](/.pictures/m4.png)
24-
25-
26-
- step 3: Refresh the page and you will see the progress of the build, wait a few minutes
27-
28-
![text](/.pictures/m5.png)
29-
30-
31-
- step 4: when the build is complete, go to the bottom of the build page to download the tipa file.
32-
33-
(***NOTE: The downloaded file is in zip format, you need to unzip it on your device to get the tipa file***)
34-
35-
![text](/.pictures/m6.png)
36-
37-
38-
***and you will get the contributor with your name on Credits***
39-
40-
![text](/.pictures/m7.png)
41-
42-
43-
*ref to build script [.github/workflows/main.yml](.github/workflows/main.yml) if you want to build on macOS.*

0 commit comments

Comments
 (0)