Skip to content

Commit

Permalink
Add task to update all verndor + update all vendor
Browse files Browse the repository at this point in the history
  • Loading branch information
lyrixx committed Feb 27, 2025
1 parent c85bc00 commit 598d500
Show file tree
Hide file tree
Showing 14 changed files with 289 additions and 271 deletions.
1 change: 1 addition & 0 deletions bin/generate-tests.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@
'qa:phpstan:install',
'qa:phpstan:phpstan',
'qa:phpstan:update',
'update',
// Customized tests
'crypto:decrypt',
'crypto:encrypt',
Expand Down
17 changes: 17 additions & 0 deletions castor.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,12 @@

use Castor\Attribute\AsTask;

use function Castor\context;
use function Castor\import;
use function Castor\io;
use function Castor\mount;
use function Castor\run;
use function Castor\with;

import(__DIR__ . '/examples');
import(__DIR__ . '/tools/php-cs-fixer/castor.php');
Expand All @@ -19,3 +23,16 @@ function hello(): void
{
echo 'Hello world!';
}

#[AsTask(description: 'Update all dependencies')]
function update(): void
{
io()->title('Update all dependencies');

with(\castor\phar\update(...), context: context()->withWorkingDirectory(__DIR__ . '/tools/phar'));
\qa\cs\update();
\qa\phpstan\update();

io()->section('Update castor dependencies');
run(['composer', 'update']);
}
14 changes: 7 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,26 @@
},
"require": {
"php": ">=8.2",
"composer/composer": "^2.8.5",
"composer/composer": "^2.8.6",
"jolicode/jolinotif": "^3.1",
"jolicode/php-os-helper": "^0.2",
"monolog/monolog": "^3.8.1",
"nikic/php-parser": "^5.4.0",
"phpstan/phpdoc-parser": "^2.0.1",
"phpstan/phpdoc-parser": "^2.1.0",
"spatie/ssh": "^1.13.0",
"symfony/cache": "^7.2.3",
"symfony/cache": "^7.2.4",
"symfony/config": "^7.2.3",
"symfony/console": "^7.2.1",
"symfony/dependency-injection": "^7.2.3",
"symfony/dependency-injection": "^7.2.4",
"symfony/deprecation-contracts": "^3.5.1",
"symfony/dotenv": "^7.2",
"symfony/error-handler": "^7.2.3",
"symfony/error-handler": "^7.2.4",
"symfony/expression-language": "^7.2",
"symfony/filesystem": "^7.2",
"symfony/finder": "^7.2.2",
"symfony/http-client": "^7.2.3",
"symfony/http-client": "^7.2.4",
"symfony/monolog-bridge": "^7.2",
"symfony/process": "^7.2",
"symfony/process": "^7.2.4",
"symfony/string": "^7.2",
"symfony/translation-contracts": "^3.5.1",
"symfony/var-dumper": "^7.2.3",
Expand Down
Loading

0 comments on commit 598d500

Please sign in to comment.