Pantheon\Terminus\Commands\Env\DiffStatCommand::diffstat PHP Method

diffstat() public method

Show a statistical summary of the uncommitted code on an environment
public diffstat ( string $site_env ) : Consolidation\OutputFormatters\StructuredData\RowsOfFields
$site_env string Site and environment to show diff statistics for
return Consolidation\OutputFormatters\StructuredData\RowsOfFields
    public function diffstat($site_env)
    {
        list(, $env) = $this->getSiteEnv($site_env);
        $diff = (array) $env->diffstat();
        $data = [];
        if (empty($diff)) {
            $this->log()->notice('No changes on server.');
        } else {
            foreach ($diff as $file => $stats) {
                $data[] = array_merge(compact('file'), (array) $stats);
            }
        }
        return new RowsOfFields($data);
    }
DiffStatCommand