src/Rocketeer/Rocketeer.php
public static function getDetectedStage($application = 'application', $path = null)
    {
        $folderRegex = '[a-zA-Z0-9_-]+';

        $current = $path ?: realpath(__DIR__);
        $pattern = sprintf('/%s\/(%s)\/%s\/([0-9]{14})/', $application, $folderRegex, $folderRegex);
        preg_match($pattern, $current, $matches);

        return isset($matches[1]) ? $matches[1] : false;
    }
public static function getDetectedStage($application = 'application', $path = null)
    {
        $folderRegex = '[a-zA-Z0-9_-]+';

        $current = $path ?: realpath(__DIR__);
        $pattern = sprintf('/%s\/(%s)\/%s\/([0-9]{14})/', $application, $folderRegex, $folderRegex);
        preg_match($pattern, $current, $matches);

        return isset($matches[1]) ? $matches[1] : false;
    }
public static function getDetectedStage ( $ application = 'application' , $ path = null ) { $ folderRegex = '[a-zA-Z0-9_-]+' ; $ current = $ path ? : realpath ( __DIR__ ) ; $ pattern = sprintf ( '/%s\/(%s)\/%s\/([0-9]{14})/' , $ application , $ folderRegex , $ folderRegex ) ; preg_match ( $ pattern , $ current , $ matches ) ; return isset ( $ matches [ 1 ] ) ? $ matches [ 1 ] : false ; }
Returns what stage Rocketeer thinks he's in.

@param string      $application
@param string|null $path

@return string|false
Returns what stage Rocketeer thinks he s in .