Code Review
/
src
/
xds
/
xds-agent.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
603c2a2685d8d9a92cdd656a0a5d690b878c3f7b
[src/xds/xds-agent.git]
/
lib
/
common
/
filepath.go
1
package common
2
3
import "os"
4
5
// Exists returns whether the given file or directory exists or not
6
func Exists(path string) bool {
7
_, err := os.Stat(path)
8
if err == nil {
9
return true
10
}
11
if os.IsNotExist(err) {
12
return false
13
}
14
return true
15
}