Re-structure packages
Overhaul of package structure and other cleanup.
This commit is contained in:
15
file/file.go
Normal file
15
file/file.go
Normal file
@@ -0,0 +1,15 @@
|
||||
// Package file contains filesystem functions
|
||||
package file
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
// Exists returns true if a file exists
|
||||
func Exists(filename string) bool {
|
||||
info, err := os.Stat(filename)
|
||||
if os.IsNotExist(err) {
|
||||
return false
|
||||
}
|
||||
return !info.IsDir()
|
||||
}
|
Reference in New Issue
Block a user