[Android Software/Hacking General [Developers Only]] ipdev:
Hi. :)

You seem to have it correct. :D

If you decide to add the --skip-reboot option the device will be left in bootloader_d since it is the last boot mode of update on newer devices.

So you will want to add a reboot to bootloader line after the update line.

You might also want to keep Windows from closing the command window after the batch script runs.

-- Intermission. --

Before I recommend something I try to test and double check it as much as I can. 🙃

It has been a while since I used Windows and wanted to test a few things.

Took longer than I thought it would. :censored:

After some updates (sdk and platform tools), and installing some new device drivers.

Trusty Windows 7 Pro (dual boot) on my trusty 2013 MackBook Air was ready to go. ;)​

I do not have a 6 Pro [raven] so I just used my 5 [redfin] to test.

I have a 6 [oriole] on order, should be delivered by Monday. 🙏

I edit the update script with Notepad++ since I know it is recommended to use for script files.

It does not include the Windows line ending junk.

This is what I ended up with to do a dirty reflash on my Pixel 5.

Along with keeping the command window open. ;)

Note: For those stumbling across this post.

This is after the initial flash of Android 12 that included disabling verity, verification and wiping user data.​

Modified flash-all.bat

@ECHO OFF
:: Copyright 2012 The Android Open Source Project
::
:: Licensed under the Apache License, Version 2.0 (the "License");
:: you may not use this file except in compliance with the License.
:: You may obtain a copy of the License at
::
::	http://www.apache.org/licenses/LICENSE-2.0
::
:: Unless required by applicable law or agreed to in writing, software
:: distributed under the License is distributed on an "AS IS" BASIS,
:: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
:: See the License for the specific language governing permissions and
:: limitations under the License.

PATH=%PATH%;"%SYSTEMROOT%\System32"
fastboot flash bootloader bootloader-redfin-r3-0.4-7617468.img
fastboot reboot-bootloader
ping -n 5 127.0.0.1 >nul
fastboot flash radio radio-redfin-g7250-00147-210811-b-7631450.img
fastboot reboot-bootloader
ping -n 5 127.0.0.1 >nul
:: fastboot -w update image-redfin-sp1a.211105.003.zip

:: echo Press any key to exit...
:: pause >nul
:: exit

fastboot --disable-verity --disable-verification --skip-reboot update image-redfin-sp1a.211105.003.zip
fastboot reboot-bootloader
ping -n 5 127.0.0.1 >nul
cmd /k

Probably do not need the extra ping but, why not delay a few seconds. :whistle:

Then I just booted (fastboot boot) the magisk patched image (that I already patched while on the November build) and used the Direct install option in the Magisk app to install Magisk.

To close the command window (when I was done with it) a single exit command was all that was need.​

---

As for Magisk.

Since about the start of Android 11, I have had issues patching the new boot image beforehand.

Patching the December boot image while still on the November release for example.

So I generally patch the boot image while I am running the corresponding system (rom build).

Patch the December boot image while running the December release.

Then boot the Magisk patched image to make sure it works and nothing is broken.

If everything is good, I then just use the Direct install option in the Magisk app to install Magisk.

You could reboot to bootloader and then flash boot if you prefer.

Hope it helps more than confuse. 🙃

Cheers. :cowboy: