Code Duplication    Length = 10-11 lines in 2 locations

src/Git/Repository.php 2 locations

@@ 83-93 (lines=11) @@
80
        return $branches;
81
    }
82
83
    public function createBranch(string $name): Branch
84
    {
85
        $this->client->run(
86
            $this->directory,
87
            new PlainArgument('checkout'),
88
            new ShortFlag('b'),
89
            new PlainArgument($name)
90
        );
91
92
        return new Branch($name);
93
    }
94
95
    public function checkout(string $name): Branch
96
    {
@@ 95-104 (lines=10) @@
92
        return new Branch($name);
93
    }
94
95
    public function checkout(string $name): Branch
96
    {
97
        $this->client->run(
98
            $this->directory,
99
            new PlainArgument('checkout'),
100
            new PlainArgument($name)
101
        );
102
103
        return new Branch('* ' . $name);
104
    }
105
106
    public function add(File $file)
107
    {