MCPcopy Create free account
hub / github.com/OpenListTeam/OpenList / PWD

Function PWD

internal/bootstrap/config.go:21–35  ·  view source on GitHub ↗

Program working directory

()

Source from the content-addressed store, hash-verified

19
20// Program working directory
21func PWD() string {
22 if flags.ForceBinDir {
23 ex, err := os.Executable()
24 if err != nil {
25 log.Fatal(err)
26 }
27 pwd := filepath.Dir(ex)
28 return pwd
29 }
30 d, err := os.Getwd()
31 if err != nil {
32 d = "."
33 }
34 return d
35}
36
37func InitConfig() {
38 pwd := PWD()

Callers 1

InitConfigFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected