mirror of
https://github.com/go-i2p/go-i2p.git
synced 2025-07-05 22:17:04 -04:00
add base files
This commit is contained in:
14
lib/common/utils.go
Normal file
14
lib/common/utils.go
Normal file
@ -0,0 +1,14 @@
|
||||
package common
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
// check if a file is there and writeable
|
||||
func FileExists(fname string) (exists bool) {
|
||||
_, err := os.Stat(fname)
|
||||
if err == nil {
|
||||
exists = true
|
||||
}
|
||||
return
|
||||
}
|
Reference in New Issue
Block a user