hookPreEdit warns before editing hub files (reads JSON from stdin)
(root string)
| 648 | |
| 649 | // hookPreEdit warns before editing hub files (reads JSON from stdin) |
| 650 | func hookPreEdit(root string) error { |
| 651 | filePath, err := extractFilePathFromStdin() |
| 652 | if err != nil || filePath == "" { |
| 653 | return nil // silently skip if no file path |
| 654 | } |
| 655 | |
| 656 | return checkFileImporters(root, filePath) |
| 657 | } |
| 658 | |
| 659 | // hookPostEdit shows impact after editing (reads JSON from stdin) |
| 660 | func hookPostEdit(root string) error { |
no test coverage detected