This repository has been archived on 2024-01-06. You can view files and clone it, but cannot push or open issues or pull requests.
Files
srv/file/file.go
Dave Gallant afbfa53ae6 Add feed description view (#12)
with colors!
2020-07-03 23:25:48 -04:00

17 lines
285 B
Go

// Package file contains filesystem functions
package file
import (
"github.com/spf13/afero"
)
// Exists returns true if a file exists
func Exists(filename string) bool {
var AppFs = afero.NewOsFs()
_, err := AppFs.Stat(filename)
if err != nil {
return false
}
return true
}