Skip to content

Commit 7de6a9f

Browse files
committed
Use master branch of workshop
1 parent 6b0a568 commit 7de6a9f

15 files changed

+463
-66
lines changed

app/bootstrap.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@
1919
throw new RuntimeException('Unable to locate Composer autoloader; please run "composer install".');
2020
}
2121

22+
use PhpSchool\PHP8Appreciate\Exercise\AMatchMadeInHeaven;
2223
use PhpSchool\PhpWorkshop\Application;
2324

2425
$app = new Application('PHP8 Appreciate', __DIR__ . '/config.php');
2526

26-
//$app->addExercise(...);
27-
//$app->addExercise(...);
27+
$app->addExercise(AMatchMadeInHeaven::class);
2828

2929
$art = <<<ART
3030
_ __ _
@@ -37,7 +37,7 @@
3737
ART;
3838

3939
$app->setLogo($art);
40-
$app->setFgColour('green');
41-
$app->setBgColour('black');
40+
$app->setFgColour('white');
41+
$app->setBgColour('61');
4242

4343
return $app;

app/config.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,17 @@
11
<?php
22

3+
use PhpSchool\PHP8Appreciate\AstService;
4+
use PhpSchool\PHP8Appreciate\Exercise\AMatchMadeInHeaven;
5+
use Psr\Container\ContainerInterface;
6+
use function DI\create;
37
use function DI\factory;
48
use function DI\object;
59

610
return [
11+
'basePath' => __DIR__ . '/../',
12+
713
//Define your exercise factories here
14+
AMatchMadeInHeaven::class => function (ContainerInterface $c) {
15+
return new AMatchMadeInHeaven($c->get(PhpParser\Parser::class));
16+
},
817
];

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
],
2222
"require": {
2323
"php": "^8.0",
24-
"php-school/php-workshop": "^3.0"
24+
"php-school/php-workshop": "dev-master"
2525
},
2626
"require-dev": {
2727
"phpunit/phpunit": "^9",
@@ -47,11 +47,11 @@
4747
"unit-tests": "phpunit",
4848
"cs": [
4949
"phpcs src --standard=PSR12",
50-
"phpcs test --standard=PSR12"
50+
"phpcs test --standard=PSR12 --ignore='test/solutions'"
5151
],
5252
"cs-fix": [
5353
"phpcbf src --standard=PSR12 --encoding=UTF-8",
54-
"phpcbf test --standard=PSR12 --encoding=UTF-8"
54+
"phpcbf test --standard=PSR12 --encoding=UTF-8 --ignore='test/solutions'"
5555
],
5656
"static": "phpstan --ansi analyse --level max src"
5757
},

0 commit comments

Comments
 (0)