Code Duplication    Length = 9-13 lines in 2 locations

src/TaskInfo.php 1 location

@@ 26-34 (lines=9) @@
23
     *
24
     * @return string
25
     */
26
    public static function formatTaskName($task)
27
    {
28
        $name = get_class($task);
29
        $name = preg_replace('~Stack^~', '', $name);
30
        $name = str_replace('Robo\\Task\Base\\', '', $name);
31
        $name = str_replace('Robo\\Task\\', '', $name);
32
        $name = str_replace('Robo\\Collection\\', '', $name);
33
        return $name;
34
    }
35
}
36

src/Task/Assets/ImageMinify.php 1 location

@@ 434-446 (lines=13) @@
431
    /**
432
     * @return string
433
     */
434
    protected function getOS()
435
    {
436
        $os = php_uname('s');
437
        $os .= '/'.php_uname('m');
438
        // replace x86_64 to x64, because the imagemin repo uses that
439
        $os = str_replace('x86_64', 'x64', $os);
440
        // replace i386, i686, etc to x86, because of imagemin
441
        $os = preg_replace('/i[0-9]86/', 'x86', $os);
442
        // turn info to lowercase, because of imagemin
443
        $os = strtolower($os);
444
445
        return $os;
446
    }
447
448
    /**
449
     * @param string $command