github.com/dayvar14/tail@v0.0.0-20240222011302-f530c4fa0c9f/tail_posix.go (about) 1 // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail 2 // +build !windows 3 4 package tail 5 6 import ( 7 "os" 8 ) 9 10 // Deprecated: this function is only useful internally and, as such, 11 // it will be removed from the API in a future major release. 12 // 13 // OpenFile proxies a os.Open call for a file so it can be correctly tailed 14 // on POSIX and non-POSIX OSes like MS Windows. 15 func OpenFile(name string) (file *os.File, err error) { 16 return os.Open(name) 17 }