document delta generation

This commit is contained in:
Daniel Micay 2019-10-08 09:15:37 -04:00
parent cfb7c42fbb
commit c5547e10f8

View File

@ -67,7 +67,12 @@
<li><a href="#upgrading-to-android-10">Upgrading to Android 10</a></li> <li><a href="#upgrading-to-android-10">Upgrading to Android 10</a></li>
</ul> </ul>
</li> </li>
<li><a href="#generating-signed-factory-images-and-full-update-packages">Generating signed factory images and full update packages</a></li> <li>
<a href="#generating-signed-factory-images-and-full-update-packages">Generating signed factory images and full update packages</a>
<ul>
<li><a href="#generating-delta-updates">Generating delta updates</a></li>
</ul>
</li>
<li> <li>
<a href="#prebuilt-code">Prebuilt code</a> <a href="#prebuilt-code">Prebuilt code</a>
<ul> <ul>
@ -546,6 +551,43 @@ cd ../..</pre>
incremental updates from those to the most recent signed <code>target_files</code> incremental updates from those to the most recent signed <code>target_files</code>
zip.</p> zip.</p>
<h3 id="generating-delta-updates">
<a href="#generating-delta-updates">Generating delta updates</a>
</h3>
<p>Incremental updates shipping only the changes between two versions can be generated
as a much more efficient way of shipping updates than a full update package containing
the entire operating system. The GrapheneOS Updater app will automatically use a delta
update if one exists for going directly from the currently installed version to the
latest release. In order to generate a delta update, the original signed target files
package for both the source version and target version are needed. The
<code>script/generate_delta.sh</code> script provides a wrapper script for generating
delta updates by passing the device, source version build number and target version
build number. For example:</p>
<pre>script/generate_delta.sh crosshatch 2019.09.25.00 2019.10.07.21</pre>
<p>The script assumes that the releases are organized in the following directory
structure:</p>
<pre>releases
├── 2019.09.25.00
│   └── release-crosshatch-2019.09.25.00
│      ├── crosshatch-factory-2019.09.25.00.zip
│      ├── crosshatch-factory-2019.09.25.00.zip.sig
│      ├── crosshatch-img-2019.09.25.00.zip
│      ├── crosshatch-ota_update-2019.09.25.00.zip
│      ├── crosshatch-target_files-2019.09.25.00.zip
│      └── crosshatch-testing
└── 2019.10.07.21
└── release-crosshatch-2019.10.07.21
   ├── crosshatch-factory-2019.10.07.21.zip
   ├── crosshatch-factory-2019.10.07.21.zip.sig
   ├── crosshatch-img-2019.10.07.21.zip
   ├── crosshatch-ota_update-2019.10.07.21.zip
   ├── crosshatch-target_files-2019.10.07.21.zip
   └── crosshatch-testing</pre>
<h2 id="prebuilt-code"> <h2 id="prebuilt-code">
<a href="#prebuilt-code">Prebuilt code</a> <a href="#prebuilt-code">Prebuilt code</a>
</h2> </h2>