Skip to content

Commit 63f747b

Browse files
pedrolucasphonza
authored andcommitted
Use Join() to handle missing dir separator
Without this, if you didn't added a / on your root it wouldn't fetch repos correctly
1 parent 8fbf436 commit 63f747b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

pkg/smithy/config.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ package smithy
1919
import (
2020
"fmt"
2121
"io/ioutil"
22+
"path"
2223
"path/filepath"
2324
"sort"
2425

@@ -108,7 +109,9 @@ func (sc *SmithyConfig) LoadAllRepositories() error {
108109
continue
109110
}
110111

111-
r, err := git.PlainOpen(sc.Git.Root + repo.Name())
112+
repoPath := path.Join(sc.Git.Root, repo.Name())
113+
114+
r, err := git.PlainOpen(repoPath)
112115
if err != nil {
113116
// Ignore directories that aren't git repositories
114117
continue

0 commit comments

Comments
 (0)