@@ -6,8 +6,8 @@ |
||
6 | 6 | localhost('beta')->setLabels(['env' => 'dev']); |
7 | 7 | localhost('dev')->setLabels(['env' => 'dev']); |
8 | 8 | |
9 | -task('test', function () { |
|
10 | - on(select('env=dev'), function () { |
|
9 | +task('test', function() { |
|
10 | + on(select('env=dev'), function() { |
|
11 | 11 | info('executing on {{alias}}'); |
12 | 12 | }); |
13 | 13 | }); |
@@ -8,14 +8,14 @@ |
||
8 | 8 | 'VAR' => 'global', |
9 | 9 | ]); |
10 | 10 | |
11 | -task('test', function () { |
|
11 | +task('test', function() { |
|
12 | 12 | info('global=' . run('echo $VAR')); |
13 | 13 | info('local=' . run('echo $VAR', ['env' => ['VAR' => 'local']])); |
14 | 14 | info('dotenv=' . run('echo $KEY')); |
15 | 15 | info('dotenv=' . run('echo $KEY', ['env' => ['KEY' => 'local']])); |
16 | 16 | }); |
17 | 17 | |
18 | -before('test', function () { |
|
18 | +before('test', function() { |
|
19 | 19 | run('mkdir -p {{deploy_path}}'); |
20 | 20 | run('echo KEY="\'Hello, world!\'" > {{deploy_path}}/.env'); |
21 | 21 | set('dotenv', '{{deploy_path}}/.env'); |
@@ -4,6 +4,6 @@ |
||
4 | 4 | |
5 | 5 | require __DIR__ . '/deploy.php'; |
6 | 6 | |
7 | -task('deploy:update_code', function () { |
|
7 | +task('deploy:update_code', function() { |
|
8 | 8 | upload(__FIXTURES__ . '/project/', '{{release_path}}'); |
9 | 9 | }); |
@@ -5,6 +5,6 @@ |
||
5 | 5 | localhost('prod'); |
6 | 6 | localhost('beta'); |
7 | 7 | |
8 | -task('test_once', function () { |
|
8 | +task('test_once', function() { |
|
9 | 9 | writeln('SHOULD BE ONCE'); |
10 | 10 | })->once(); |
@@ -11,6 +11,6 @@ |
||
11 | 11 | localhost('group_b_2') |
12 | 12 | ->setLabels(['node' => 'anna']); |
13 | 13 | |
14 | -task('test_once_per_node', function () { |
|
14 | +task('test_once_per_node', function() { |
|
15 | 15 | writeln('alias: {{alias}} hostname: {{hostname}}'); |
16 | 16 | })->oncePerNode(); |
@@ -4,19 +4,19 @@ |
||
4 | 4 | |
5 | 5 | localhost(); |
6 | 6 | |
7 | -task('named_arguments', function () { |
|
7 | +task('named_arguments', function() { |
|
8 | 8 | run('echo "Hello, $name!"', env: ['name' => 'world']); |
9 | 9 | }); |
10 | 10 | |
11 | -task('options', function () { |
|
11 | +task('options', function() { |
|
12 | 12 | run('echo "Hello, $name!"', ['env' => ['name' => 'Anton']]); |
13 | 13 | }); |
14 | 14 | |
15 | -task('options_with_named_arguments', function () { |
|
15 | +task('options_with_named_arguments', function() { |
|
16 | 16 | // The `options:` arg has higher priority than named arguments. |
17 | 17 | run('echo "Hello, $name!"', ['env' => ['name' => 'override']], env: ['name' => 'world']); |
18 | 18 | }); |
19 | 19 | |
20 | -task('run_locally_named_arguments', function () { |
|
20 | +task('run_locally_named_arguments', function() { |
|
21 | 21 | runLocally('echo "Hello, $name!"', env: ['name' => 'world']); |
22 | 22 | }); |
@@ -120,7 +120,7 @@ |
||
120 | 120 | |
121 | 121 | usort( |
122 | 122 | $updates, |
123 | - function (Update $a, Update $b) { |
|
123 | + function(Update $a, Update $b) { |
|
124 | 124 | return Comparator::isGreaterThan( |
125 | 125 | $a->getVersion(), |
126 | 126 | $b->getVersion(), |
@@ -88,7 +88,7 @@ |
||
88 | 88 | ->setTimeout((null === $config['timeout']) ? null : (float) $config['timeout']) |
89 | 89 | ->setIdleTimeout((null === $config['idle_timeout']) ? null : (float) $config['idle_timeout']); |
90 | 90 | |
91 | - $callback = function ($type, $buffer) use ($config, $host) { |
|
91 | + $callback = function($type, $buffer) use ($config, $host) { |
|
92 | 92 | $this->logger->printBuffer($host, $type, $buffer); |
93 | 93 | $this->pop->callback($host, boolval($config['real_time_output']))($type, $buffer); |
94 | 94 | }; |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | $dealersHand = []; |
81 | 81 | $playersHand = []; |
82 | 82 | shuffle($deck); |
83 | - $deal = function () use (&$deck, &$graveyard) { |
|
83 | + $deal = function() use (&$deck, &$graveyard) { |
|
84 | 84 | if (count($deck) == 0) { |
85 | 85 | shuffle($graveyard); |
86 | 86 | $deck = $graveyard; |
@@ -287,7 +287,7 @@ discard block |
||
287 | 287 | } |
288 | 288 | $variants = [$value]; |
289 | 289 | while ($aces-- > 0) { |
290 | - $variants = array_flatten(array_map(function ($v) { |
|
290 | + $variants = array_flatten(array_map(function($v) { |
|
291 | 291 | return [$v + 1, $v + 11]; |
292 | 292 | }, $variants)); |
293 | 293 | } |