Skip to content

Commit 13a047f

Browse files
committed
bigger timeout + print destination
1 parent f9d3b10 commit 13a047f

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

app/Commands/CompileBinaryCommand.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ class CompileBinaryCommand extends Command
1616

1717
public function handle(): void
1818
{
19-
set_time_limit(300);
19+
$timeout = 60 * 10;
20+
21+
set_time_limit($timeout);
2022

2123
$version = File::json(base_path('composer.json'))['version'];
2224

@@ -26,6 +28,8 @@ public function handle(): void
2628
sprintf('bin/php-parser-v%s-%s', $version, $this->option('arch'))
2729
);
2830

31+
info("Destination: {$destination}");
32+
2933
if (file_exists(base_path('.env'))) {
3034
exec('mv ' . base_path('.env') . ' ' . base_path('.env.bak'));
3135
}
@@ -75,8 +79,8 @@ public function handle(): void
7579
sprintf('%s download --with-php=8.2 --for-extensions="%s"', $spc, $extensions),
7680
sprintf('%s build --build-micro --build-cli "%s"', $spc, $extensions),
7781
sprintf('%s micro:combine %s -O %s', $spc, base_path('builds/php-parser'), $destination),
78-
])->each(function (string $command) {
79-
Process::timeout(300)->run($command, function (string $type, string $output) {
82+
])->each(function (string $command) use ($timeout) {
83+
Process::timeout($timeout)->run($command, function (string $type, string $output) {
8084
echo $output;
8185
});
8286
});

0 commit comments

Comments
 (0)