blob: d7693093577ebacb573eb7643a25e923a3397405 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
#!/bin/bash
{
pushd $(git rev-parse --show-toplevel)
# Check if setup.py version matches rpm/SPECS/logactio.spec
PYVER=$(awk -F\" '/version =/ { print $2 }' setup.py)
SPECVER=$(awk -F\ '/^Version:/{ print $2}' rpm/SPECS/logactio.spec)
if [ "$PYVER" != "$SPECVER" ]; then
echo "*** ERROR *** Version mismatch between setup.py (v$PYVER) and logactio.spec (v$SPECVER)"
exit 1
fi
python2 setup.py sdist --formats=bztar
cp dist/logactio-*.tar.bz2 rpm/SOURCES
rpmbuild -ba --define "_topdir $(pwd)/rpm" rpm/SPECS/logactio.spec
popd
}
|