%define debug_package %nil %define pkgname CryptoARMGOST %define _optdir /opt Name: etcdmanager Version: 1.2.0 Release: 1 Summary: A cross-platform GUI and ETCD client URL: https://etcdmanager.io Source0: https://github.com/i-Cell-Mobilsoft-Open-Source/etcdmanager/archive/%{version}/%{name}-%{version}.tar.gz Source1000: %{name}.rpmlintrc License: MIT Group: Development/Other BuildRequires: npm BuildRequires: yarn BuildRequires: imagemagick %description This is a free, cross-platform ETCD v3 client and GUI. The goal of the project is twofold: - Provide an efficient, modern GUI for desktop (Windows, Linux, Mac), mobile (iOS and Android) and web. - Cover all ETCD functionality. Anything you can do with etcdctl, you should be able to do with this tool as well. This app should be useful for simple and power users alike. %prep %setup -q %build yarn yarn run electron:build:linux %install install -d %{buildroot}%{_optdir}/%{name} %ifarch x86_64 cp -a dist_electron/linux-unpacked/* %{buildroot}%{_optdir}/%{name} %else cp -a dist_electron/linux--ia32-unpacked/* %{buildroot}%{_optdir}/%{name} %endif # install binary wrapper mkdir -p %{buildroot}%{_bindir} cat > %{buildroot}%{_bindir}/%{name} << EOF #!/bin/bash cd %{_optdir}/%{name} ./etcd-manager EOF chmod 755 %{buildroot}%{_bindir}/%{name}* # install menu entry mkdir -p %{buildroot}%{_datadir}/applications/ cat > %{buildroot}%{_datadir}/applications/%{name}.desktop << EOF [Desktop Entry] Name=ETCD manager Comment=GUI manager for ETCD Exec=%{name} Icon=%{name} Terminal=false Type=Application StartupNotify=true Categories=Network; EOF # install menu icons pushd build_files for N in 16 22 24 32 48 128 256; do install -d %{buildroot}%{_iconsdir}/hicolor/${N}x${N}/apps convert -resize ${N}x${N} icon.png %{buildroot}%{_iconsdir}/hicolor/${N}x${N}/apps/%{name}.png done popd %files %doc README.md LICENSE %{_bindir}/%{name} %{_datadir}/applications/%{name}.desktop %{_iconsdir}/hicolor/* %{_optdir}/%{name}/*