[OnePlus 2 Original Android Development] anupritaisno1:
Step 4: erase everything will fail

Explanation: you ran the commands and mounted an image file in /data and you are about to erase data. This will not be possible

You should first wipe everything and then run the commands

If you ignore the fakecache, the ROM will fail to flash with the error "failed to update system image"

Switching to other custom ROMs is slightly tricky but possible

You'll find the stock oos firmware in the firmware folder and a recovery.img

Flash that recovery.img file and then flash your other ROM

Backup your internal storage as the new ROM won't be able to decrypt data

(Note that you can just flash a forced encryption disabler to avoid encryption completely)

Now go to wipe > format data > type yes and confirm the format

The cache partition was used as vendor so wipe that from advanced wipe

Now your new ROM should be booting. You can replace the recovery with official TWRP after it boots

If you used recovery-vendor.img or built glassrom yourself, you'll have to flash the firmware file from recovery. It is recommended that you use one of my built recoveries and also tick zip file signature verification before flashing the firmware file. The stock oos firmware is in the firmware folder. Zip file signature verification will fail on the official recovery so you can use the sha512sum for confirmation

Incremental OTA mechanism is almost the same as stock OOS. The only difference is that glassrom's patcher is block-level while oos' patcher is file-level. While they are different, both require an unmodified system partition. Basically, you grab yourself the OTA from the full folder and then download incremental OTAs until you reach the target that you want to update the system to

Check: spanna's thread on the op2 forum for oxygenos mirrors has all the information you'd need about flashing incremental OTAs

Note that block based and file based are slightly different

Block based blindly moves blocks of data around as the script tells it to until the target system partition is reached

File based mounts the filesystem and patches individual files until something that looks like the target system partition is reached

Block based is more consistent:

Imagine you want to copy a book

A photocopy printed by a printer should very well do, right?

But is it exactly the same as the original? No

That's file based OTAs oos uses

Now imagine if you took atoms exactly the same as those forming the book and arranged them exactly as they were in the original.

That's block based OTAs glassrom uses

Anyway, if you're interested in incremental OTAs, give that thread by spanna a read

Do note that incremental OTAs are not for convenience. Rather, they are a last resort when you absolutely cannot download the whole ROM. That is also the reason flashing them proves to be a little tricky. There is no difference at all between using a full OTA vs an incremental. The result will be exactly the same

If you go the incremental OTA route, please learn how to use the backup and restore zips from tools correctly otherwise you'll accidentally boot without gapps and a factory reset might be required to be able to use gapps again. Be careful