Skip to content

Commit

Permalink
feat: connect to $PWD with . (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
AgusDOLARD authored Jan 19, 2024
1 parent 7a32bb7 commit fb3fb48
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions session/path.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@ import (
)

func DeterminePath(choice string) (string, error) {
if choice == "." {
cwd, err := os.Getwd()
if err != nil {
return "", err
}
return cwd, nil
}
fullPath := dir.FullPath(choice)
if path.IsAbs(fullPath) {
return fullPath, nil
Expand Down

0 comments on commit fb3fb48

Please sign in to comment.