(filename string, appendData bool)
| 743 | } |
| 744 | |
| 745 | func createOrOpenFile(filename string, appendData bool) (*os.File, error) { |
| 746 | if appendData { |
| 747 | return os.OpenFile(filename, os.O_APPEND|os.O_WRONLY, 0600) |
| 748 | } |
| 749 | return os.Create(filename) |
| 750 | } |
| 751 | |
| 752 | // check if the directory exists to create file. creates if doesn't exist |
| 753 | func ensureDirectoryForFile(file string) error { |
no test coverage detected
searching dependent graphs…