laravel / envoy

Elegant SSH tasks for PHP.
https://laravel.com/docs/envoy
MIT License
1.57k stars 178 forks source link

[2.x] Revert allowing line breaks inside `@server` statements #243

Closed bakerkretzmar closed 2 years ago

bakerkretzmar commented 2 years ago

This PR reverts #241 for now. It breaks if there is another ) character anywhere after the @servers block (which there almost definitely will be) because the @servers block now matches up to that last parenthesis.

E.g. this breaks completely because of the ) in the setup section:

@servers(['local' => 'localhost', 'staging' => 'staging-host'])
@setup
    $releaseName = date('Y-m-d_H-i-s');
@endsetup

Sorry about this! I'll keep working on the regex and PR something more robust if I figure it out.