io.go 488 B

12345678910111213141516171819202122232425
  1. package buggo
  2. import (
  3. "os"
  4. )
  5. func readPath(path string) (output string, err error) {
  6. content, err := os.ReadFile(path)
  7. if err != nil {
  8. return "", err
  9. }
  10. for _, line := range content {
  11. output = output + string(line)
  12. }
  13. return output, nil
  14. }
  15. // Writes a bug to disk
  16. func WriteBug(bug Bug) (success bool, err error) { return false, nil } // TODO: implement
  17. // Removes a bug from disk
  18. func DeleteBug(bug Bug) (success bool, err error) { return false, nil } // TODO: implement