mirror of
https://github.com/peco/peco.git
synced 2026-09-10 07:16:29 -04:00
15 lines
207 B
Go
15 lines
207 B
Go
package peco
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
)
|
|
|
|
func homedir() (string, error) {
|
|
home := os.Getenv("HOME")
|
|
if home == "" {
|
|
return "", fmt.Errorf("error: Environment variable HOME not set")
|
|
}
|
|
|
|
return home, nil
|
|
} |