Skip to content

Commit

Permalink
🔧 Acorn v3 (Laravel 9.x), drop PHP 7.4 support (#3097)
Browse files Browse the repository at this point in the history
Co-authored-by: retlehs <[email protected]>
Co-authored-by: Brandon Nifong <[email protected]>
  • Loading branch information
3 people authored Jan 27, 2023
1 parent 523c99c commit 03386f0
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
if: "!contains(github.event.head_commit.message, '[ci skip]')"
strategy:
matrix:
php: ['7.4', '8.0', '8.1']
php: ['8.0', '8.1']

steps:
- name: Checkout the project
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Make sure all dependencies have been installed before moving on:

- [Acorn](https://docs.roots.io/acorn/2.x/installation/) v2
- [WordPress](https://wordpress.org/) >= 5.9
- [PHP](https://secure.php.net/manual/en/install.php) >= 7.4.0 (with [`php-mbstring`](https://secure.php.net/manual/en/book.mbstring.php) enabled)
- [PHP](https://secure.php.net/manual/en/install.php) >= 8.0 (with [`php-mbstring`](https://secure.php.net/manual/en/book.mbstring.php) enabled)
- [Composer](https://getcomposer.org/download/)
- [Node.js](http://nodejs.org/) >= 16
- [Yarn](https://yarnpkg.com/en/docs/install)
Expand Down
8 changes: 4 additions & 4 deletions app/Providers/ThemeServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

namespace App\Providers;

use Roots\Acorn\ServiceProvider;
use Roots\Acorn\Sage\SageServiceProvider;

class ThemeServiceProvider extends ServiceProvider
class ThemeServiceProvider extends SageServiceProvider
{
/**
* Register any application services.
Expand All @@ -13,7 +13,7 @@ class ThemeServiceProvider extends ServiceProvider
*/
public function register()
{
//
parent::register();
}

/**
Expand All @@ -23,6 +23,6 @@ public function register()
*/
public function boot()
{
//
parent::boot();
}
}
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
}
},
"require": {
"php": "^7.4|^8.0"
"php": "^8.0"
},
"require-dev": {
"squizlabs/php_codesniffer": "3.7.1"
Expand Down
18 changes: 2 additions & 16 deletions functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@
*/

try {
\Roots\bootloader();
\Roots\bootloader()->boot();
} catch (Throwable $e) {
wp_die(
__('You need to install Acorn to use this theme.', 'sage'),
'',
[
'link_url' => 'https://docs.roots.io/acorn/2.x/installation/',
'link_url' => 'https://roots.io/acorn/docs/installation/',
'link_text' => __('Acorn Docs: Installation', 'sage'),
]
);
Expand All @@ -63,17 +63,3 @@
);
}
});

/*
|--------------------------------------------------------------------------
| Enable Sage Theme Support
|--------------------------------------------------------------------------
|
| Once our theme files are registered and available for use, we are almost
| ready to boot our application. But first, we need to signal to Acorn
| that we will need to initialize the necessary service providers built in
| for Sage when booting.
|
*/

add_theme_support('sage');

0 comments on commit 03386f0

Please sign in to comment.