mirror of
https://github.com/zhigang1992/cow.git
synced 2026-01-12 22:46:29 +08:00
22 lines
445 B
Go
22 lines
445 B
Go
package main
|
|
|
|
import (
|
|
"os"
|
|
"path"
|
|
)
|
|
|
|
const (
|
|
rcFname = "rc.txt"
|
|
blockedFname = "blocked.txt"
|
|
directFname = "direct.txt"
|
|
statFname = "stat.txt"
|
|
|
|
newLine = "\r\n"
|
|
)
|
|
|
|
func getDefaultRcFile() string {
|
|
// On windows, put the configuration file in the same directory of cow executable
|
|
// This is not a reliable way to detect binary directory, but it works for double click and run
|
|
return path.Join(path.Dir(os.Args[0]), rcFname)
|
|
}
|