Skip to content

Commit

Permalink
Update for 3GS 3.1.x
Browse files Browse the repository at this point in the history
- should fix issues like #397
- users need to do the jailbreak and hacktivate after the restore though
  • Loading branch information
LukeZGD committed Mar 2, 2024
1 parent d059301 commit d77d424
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions restore.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1720,11 +1720,7 @@ ipsw_preference_set() {
return
fi

if [[ $device_target_vers == "3.1"* && $device_proc != 1 &&
$device_target_powder != 1 && $device_type != "iPod2,1" ]]; then
#log "Jailbreak Option is always enabled for 3.1.x ($device_target_vers)"
ipsw_jailbreak=1
elif [[ -z $ipsw_jailbreak && $ipsw_canjailbreak == 1 ]]; then
if [[ -z $ipsw_jailbreak && $ipsw_canjailbreak == 1 ]]; then
input "Jailbreak Option"
print "* When this option is enabled, your device will be jailbroken on restore."
print "* I recommend to enable this option to have the jailbreak and Cydia pre-installed."
Expand Down Expand Up @@ -1758,10 +1754,6 @@ ipsw_preference_set() {
ipsw_hacktivate=
fi
echo
elif [[ $ipsw_jailbreak != 1 ]] &&
[[ $device_type == "iPhone1"* || $device_type == "iPhone2,1" ]]; then
log "Hacktivate option is not available. Jailbreak option must be enabled"
echo
fi

case $device_type in
Expand Down Expand Up @@ -4483,12 +4475,18 @@ device_ramdisk() {
$scp -P $ssh_port $jelbrek/$untether [email protected]:/mnt1
# 3.1.3-4.1 untether needs to be extracted early (before data partition is mounted)
case $vers in
4.1 | 4.0* | 3.1* )
4.1 | 4.0* )
untether="${device_type}_${build}.tar"
log "Extracting $untether"
$ssh -p $ssh_port [email protected] "tar -xvf /mnt1/$untether -C /mnt1; rm /mnt1/$untether"
;;
esac
# Do not extract untether for 3GS 3.1.x
if [[ $vers == "3.1"* && $device_type != "iPhone2,1" ]]; then
untether="${device_type}_${build}.tar"
log "Extracting $untether"
$ssh -p $ssh_port [email protected] "tar -xvf /mnt1/$untether -C /mnt1; rm /mnt1/$untether"
fi
log "Mounting data partition"
$ssh -p $ssh_port [email protected] "mount.sh pv"
case $vers in
Expand Down

0 comments on commit d77d424

Please sign in to comment.