mirror of
https://github.com/EnumeratedDev/typer.git
synced 2026-09-20 23:26:11 +00:00
Switch from path to filepath package
This commit is contained in:
+5
-5
@@ -3,7 +3,7 @@ package main
|
||||
import (
|
||||
"log"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
@@ -40,11 +40,11 @@ func readKeybindings() {
|
||||
|
||||
configPaths := make([]string, 0)
|
||||
if runtime.GOOS == "windows" {
|
||||
configPaths = append(configPaths, path.Join(homeDir, "AppData/Roaming/Typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, path.Join(path.Dir(execPath), "etc/typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, filepath.Join(homeDir, "AppData/Roaming/Typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, filepath.Join(filepath.Dir(execPath), "etc/typer/keybindings.yml"))
|
||||
} else {
|
||||
configPaths = append(configPaths, path.Join(homeDir, ".config/typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, path.Join(sysconfdir, "typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, filepath.Join(homeDir, ".config/typer/keybindings.yml"))
|
||||
configPaths = append(configPaths, filepath.Join(sysconfdir, "typer/keybindings.yml"))
|
||||
}
|
||||
|
||||
for _, configPath := range configPaths {
|
||||
|
||||
Reference in New Issue
Block a user