try to fix dependency-update workflow

Signed-off-by: Simon L <szaimen@e.mail.de>
This commit is contained in:
Simon L 2023-01-13 13:26:38 +01:00
parent b5f9c860b5
commit 5beb3965bf
3 changed files with 12 additions and 15 deletions

View file

@ -11,24 +11,21 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: nanasess/setup-php@master
- uses: shivammathur/setup-php@v2
with:
php-version: 8.1
extensions: apcu
- name: Run dependency update script
run: |
set -x
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
chmod +x /usr/local/bin/composer
cd ./php
composer update
set +e
ALL_LINES="$(composer outdated | grep -v "psr/container\|^$\|Direct dependencies\|Everything up to date\|Transitive dependencies")"
ALL_LINES="$(composer outdated | grep -v "^$\|php-di/php-di\|psr/container\|Direct dependencies\|Everything up to date\|Transitive dependencies")"
set -e
while [ -n "$ALL_LINES" ]; do
CURRENT_LINE="$(echo "$ALL_LINES" | head -1)"
composer require "$(echo "$CURRENT_LINE" | awk '{print $1}')" "^$(echo "$CURRENT_LINE" | awk '{print $4}')"
composer require "$(echo "$CURRENT_LINE" | awk '{print $1}')" "^$(echo "$CURRENT_LINE" | awk '{print $4}')" --with-all-dependencies
ALL_LINES="$(echo "$ALL_LINES" | sed '1d')"
done
echo "outdated dependencies:

View file

@ -5,17 +5,17 @@
}
},
"require": {
"php": "^8.1",
"php": "8.1.*",
"ext-json": "*",
"ext-sodium": "*",
"ext-curl": "*",
"slim/slim": "4.*",
"php-di/slim-bridge": "^3.1",
"guzzlehttp/guzzle": "^7.3",
"guzzlehttp/psr7": "^2.1.0",
"http-interop/http-factory-guzzle": "^1.2",
"slim/twig-view": "^3.2",
"slim/csrf": "^1.2",
"php-di/slim-bridge": "3.*",
"guzzlehttp/guzzle": "7.*",
"guzzlehttp/psr7": "2.*",
"http-interop/http-factory-guzzle": "1.*",
"slim/twig-view": "3.*",
"slim/csrf": "1.*",
"ext-apcu": "*"
},
"scripts": {

4
php/composer.lock generated
View file

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "7a318338d9e074d6f02e1fba5b3dda24",
"content-hash": "98f51eb5b87b52c52674f503a131269f",
"packages": [
{
"name": "guzzlehttp/guzzle",
@ -1768,7 +1768,7 @@
"prefer-stable": false,
"prefer-lowest": false,
"platform": {
"php": "^8.1",
"php": "8.1.*",
"ext-json": "*",
"ext-sodium": "*",
"ext-curl": "*",