Skip to content

Commit

Permalink
fix: fix absolute path
Browse files Browse the repository at this point in the history
  • Loading branch information
dtomasi committed Aug 18, 2021
1 parent ffb9857 commit 7c7520d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions git-dirclone/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"os"
"os/exec"
"path"
"path/filepath"
"strings"
)

Expand All @@ -26,6 +27,11 @@ func newRootCmd() *cobra.Command {
return err
}

rootDir, err = filepath.Abs(rootDir)
if err != nil {
return err
}

urlObj, err := giturls.Parse(args[0])
if err != nil {
return err
Expand Down

0 comments on commit 7c7520d

Please sign in to comment.