summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmakesrc.sh28
-rw-r--r--php-ocramius-proxy-manager-rpm.patch20
-rw-r--r--php-ocramius-proxy-manager.spec6
3 files changed, 51 insertions, 3 deletions
diff --git a/makesrc.sh b/makesrc.sh
new file mode 100755
index 0000000..ab1375c
--- /dev/null
+++ b/makesrc.sh
@@ -0,0 +1,28 @@
+#!/bin/bash
+
+NAME=$(basename $PWD)
+OWNER=$(sed -n '/^%global github_owner/{s/.* //;p}' $NAME.spec)
+PROJECT=$(sed -n '/^%global github_name/{s/.* //;p}' $NAME.spec)
+VERSION=$(sed -n '/^%global github_version/{s/.* //;p}' $NAME.spec)
+COMMIT=$(sed -n '/^%global github_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
+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-ocramius-proxy-manager-rpm.patch b/php-ocramius-proxy-manager-rpm.patch
new file mode 100644
index 0000000..2d5f7d1
--- /dev/null
+++ b/php-ocramius-proxy-manager-rpm.patch
@@ -0,0 +1,20 @@
+diff -up src/ProxyManager/Version.php.rpm src/ProxyManager/Version.php
+--- src/ProxyManager/Version.php.rpm 2016-06-29 16:37:55.000000000 +0200
++++ src/ProxyManager/Version.php 2016-06-29 16:38:44.000000000 +0200
+@@ -20,8 +20,6 @@ declare(strict_types=1);
+
+ namespace ProxyManager;
+
+-use PackageVersions\Versions;
+-
+ /**
+ * Version class - to be adjusted when a new release is created.
+ *
+@@ -47,6 +45,6 @@ final class Version
+ */
+ public static function getVersion() : string
+ {
+- return Versions::getVersion('ocramius/proxy-manager');
++ return '@VERSION@@@COMMIT@';
+ }
+ }
diff --git a/php-ocramius-proxy-manager.spec b/php-ocramius-proxy-manager.spec
index 61975b7..fc0bde3 100644
--- a/php-ocramius-proxy-manager.spec
+++ b/php-ocramius-proxy-manager.spec
@@ -12,7 +12,7 @@
%global github_owner Ocramius
%global github_name ProxyManager
-%global github_version 2.0.0
+%global github_version 2.0.2
%global github_commit 001e730968f17cb36816ad68914994341d16e029
%global github_short %(c=%{github_commit}; echo ${c:0:7})
@@ -144,8 +144,8 @@ rm -rf %{buildroot}
%changelog
-* Wed Jun 29 2016 Remi Collet <remi@fedoraproject.org> - 2.0.0-1
-- update to 2.0.0
+* Wed Jun 29 2016 Remi Collet <remi@fedoraproject.org> - 2.0.2-1
+- update to 2.0.2
- raise dependency on php 7.0.7
- raise dependency on zendframework/zend-code 3.0