## START: Set by rpmautospec ## (rpmautospec version 0.7.3) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 3; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec Name: timew Version: 1.7.1 Release: %autorelease Summary: Timewarrior tracks and reports time # SPDX License: MIT URL: https://timewarrior.net/ # Do not use github tag archives # They do not contain the libshared git submodule Source0: https://github.com/GothenburgBitFactory/timewarrior/releases/download/v%{version}/%{name}-%{version}.tar.gz Source1: README.Fedora # updated bash completion from https://raw.githubusercontent.com/lauft/timew-bashcompletion/refs/heads/master/timew Source2: timew-bash-completion BuildRequires: cmake gcc-c++ BuildRequires: rubygem-asciidoctor %description Timewarrior is a time tracking utility that offers simple stopwatch features as well as sophisticated calendar-base backfill, along with flexible reporting. It is a portable, well supported and very active, Open Source project. Please read the /usr/share/doc/timew/README.Fedora file on using the included extensions. %prep %autosetup cp -v %{SOURCE1} . cp -v %{SOURCE2} completion/timew-completion.bash chmod -x doc/holidays/* for lib in doc/holidays/*; do sed '1{\@^#!/usr/bin/env python@d}' $lib > $lib.new && touch -r $lib $lib.new && mv $lib.new $lib done for lib in ext/*; do sed "s@^#!/usr/bin/env python3@#!%{python3}@" $lib > $lib.new && touch -r $lib $lib.new && mv $lib.new $lib done # Install themes in _datadir instead of _docdir sed -i 's|DESTINATION.*|DESTINATION ${SHARE_INSTALL_PREFIX}/timew/themes/)|' doc/themes/CMakeLists.txt %build %cmake -DTIMEW_BINDIR=%{_bindir} -DTIMEW_DOCDIR=%{_pkgdocdir} -DTIMEW_MAN1DIR=%{_mandir}/man1/ -DTIMEW_MAN7DIR=%{_mandir}/man7/ %cmake_build %install %cmake_install # move extensions to datadir and keep shebang install -m 0755 -d $RPM_BUILD_ROOT/%{_libdir}/%{name}/ mv $RPM_BUILD_ROOT/%{_pkgdocdir}/ext $RPM_BUILD_ROOT/%{_libdir}/%{name}/ -v chmod +x $RPM_BUILD_ROOT/%{_libdir}/%{name}/ext/* # Not needed rm -f $RPM_BUILD_ROOT/%{_docdir}/%{name}/INSTALL # same as license rm -f $RPM_BUILD_ROOT/%{_docdir}/%{name}/LICENSE # Install Fedora readme file mv -v README.Fedora $RPM_BUILD_ROOT/%{_pkgdocdir}/ # Install bash completion file install -m 0755 completion/timew-completion.bash -DT $RPM_BUILD_ROOT/%{bash_completions_dir}/timew install -m 0755 completion/timew.fish -DT $RPM_BUILD_ROOT/%{fish_completions_dir}/timew.fish %check # Run tests make test %{_smp_mflags} %files %license LICENSE %{_bindir}/%{name} %{_datadir}/%{name} %{_libdir}/%{name} %{_mandir}/man1/%{name}* %{_mandir}/man7/%{name}* %{_pkgdocdir}/ %{bash_completions_dir} %{fish_completions_dir} %changelog ## START: Generated by rpmautospec * Thu Nov 14 2024 Ankur Sinha (Ankur Sinha Gmail) - 1.7.1-3 - fix: include latest bash-completion script * Tue Nov 12 2024 Ankur Sinha (Ankur Sinha Gmail) - 1.7.1-2 - feat: remove uneeded patch (rhbz#2258657) * Tue Nov 12 2024 Packit - 1.7.1-1 - [packit] 1.7.1 upstream release - Resolves rhbz#2258657 * Sat Jul 20 2024 Fedora Release Engineering - 1.7.0-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Sat Jan 27 2024 Fedora Release Engineering - 1.7.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Tue Jan 09 2024 Ankur Sinha (Ankur Sinha Gmail) - 1.7.0-2 - fix: revert completion changes that break tag completion * Sun Dec 24 2023 Packit - 1.7.0-1 - [packit] 1.7.0 upstream release - Resolves rhbz#2255777 * Mon Sep 18 2023 Ankur Sinha (Ankur Sinha Gmail) - 1.6.0-1 - feat: update to 1.6.0 (fixes rh#2239442) * Mon Sep 18 2023 Ankur Sinha (Ankur Sinha Gmail) - 1.5.0-4 - chore: add packit * Sat Jul 22 2023 Fedora Release Engineering - 1.5.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Fri May 19 2023 Ankur Sinha (Ankur Sinha Gmail) - 1.5.0-2 - fix: correctly install extensions with shebangs and as executables for this, they've been moved to /usr/lib64/timew/, since in /usr/share/, they can't be executable etc. * Thu May 18 2023 Ankur Sinha (Ankur Sinha Gmail) - 1.5.0-1 - feat: update to 1.5.0 (fixes rhbz#2184536) * Sat Jan 21 2023 Fedora Release Engineering - 1.4.3-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Sat Jul 23 2022 Fedora Release Engineering - 1.4.3-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Sat Jan 22 2022 Fedora Release Engineering - 1.4.3-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Fri Jul 23 2021 Fedora Release Engineering - 1.4.3-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Thu Jun 17 2021 Ankur Sinha - 1.4.3-1 - Update to latest release - include tests - add bash completion * Wed Jan 27 2021 Fedora Release Engineering - 1.4.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Mon Aug 31 2020 Ankur Sinha - 1.4.2-1 - Update to latest release * Wed Jul 29 2020 Fedora Release Engineering - 1.3.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Tue Apr 21 2020 Aniket Pradhan - 1.3.0-1 - Version update to 1.3.0 * Fri Jan 31 2020 Fedora Release Engineering - 1.2.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Mon Nov 25 2019 Ankur Sinha - 1.2.0-1 - Update to 1.2.0 * Tue Oct 01 2019 Ankur Sinha - 1.1.1-5 - Add Readme: https://bugzilla.redhat.com/show_bug.cgi?id=1631025 * Sat Jul 27 2019 Fedora Release Engineering - 1.1.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Sun Feb 03 2019 Fedora Release Engineering - 1.1.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild * Sat Jul 14 2018 Fedora Release Engineering - 1.1.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild * Mon Mar 05 2018 Ankur Sinha - 1.1.1-1 - Update to latest upstream release * Fri Feb 09 2018 Fedora Release Engineering - 1.0.0-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild * Wed Jan 03 2018 Ankur Sinha - 1.0.0-3 - Add missing buildrequires * Wed Dec 07 2016 Ankur Sinha - 1.0.0-2 - Put files in the right place * Wed Dec 07 2016 Ankur Sinha - 1.0.0-1 - Initial rpmbuild ## END: Generated by rpmautospec