Skip to content

Commit df26fb5

Browse files
authored
docs: Update migration docs for removed read_ingredient_file (#242)
* fix: Initial commit * fix: Refactor and rewrite * fix: Update the docs * fix: docs * fix: docs * fix: docs * fix: Docs 3 * fix: Further wording fixes * fix: Further wording fixes * fix: Further wording fixes * fix: Further wording fixes
1 parent c71197c commit df26fb5

6 files changed

Lines changed: 1822 additions & 91 deletions

File tree

‎docs/faqs.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,5 +121,5 @@ These file-based functions not attached to an API-exposed object, `read_file`, `
121121
| Removed function | Equivalent |
122122
| --- | --- |
123123
| `read_file(path)` | `Reader::from_asset(ctx, format, stream)` then `Reader::json()`. Pull binary resources with `Reader::get_resource(uri, dest)`. |
124-
| `read_ingredient_file(path, data_dir)` | `Builder::add_ingredient(ingredient_json, source_path)`, which adds ingredients to the active Builder. To recover the formed ingredient JSON (if needed) and its resources, archive the working store and read it back, or move the ingredient with the dedicated `write_ingredient_archive` / `add_ingredient_from_archive` APIs. See [Extracting ingredients from a working store](selective-manifests.md#extracting-ingredients-from-a-working-store). |
124+
| `read_ingredient_file(path, data_dir)` | `Builder::add_ingredient(ingredient_json, source_path)`, which adds ingredients to the active Builder. To recover the formed ingredient JSON (if needed) and its resources, archive the working store and read it back, or move the ingredient with the dedicated `write_ingredient_archive` / `add_ingredient_from_archive` APIs. There is no single-call replacement; but the full behavior (extract the ingredient JSON, thumbnail, and manifest_data to a directory, then reuse that directory to sign an asset using a Builder) can be reimplemented as shown in examples from [Migrating from `read_ingredient_file`](selective-manifests.md#migrating-from-read_ingredient_file). See also [Extracting ingredients from a working store](selective-manifests.md#extracting-ingredients-from-a-working-store). |
125125
| `sign_file(src, dst, manifest, SignerInfo*, data_dir)` | `Builder::sign(source_path, dest_path, signer)` with a `Signer`. |

0 commit comments

Comments
 (0)