build nano-default-editor by default only on fedora
Red Hat is not going to maintain the nano-default-editor subpackage in RHEL.
This commit is contained in:
parent
def6c06d12
commit
324d3109a0
18
nano.spec
18
nano.spec
@ -1,7 +1,14 @@
|
||||
# build nano-default-editor by default only on fedora
|
||||
%if 0%{?fedora}
|
||||
%bcond_without default_editor
|
||||
%else
|
||||
%bcond_with default_editor
|
||||
%endif
|
||||
|
||||
Summary: A small text editor
|
||||
Name: nano
|
||||
Version: 5.7
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
License: GPLv3+
|
||||
URL: https://www.nano-editor.org
|
||||
Source: https://www.nano-editor.org/dist/latest/%{name}-%{version}.tar.xz
|
||||
@ -26,6 +33,7 @@ Conflicts: filesystem < 3
|
||||
%description
|
||||
GNU nano is a small and friendly text editor.
|
||||
|
||||
%if %{with default_editor}
|
||||
%package default-editor
|
||||
Summary: Sets GNU nano as the default editor
|
||||
Requires: nano = %{version}-%{release}
|
||||
@ -37,6 +45,7 @@ BuildArch: noarch
|
||||
%description default-editor
|
||||
This package ensures the EDITOR shell variable
|
||||
is set in common shells to GNU nano.
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%autosetup -S git
|
||||
@ -73,10 +82,12 @@ rm -rf %{buildroot}%{_datadir}/nano/extra
|
||||
|
||||
%find_lang %{name}
|
||||
|
||||
%if %{with default_editor}
|
||||
# install nano-default-editor snippets
|
||||
install -Dpm 0644 %{SOURCE11} %{buildroot}%{_sysconfdir}/profile.d/%{basename:%{S:11}}
|
||||
install -Dpm 0644 %{SOURCE12} %{buildroot}%{_sysconfdir}/profile.d/%{basename:%{S:12}}
|
||||
install -Dpm 0644 %{SOURCE13} %{buildroot}%{_datadir}/fish/vendor_conf.d/%{basename:%{S:13}}
|
||||
%endif
|
||||
|
||||
%files -f build/%{name}.lang
|
||||
%doc AUTHORS COPYING ChangeLog INSTALL NEWS README THANKS TODO
|
||||
@ -88,14 +99,19 @@ install -Dpm 0644 %{SOURCE13} %{buildroot}%{_datadir}/fish/vendor_conf.d/%{basen
|
||||
%{_infodir}/nano.info*
|
||||
%{_datadir}/nano
|
||||
|
||||
%if %{with default_editor}
|
||||
%files default-editor
|
||||
%dir %{_sysconfdir}/profile.d
|
||||
%config(noreplace) %{_sysconfdir}/profile.d/nano-default-editor.*
|
||||
%dir %{_datadir}/fish/vendor_conf.d
|
||||
%{_datadir}/fish/vendor_conf.d/nano-default-editor.fish
|
||||
%endif
|
||||
|
||||
|
||||
%changelog
|
||||
* Wed May 05 2021 Kamil Dudka <kdudka@redhat.com> - 5.7-2
|
||||
- build nano-default-editor by default only on fedora
|
||||
|
||||
* Thu Apr 29 2021 Kamil Dudka <kdudka@redhat.com> - 5.7-1
|
||||
- new upstream release
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user