mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-04 15:32:35 +00:00
#591 - sites
This commit is contained in:
@ -5,6 +5,7 @@
|
||||
use App\Exceptions\SSHError;
|
||||
use App\Models\Site;
|
||||
use App\SSH\Git\Git;
|
||||
use Illuminate\Support\Facades\Validator;
|
||||
|
||||
class UpdateBranch
|
||||
{
|
||||
@ -15,6 +16,8 @@ class UpdateBranch
|
||||
*/
|
||||
public function update(Site $site, array $input): void
|
||||
{
|
||||
Validator::make($input, self::rules())->validate();
|
||||
|
||||
$site->branch = $input['branch'];
|
||||
app(Git::class)->fetchOrigin($site);
|
||||
app(Git::class)->checkout($site);
|
||||
|
Reference in New Issue
Block a user