Skip to content

Commit

Permalink
Merge pull request #1656 from wielebenwir/enhancement-fix-autoloader
Browse files Browse the repository at this point in the history
Fix autoloading behaviour to enable local development.
  • Loading branch information
datengraben authored Nov 25, 2024
2 parents 54a917f + 0dc0c19 commit 951e369
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 53 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,7 @@ jobs:
- name: Run test suite
run: |
composer dump-autoload -o
curl -ksSfL -o ~/phpunit-9.phar https://phar.phpunit.de/phpunit-9.phar
php ~/phpunit-9.phar
php vendor/bin/phpunit
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
Expand All @@ -90,4 +89,4 @@ jobs:
GH_REPO: ${{ github.repository }}
GH_TOKEN: ${{ github.token }}
GH_DEBUG: api
run: gh workflow run rerun.yml -r ${{ github.head_ref || github.ref_name }} -F run_id=${{ github.run_id }}
run: gh workflow run rerun.yml -r ${{ github.head_ref || github.ref_name }} -F run_id=${{ github.run_id }}
1 change: 1 addition & 0 deletions commonsbooking.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,5 @@
require __DIR__.'/vendor/autoload.php';
require __DIR__.'/vendor/cmb2/cmb2/init.php';
require __DIR__.'/vendor/mustardBees/cmb-field-select2/cmb-field-select2.php';
require __DIR__.'/vendor/ed-itsolutions/cmb2-field-ajax-search/cmb2-field-ajax-search.php';
require_once __DIR__. '/includes/Plugin.php';
15 changes: 7 additions & 8 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,6 @@
}
},
"autoload": {
"files": [
"includes/Shortcodes.php",
"includes/Template.php",
"includes/TemplateParser.php",
"includes/Users.php"
],
"psr-4": {
"CommonsBooking\\": "src/"
}
Expand All @@ -29,12 +23,17 @@
{
"type": "vcs",
"url": "https://github.com/wielebenwir/cmb-field-select2"
},
{
"type": "vcs",
"url": "https://github.com/wielebenwir/cmb2-field-ajax-search"
}

],
"require": {
"php": ">=7.3",
"cmb2/cmb2": "^2.10.1",
"mustardbees/cmb-field-select2": "3.0.4",
"mustardbees/cmb-field-select2": "^3.0.4",
"geocoder-php/nominatim-provider": "^5.7",
"php-http/curl-client": "^2.3",
"nyholm/psr7": "^1.8",
Expand All @@ -45,7 +44,7 @@
"symfony/service-contracts": "^v2.5.2",
"eluceo/ical": "~2.14.0",
"phpmailer/phpmailer": "^6.8.1",
"ed-itsolutions/cmb2-field-ajax-search": "^2.0"
"ed-itsolutions/cmb2-field-ajax-search": "v2.0.1"
},
"require-dev": {
"mockery/mockery": "^1.6.6",
Expand Down
79 changes: 37 additions & 42 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions includes/Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@


$cbPlugin = new Plugin();

require_once __DIR__ . '/Users.php';
require_once __DIR__ . '/TemplateParser.php';
require_once __DIR__ . '/Shortcodes.php';
require_once __DIR__ . '/Template.php';

$cbPlugin->init();
$cbPlugin->initRoutes();
$cbPlugin->initBookingcodes();

0 comments on commit 951e369

Please sign in to comment.