Skip to content

Commit

Permalink
Draft: debgu
Browse files Browse the repository at this point in the history
  • Loading branch information
theofidry committed Oct 18, 2023
1 parent 3831987 commit 89e87b6
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/phar-debug.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: PHAR DEBUG

on:
push:
branches: [ "main" ]
pull_request: ~

permissions:
contents: read

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Install dependencies
run: composer install --prefer-dist --no-progress

- name: Dump env
run: bin/box composer:check-version

- name: Dump env
run: php bin/box composer:check-version
11 changes: 11 additions & 0 deletions src/Console/Command/Composer/ComposerCheckVersion.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
use Fidry\Console\ExitCode;
use Fidry\Console\Input\IO;
use KevinGH\Box\Composer\ComposerOrchestrator;
use function ini_get;
use function KevinGH\Box\check_php_settings;

/**
* @private
Expand All @@ -42,8 +44,17 @@ public function getConfiguration(): Configuration

protected function orchestrate(ComposerOrchestrator $composerOrchestrator, IO $io): int
{
check_php_settings($io);
$composerOrchestrator->checkVersion();

if (!class_exists('Phar', false)) {
dd([
'get_declared_classes' => get_declared_classes(),
'phpversion' => phpversion(),
'get_loaded_extensions' => get_loaded_extensions(),
]);
}

return ExitCode::SUCCESS;
}
}

0 comments on commit 89e87b6

Please sign in to comment.