From fb3fb489e73ea645bcfec3ee9fa0eb0e21daed1d Mon Sep 17 00:00:00 2001 From: AgusDOLARD Date: Thu, 18 Jan 2024 22:20:09 -0300 Subject: [PATCH] feat: connect to $PWD with . (#26) --- session/path.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/session/path.go b/session/path.go index 9a0772a..4828404 100644 --- a/session/path.go +++ b/session/path.go @@ -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