%define prerelease c5b73d348500e127fc50788ee93ef5a6f740cc96 %define import_path github.com/ActiveState/tail %define gopath %{_libdir}/golang %define gosrc %{gopath}/src/%{import_path} %define shortcommit %(c=%{prerelease}; echo ${c:0:7}) Summary: Go package striving to emulate the features of the tail program Name: golang-ActiveState-tail Version: 0.20131114 Release: %mkrel 2 License: BSD Group: Development/Other Url: https://%{import_path} Source0: https://%{import_path}/archive/%{prerelease}.tar.gz Provides: golang(%{import_path}) = %{version}-%{release} %description A Go package striving to emulate the features of the BSD tail program Tail comes with full support for truncation/move detection as it is designed to work with log rotation tools. %prep %setup -q -n tail-%{prerelease} %build %install mkdir -p %{buildroot}%{gosrc} cp -av * %{buildroot}%{gosrc}/ rm -f %{buildroot}%{gosrc}/LICENSE.txt rm -f %{buildroot}%{gosrc}/README.md rm -f %{buildroot}%{gosrc}/CHANGES.md %files %doc LICENSE.txt %doc README.md %doc CHANGES.md %{gosrc}/*