mirror of https://github.com/Hilbis/Hilbish
feat: replace ~ in preloadPath and sampleConfPath with homedir
parent
822b2876e9
commit
4caeb7ec91
2
main.go
2
main.go
|
@ -40,6 +40,8 @@ var (
|
||||||
func main() {
|
func main() {
|
||||||
homedir, _ = os.UserHomeDir()
|
homedir, _ = os.UserHomeDir()
|
||||||
curuser, _ = user.Current()
|
curuser, _ = user.Current()
|
||||||
|
preloadPath = strings.Replace(preloadPath, "~", homedir, 1)
|
||||||
|
sampleConfPath = strings.Replace(sampleConfPath, "~", homedir, 1)
|
||||||
|
|
||||||
if defaultConfDir == "" {
|
if defaultConfDir == "" {
|
||||||
// we'll add *our* default if its empty (wont be if its changed comptime)
|
// we'll add *our* default if its empty (wont be if its changed comptime)
|
||||||
|
|
Loading…
Reference in New Issue