summary is like description, but not multiline
Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
parent
1282937913
commit
e880b5031d
1 changed files with 13 additions and 1 deletions
|
@ -71,7 +71,12 @@ TEMPLATE = """# Generated by rust2rpm
|
||||||
Name: {{ name }}
|
Name: {{ name }}
|
||||||
Version: {{ md.version }}
|
Version: {{ md.version }}
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: {{ md.description|default("# FIXME") }}
|
{% if md.description is none %}
|
||||||
|
Summary: # FIXME
|
||||||
|
{% else %}
|
||||||
|
{% set description_lines = md.description.split("\n") %}
|
||||||
|
Summary: {{ description_lines|join(" ")|trim }}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
License: {{ md.license|default("# FIXME") }}
|
License: {{ md.license|default("# FIXME") }}
|
||||||
URL: https://crates.io/crates/{{ md.name }}
|
URL: https://crates.io/crates/{{ md.name }}
|
||||||
|
@ -118,7 +123,14 @@ Conflicts: {{ con }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
%description {{ name_devel }}
|
%description {{ name_devel }}
|
||||||
|
{% if md.description is none %}
|
||||||
%{summary}.
|
%{summary}.
|
||||||
|
{% else %}
|
||||||
|
{{ md.description|wordwrap|trim }}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
This package contains library source intended for building other packages
|
||||||
|
which use %{crate} from crates.io.
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
%prep
|
%prep
|
||||||
|
|
Loading…
Reference in a new issue