[COPR] Restore dist in Release
This is to fix: WARNING: No disttag found in prebuilt packages INFO: Use --define DISTTAG to set proper dist. e. g. --define DISTTAG fc21. ERROR: 'No disttag in package and no DISTTAG flag. Use --define DISTTAG to set proper dist e. g., --define DISTTAG=fc21.' (logs in /var/lib/copr-rpmbuild/workspace/workdir-wgba9jrq/.cache/fedora-review.log) Also adding option to git_commint_no suppressing new line prevents breaking line in Release tag. Signed-off-by: Przemo Firszt <przemo@firszt.eu>
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
Name: %{name}
|
||||
Epoch: 1
|
||||
Version: 0.19
|
||||
Release: pre_{{{ git_commit_no }}}
|
||||
Release: pre_{{{git_commit_no}}}%{?dist}
|
||||
Summary: A general purpose 3D CAD modeler
|
||||
Group: Applications/Engineering
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
function git_commit_no {
|
||||
commits=$(curl -s 'https://api.github.com/repos/FreeCAD/FreeCAD/compare/120ca87015...master' | grep "ahead_by" | sed -s 's/ //g' | sed -s 's/"ahead_by"://' | sed -s 's/,//')
|
||||
echo $((commits + 1))
|
||||
echo -n $((commits + 1))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user