From 45270e389ec8f69472b7e570468390369fe935ac Mon Sep 17 00:00:00 2001 From: Gokcehan Date: Sun, 31 Mar 2019 19:45:11 +0300 Subject: [PATCH] export id variable after initialization --- main.go | 2 ++ os.go | 2 -- os_windows.go | 2 -- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/main.go b/main.go index 1cb4c81e..007a6d6b 100644 --- a/main.go +++ b/main.go @@ -181,6 +181,8 @@ func main() { os.Exit(2) } + exportEnvVars() + run() } diff --git a/os.go b/os.go index 843776a9..3117bb8a 100644 --- a/os.go +++ b/os.go @@ -85,8 +85,6 @@ func init() { gHistoryPath = filepath.Join(data, "lf", "history") gDefaultSocketPath = filepath.Join(os.TempDir(), fmt.Sprintf("lf.%s.sock", gUser.Username)) - - exportEnvVars() } func detachedCommand(name string, arg ...string) *exec.Cmd { diff --git a/os_windows.go b/os_windows.go index 9c4eeb65..429c3a8a 100644 --- a/os_windows.go +++ b/os_windows.go @@ -70,8 +70,6 @@ func init() { gMarksPath = filepath.Join(data, "lf", "marks") gHistoryPath = filepath.Join(data, "lf", "history") - - exportEnvVars() } func detachedCommand(name string, arg ...string) *exec.Cmd {