crate: ensure metadata is re-loaded after patching Cargo.toml
This commit is contained in:
parent
2e188b55a4
commit
334f043031
1 changed files with 6 additions and 0 deletions
|
@ -175,6 +175,9 @@ def process_project_local(
|
||||||
features = package.get_feature_names()
|
features = package.get_feature_names()
|
||||||
diffs = make_patches(name, package.version, patch, patch_foreign, toml_path, features)
|
diffs = make_patches(name, package.version, patch, patch_foreign, toml_path, features)
|
||||||
|
|
||||||
|
# ensure metadata is up-to-date with changes from patches
|
||||||
|
metadata = Metadata.from_cargo(toml_path)
|
||||||
|
|
||||||
return name, diffs, metadata, doc_files, license_files
|
return name, diffs, metadata, doc_files, license_files
|
||||||
|
|
||||||
|
|
||||||
|
@ -222,6 +225,9 @@ def process_project(
|
||||||
features = package.get_feature_names()
|
features = package.get_feature_names()
|
||||||
diffs = make_patches(name, version, patch, patch_foreign, toml_path, features)
|
diffs = make_patches(name, version, patch, patch_foreign, toml_path, features)
|
||||||
|
|
||||||
|
# ensure metadata is up-to-date with changes from patches
|
||||||
|
metadata = Metadata.from_cargo(toml_path)
|
||||||
|
|
||||||
if store_crate:
|
if store_crate:
|
||||||
copy_target = os.path.join(os.getcwd(), f"{package.name}-{package.version}.crate")
|
copy_target = os.path.join(os.getcwd(), f"{package.name}-{package.version}.crate")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue