GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Exec   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 16
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getCommandForDirectory() 0 7 1
1
<?php
2
/**
3
 * Exec.php
4
 *
5
 * @package         ProjectVersioner
6
 * @subpackage      Reader
7
 */
8
9
namespace Naneau\ProjectVersioner\Reader\Git\Tag;
10
11
use Naneau\ProjectVersioner\Reader\Git\Exec as GitExec;
12
13
/**
14
 * Exec
15
 *
16
 * Reads the latest tag reachable from the current commit
17
 *
18
 * For example: 3.0.2
19
 *
20
 * @see http://git-scm.com/docs/git-describe
21
 *
22
 * @category        Naneau
23
 * @package         ProjectVersioner
24
 * @subpackage      Reader
25
 */
26
class Exec extends GitExec
27
{
28
    /**
29
     * Get command for directory
30
     *
31
     * @param  string $directory
32
     * @return string
33
     **/
34
    protected function getCommandForDirectory($directory)
35
    {
36
        return sprintf(
37
            'cd %s && git describe --abbrev=0',
38
            escapeshellarg($directory)
39
        );
40
    }
41
}
42