mirror of
https://github.com/hauke68/Magallanes.git
synced 2026-08-28 10:08:56 +02:00
Big refactoring. Use of Namespaces and codestyles. PSR-0, PSR-1, PSR-2.
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
/*
|
||||
* This file is part of the Magallanes package.
|
||||
*
|
||||
* (c) Andrés Montañez <andres@andresmontanez.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Mage\Command\BuiltIn;
|
||||
|
||||
use Mage\Command\AbstractCommand;
|
||||
use Mage\Command\RequiresEnvironment;
|
||||
use Mage\Console;
|
||||
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
* Command for Unlocking an Environment
|
||||
*
|
||||
* @author Andrés Montañez <andres@andresmontanez.com>
|
||||
*/
|
||||
class UnlockCommand
|
||||
extends AbstractCommand implements RequiresEnvironment
|
||||
{
|
||||
/**
|
||||
* Unlocks an Environment
|
||||
* @see \Mage\Command\AbstractCommand::run()
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
$lockFile = '.mage/' . $this->getConfig()->getEnvironment() . '.lock';
|
||||
if (file_exists($lockFile)) {
|
||||
@unlink($lockFile);
|
||||
}
|
||||
|
||||
Console::output('Unlocked deployment to <light_purple>' . $this->getConfig()->getEnvironment() . '</light_purple> environment', 1, 2);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user