summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2016-10-03 12:46:14 +0200
committerRemi Collet <fedora@famillecollet.com>2016-10-03 12:46:14 +0200
commitc470e59341977d1cc7ff59dc6452e92437bc23e0 (patch)
tree5f6d484677a84cd0bda90e9227020e7f60fb3b3e
parentfb6123e5e586de2f598a13bebfe3b1415addc770 (diff)
php-phpunit-PHPUnit: 5.5.6
-rwxr-xr-xmakesrc.sh31
-rw-r--r--php-phpunit-PHPUnit.spec15
2 files changed, 41 insertions, 5 deletions
diff --git a/makesrc.sh b/makesrc.sh
new file mode 100755
index 0000000..34cf5ce
--- /dev/null
+++ b/makesrc.sh
@@ -0,0 +1,31 @@
+#!/bin/bash
+
+NAME=$(basename $PWD)
+OWNER=$(sed -n '/^%global gh_owner/{s/.* //;p}' $NAME.spec)
+PROJECT=$(sed -n '/^%global gh_project/{s/.* //;p}' $NAME.spec)
+MAJOR=$(sed -n '/^%global major/{s/.* //;p}' $NAME.spec)
+MINOR=$(sed -n '/^%global minor/{s/.* //;p}' $NAME.spec)
+VERSION=$MAJOR.$MINOR
+COMMIT=$(sed -n '/^%global gh_commit/{s/.* //;p}' $NAME.spec)
+SHORT=${COMMIT:0:7}
+
+echo -e "\nCreate git snapshot\nName=$NAME, Owner=$OWNER, Project=$PROJECT, Version=$VERSION\n"
+
+echo "Cloning..."
+rm -rf $PROJECT-$COMMIT
+git clone https://github.com/$OWNER/$PROJECT.git $PROJECT-$COMMIT
+
+echo "Getting commit..."
+pushd $PROJECT-$COMMIT
+rm -r build
+git checkout $COMMIT
+cp composer.json ../composer.json
+popd
+
+echo "Archiving..."
+tar czf $NAME-$VERSION-$SHORT.tgz --exclude .git $PROJECT-$COMMIT
+
+echo "Cleaning..."
+rm -rf $PROJECT-$COMMIT
+
+echo "Done."
diff --git a/php-phpunit-PHPUnit.spec b/php-phpunit-PHPUnit.spec
index 4096835..9a1dd30 100644
--- a/php-phpunit-PHPUnit.spec
+++ b/php-phpunit-PHPUnit.spec
@@ -8,7 +8,7 @@
#
# Please, preserve the changelog entries
#
-%global gh_commit a57126dc681b08289fef6ac96a48e30656f84350
+%global gh_commit 146e0fe0bb7f44d1cefade0c93e86fe0b206dd79
#global gh_date 20150927
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner sebastianbergmann
@@ -17,7 +17,7 @@
%global pear_name PHPUnit
%global pear_channel pear.phpunit.de
%global major 5.5
-%global minor 5
+%global minor 6
%global specrel 1
Name: php-phpunit-PHPUnit
@@ -28,10 +28,11 @@ Summary: The PHP Unit Testing framework
Group: Development/Libraries
License: BSD
URL: https://github.com/%{gh_owner}/%{gh_project}
-Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz
+Source0: %{gh_commit}/%{name}-%{version}-%{gh_short}.tgz
+Source1: makesrc.sh
# Autoload template, from version 3.7
-Source1: %{gh_project}-5.4.0-Autoload.php.in
+Source2: %{gh_project}-5.4.0-Autoload.php.in
# Fix command for autoload
Patch0: %{gh_project}-rpm.patch
@@ -175,7 +176,7 @@ mv src PHPUnit
%build
%{_bindir}/phpab \
--output PHPUnit/Autoload.php \
- --template %{SOURCE1} \
+ --template %{SOURCE2} \
PHPUnit
%{_bindir}/phpab \
@@ -233,6 +234,10 @@ fi
%changelog
+* Mon Oct 3 2016 Remi Collet <remi@fedoraproject.org> - 5.5.6-1
+- Update to 5.5.6
+- sources from a git snapshot
+
* Wed Sep 21 2016 Remi Collet <remi@fedoraproject.org> - 5.5.5-1
- Update to 5.5.5