on F32,
date +FORMAT,
date +%Y%m%d_%H%M%S
returns
20200703_105351
as expected.
in an rpm .spec, if I define
%define _build_timestamp %( date +%Y%m%d_%H%M%S )
and _use_ %{_build_timestamp) _anywhere_ else in the spec, at exec of any of rpmbuild/mock
build/@COPR etc, it appears as
'20200703_105351OURCE'
?????
Simply changing the define to
%define _build_timestamp %( date +%Y%m%d_%H%M%S | head -c 15 )
'fixes' the problem, and use of %{_build_timestamp) correctly returns
'20200703_105351'
Is this a bug in rpmbuild or date? Or a problem in my usage?