Skip to content

Commit 593aeb7

Browse files
committed
move process to its own component
1 parent 488f0c2 commit 593aeb7

23 files changed

+2227
-8
lines changed

bin/release.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ git tag $VERSION
5252
git push origin --tags
5353

5454
# Tag Components
55-
for REMOTE in auth broadcasting bus cache collections conditionable config console container contracts cookie database encryption events filesystem hashing http log macroable mail notifications pagination pipeline queue redis routing session support testing translation validation view
55+
for REMOTE in auth broadcasting bus cache collections conditionable config console container contracts cookie database encryption events filesystem hashing http log macroable mail notifications pagination pipeline process queue redis routing session support testing translation validation view
5656
do
5757
echo ""
5858
echo ""

bin/split.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ remote mail [email protected]:illuminate/mail.git
4141
remote notifications [email protected]:illuminate/notifications.git
4242
remote pagination [email protected]:illuminate/pagination.git
4343
remote pipeline [email protected]:illuminate/pipeline.git
44+
remote process [email protected]:illuminate/process.git
4445
remote queue [email protected]:illuminate/queue.git
4546
remote redis [email protected]:illuminate/redis.git
4647
remote routing [email protected]:illuminate/routing.git
@@ -74,6 +75,7 @@ split 'src/Illuminate/Mail' mail
7475
split 'src/Illuminate/Notifications' notifications
7576
split 'src/Illuminate/Pagination' pagination
7677
split 'src/Illuminate/Pipeline' pipeline
78+
split 'src/Illuminate/Process' process
7779
split 'src/Illuminate/Queue' queue
7880
split 'src/Illuminate/Redis' redis
7981
split 'src/Illuminate/Routing' routing

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@
7878
"illuminate/notifications": "self.version",
7979
"illuminate/pagination": "self.version",
8080
"illuminate/pipeline": "self.version",
81+
"illuminate/process": "self.version",
8182
"illuminate/queue": "self.version",
8283
"illuminate/redis": "self.version",
8384
"illuminate/routing": "self.version",

src/Illuminate/Contracts/Console/Process/InvokedProcess.php renamed to src/Illuminate/Contracts/Process/InvokedProcess.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Illuminate\Contracts\Console\Process;
3+
namespace Illuminate\Contracts\Process;
44

55
interface InvokedProcess
66
{

src/Illuminate/Contracts/Console/Process/ProcessResult.php renamed to src/Illuminate/Contracts/Process/ProcessResult.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Illuminate\Contracts\Console\Process;
3+
namespace Illuminate\Contracts\Process;
44

55
interface ProcessResult
66
{

src/Illuminate/Process/.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/.github export-ignore
2+
.gitattributes export-ignore
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Close Pull Request
2+
3+
on:
4+
pull_request_target:
5+
types: [opened]
6+
7+
jobs:
8+
run:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: superbrothers/close-pull-request@v3
12+
with:
13+
comment: "Thank you for your pull request. However, you have submitted this PR on the Illuminate organization which is a read-only sub split of `laravel/framework`. Please submit your PR on the https://github.com/laravel/framework repository.<br><br>Thanks!"
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<?php
2+
3+
namespace Illuminate\Process\Exceptions;
4+
5+
use Illuminate\Contracts\Process\ProcessResult;
6+
use Symfony\Component\Console\Exception\RuntimeException;
7+
8+
class ProcessFailedException extends RuntimeException
9+
{
10+
/**
11+
* The process result instance.
12+
*
13+
* @var \Illuminate\Contracts\Process\ProcessResult
14+
*/
15+
public $result;
16+
17+
/**
18+
* Create a new exception instance.
19+
*
20+
* @param \Illuminate\Contracts\Process\ProcessResult $result
21+
* @return void
22+
*/
23+
public function __construct(ProcessResult $result)
24+
{
25+
$this->result = $result;
26+
27+
parent::__construct(
28+
sprintf('The process "%s" failed.', $result->command()),
29+
$result->exitCode() ?? 1,
30+
);
31+
}
32+
}
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?php
2+
3+
namespace Illuminate\Process\Exceptions;
4+
5+
use Illuminate\Contracts\Process\ProcessResult;
6+
use Symfony\Component\Process\Exception\ProcessTimedOutException as SymfonyTimeoutException;
7+
use Symfony\Component\Process\Exception\RuntimeException;
8+
9+
class ProcessTimedOutException extends RuntimeException
10+
{
11+
/**
12+
* The process result instance.
13+
*
14+
* @var \Illuminate\Contracts\Process\ProcessResult
15+
*/
16+
public $result;
17+
18+
/**
19+
* Create a new exception instance.
20+
*
21+
* @param \Symfony\Component\Process\Exception\ProcessTimedOutException $original
22+
* @param \Illuminate\Contracts\Process\ProcessResult $result
23+
* @return void
24+
*/
25+
public function __construct(SymfonyTimeoutException $original, ProcessResult $result)
26+
{
27+
$this->result = $result;
28+
29+
parent::__construct($original->getMessage(), $original->getCode(), $original);
30+
}
31+
}

0 commit comments

Comments
 (0)