diff options
author | Remi Collet <remi@remirepo.net> | 2021-11-15 08:08:57 +0100 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2021-11-15 08:08:57 +0100 |
commit | 8b36aacec5a0b60ca1ccd431cc54f23bc9372a54 (patch) | |
tree | 9ef36a6ac45c3560aa4afb8c5d26371a8370983b | |
parent | 9a4c97a854b4a6f66c709c404b5a17a5d66d1001 (diff) |
update to 3.1.4
sources from git snapshot
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | composer.json | 2 | ||||
-rwxr-xr-x | makesrc.sh | 28 | ||||
-rw-r--r-- | php-sebastian-exporter3.spec | 45 |
4 files changed, 62 insertions, 15 deletions
@@ -1,5 +1,7 @@ +clog package-*.xml *.tgz +*.tar.bz2 *.tar.gz *.tar.xz *.tar.xz.asc diff --git a/composer.json b/composer.json index 50e3be7..e57ca15 100644 --- a/composer.json +++ b/composer.json @@ -36,7 +36,7 @@ "sebastian/recursion-context": "^3.0" }, "require-dev": { - "phpunit/phpunit": "^6.0", + "phpunit/phpunit": "^8.5", "ext-mbstring": "*" }, "autoload": { diff --git a/makesrc.sh b/makesrc.sh new file mode 100755 index 0000000..4190c13 --- /dev/null +++ b/makesrc.sh @@ -0,0 +1,28 @@ +#!/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) +VERSION=$(sed -n '/^Version:/{s/.* //;p}' $NAME.spec) +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 +git checkout $COMMIT +cp composer.json ../composer.json +popd + +echo "Archiving..." +tar czf $NAME-$VERSION-$SHORT.tgz --exclude-vcs --exclude tools $PROJECT-$COMMIT + +echo "Cleaning..." +rm -rf $PROJECT-$COMMIT + +echo "Done." diff --git a/php-sebastian-exporter3.spec b/php-sebastian-exporter3.spec index 743e042..8e57474 100644 --- a/php-sebastian-exporter3.spec +++ b/php-sebastian-exporter3.spec @@ -1,18 +1,20 @@ # remirepo/fedora spec file for php-sebastian-exporter3 # -# Copyright (c) 2013-2019 Remi Collet +# Copyright (c) 2013-2021 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # %global bootstrap 0 -%global gh_commit 6b853149eab67d4da22291d36f5b0631c0fd856e +%global gh_commit 0c32ea2e40dbf59de29f3b49bf375176ce7dd8db %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner sebastianbergmann %global gh_project exporter %global pk_vendor sebastian %global pk_project %{gh_project} +%global ns_vendor SebastianBergmann +%global ns_project Exporter %global major 3 %global php_home %{_datadir}/php %global pear_name Exporter @@ -23,26 +25,31 @@ %global with_tests %{?_without_tests:0}%{!?_without_tests:1} %endif +# NOTICE: used by phpunit 6, 7 and 8 + Name: php-%{pk_vendor}-%{pk_project}%{major} -Version: 3.1.3 +Version: 3.1.4 Release: 1%{?dist} -Summary: Export PHP variables for visualization +Summary: Export PHP variables for visualization, version %{major} License: BSD URL: https://github.com/%{gh_owner}/%{gh_project} -Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{name}-%{version}-%{gh_short}.tar.gz +Source0: %{name}-%{version}-%{gh_short}.tgz +Source1: makesrc.sh BuildArch: noarch BuildRequires: php(language) >= 7.0 BuildRequires: php-fedora-autoloader-devel >= 1.0.0 %if %{with_tests} # from composer.json, "require-dev": { -# "phpunit/phpunit": "^6.0", +# "phpunit/phpunit": "^8.5", # "ext-mbstring": "*" -BuildRequires: phpunit6 +BuildRequires: phpunit8 BuildRequires: php-mbstring +# remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 BuildRequires: (php-composer(%{pk_vendor}/recursion-context) >= 3.0 with php-composer(%{pk_vendor}/recursion-context) < 4) +# remirepo:3 %else BuildRequires: php-sebastian-recursion-context3 %endif @@ -52,8 +59,10 @@ BuildRequires: php-sebastian-recursion-context3 # "php": ">=7.0", # "sebastian/recursion-context": "^3.0" Requires: php(language) >= 7.0 +# remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 Requires: (php-composer(%{pk_vendor}/recursion-context) >= 3.0 with php-composer(%{pk_vendor}/recursion-context) < 4) +# remirepo:3 %else Requires: php-sebastian-recursion-context3 %endif @@ -82,13 +91,13 @@ phpab --template fedora --output src/autoload.php src # Rely on include_path as in PHPUnit dependencies cat <<EOF | tee -a src/autoload.php // Dependency' autoloader -require_once 'SebastianBergmann/RecursionContext3/autoload.php'; +require_once '%{php_home}/%{ns_vendor}/RecursionContext3/autoload.php'; EOF %install -mkdir -p %{buildroot}%{php_home}/SebastianBergmann -cp -pr src %{buildroot}%{php_home}/SebastianBergmann/Exporter%{major} +mkdir -p %{buildroot}%{php_home}/%{ns_vendor} +cp -pr src %{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}%{major} %if %{with_tests} @@ -98,10 +107,10 @@ touch vendor/autoload.php : Run upstream test suite ret=0 -for cmd in php php72 php73 php74 php80; do +for cmd in php php73 php74 php80 php81; do if which $cmd; then - %{_bindir}/php -d include_path=.:%{buildroot}%{_datadir}/php:%{_datadir}/php \ - %{_bindir}/phpunit6 --verbose || ret=1 + %{_bindir}/php -d auto_prepend_file=%{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}%{major}/autoload.php \ + %{_bindir}/phpunit8 --verbose || ret=1 fi done exit $ret @@ -109,14 +118,22 @@ exit $ret %files +# remirepo:1 %{!?_licensedir:%global license %%doc} %license LICENSE %doc README.md %doc composer.json -%{php_home}/SebastianBergmann/Exporter%{major} +%{php_home}/%{ns_vendor}/%{ns_project}%{major} %changelog +* Mon Nov 15 2021 Remi Collet <remi@remirepo.net> - 3.1.4-1 +- update to 3.1.4 +- sources from git snapshot + +* Wed Mar 10 2021 Remi Collet <remi@remirepo.net> - 3.1.3-2 +- switch to phpunit8 + * Mon Nov 30 2020 Remi Collet <remi@remirepo.net> - 3.1.3-1 - update to 3.1.3 (no change) |