(pool, branch string)
| 29 | } |
| 30 | |
| 31 | func WriteHead(pool, branch string) error { |
| 32 | head := fmt.Sprintf("%s@%s\n", pool, branch) |
| 33 | err := os.WriteFile(headPath(), []byte(head), 0644) |
| 34 | if err != nil { |
| 35 | err = fmt.Errorf("%q: failed to write HEAD: %w", headFile, err) |
| 36 | } |
| 37 | return err |
| 38 | } |