diff options
author | George Burgess IV <gbiv@google.com> | 2023-02-27 15:52:06 -0700 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2023-03-01 21:31:39 +0000 |
commit | ca8d11c7c270cd579de996d8086073297653cadd (patch) | |
tree | a734cde035d2a3b5ae295e24d6b8d023d9fadf69 /rust_tools/rust_uprev.py | |
parent | 331c0475a38639798af06f20200636faa31ec804 (diff) | |
download | toolchain-utils-ca8d11c7c270cd579de996d8086073297653cadd.tar.gz |
rust_uprev: remove the `copy patches` step
Patches no longer have rust's version in them, so we can safely skip
this step now.
BUG=b:266817148
TEST=Unittests
Change-Id: Ib54b2607f25eed5808cd6c544acc5ca3ce3a12f4
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/4295527
Tested-by: George Burgess <gbiv@chromium.org>
Commit-Queue: George Burgess <gbiv@chromium.org>
Reviewed-by: Bob Haarman <inglorion@chromium.org>
Diffstat (limited to 'rust_tools/rust_uprev.py')
-rwxr-xr-x | rust_tools/rust_uprev.py | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/rust_tools/rust_uprev.py b/rust_tools/rust_uprev.py index 382d991a..5bcb527d 100755 --- a/rust_tools/rust_uprev.py +++ b/rust_tools/rust_uprev.py @@ -332,27 +332,6 @@ def prepare_uprev( return template_version, ebuild_path, bootstrap_version -def copy_patches( - directory: Path, template_version: RustVersion, new_version: RustVersion -) -> None: - patch_path = directory / "files" - prefix = "%s-%s-" % (directory.name, template_version) - new_prefix = "%s-%s-" % (directory.name, new_version) - for f in os.listdir(patch_path): - if not f.startswith(prefix): - continue - logging.info("Copy patch %s to new version", f) - new_name = f.replace(str(template_version), str(new_version)) - shutil.copyfile( - os.path.join(patch_path, f), - os.path.join(patch_path, new_name), - ) - - subprocess.check_call( - ["git", "add", f"{new_prefix}*.patch"], cwd=patch_path - ) - - def create_ebuild( template_ebuild: str, pkgatom: str, new_version: RustVersion ) -> str: @@ -648,10 +627,6 @@ def create_rust_uprev( EBUILD_PREFIX.joinpath("eclass/cros-rustc.eclass"), template_version ), ) - run_step( - "copy patches", - lambda: copy_patches(RUST_PATH, template_version, rust_version), - ) template_host_ebuild = EBUILD_PREFIX.joinpath( f"dev-lang/rust-host/rust-host-{template_version}.ebuild" ) |