You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.2 KiB
38 lines
1.2 KiB
6 years ago
|
From 0dc9fc182edf0791ca697f587e48dd39948d63c1 Mon Sep 17 00:00:00 2001
|
||
|
From: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||
|
Date: Mon, 10 Sep 2018 23:37:40 +0200
|
||
|
Subject: [PATCH 1/7] name spec/patch_file by real crate name
|
||
|
|
||
|
When renaming using patch file, we really want to change file names too.
|
||
|
|
||
|
Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||
|
---
|
||
|
rust2rpm/__main__.py | 4 ++--
|
||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||
|
|
||
|
diff --git a/rust2rpm/__main__.py b/rust2rpm/__main__.py
|
||
|
index dc78828..1575ce6 100644
|
||
|
--- a/rust2rpm/__main__.py
|
||
|
+++ b/rust2rpm/__main__.py
|
||
|
@@ -218,7 +218,7 @@ def main():
|
||
|
template = JINJA_ENV.get_template("main.spec")
|
||
|
|
||
|
if args.patch and len(diff) > 0:
|
||
|
- patch_file = "{}-fix-metadata.diff".format(crate)
|
||
|
+ patch_file = "{}-fix-metadata.diff".format(metadata.name)
|
||
|
else:
|
||
|
patch_file = None
|
||
|
|
||
|
@@ -269,7 +269,7 @@ def main():
|
||
|
kwargs["license"] = license
|
||
|
kwargs["license_comments"] = comments
|
||
|
|
||
|
- spec_file = "rust-{}.spec".format(crate)
|
||
|
+ spec_file = "rust-{}.spec".format(metadata.name)
|
||
|
spec_contents = template.render(md=metadata, patch_file=patch_file, **kwargs)
|
||
|
if args.stdout:
|
||
|
print("# {}".format(spec_file))
|
||
|
--
|
||
|
2.19.1
|
||
|
|