(checksum string)
| 74 | } |
| 75 | |
| 76 | func (node *CacheNode) ChecksumPrompt(checksum string) string { |
| 77 | cachedChecksum := node.ReadChecksum() |
| 78 | switch { |
| 79 | |
| 80 | // If the checksum doesn't exist, prompt the user to continue |
| 81 | case cachedChecksum == "": |
| 82 | return taskfileUntrustedPrompt |
| 83 | |
| 84 | // If there is a cached hash, but it doesn't match the expected hash, prompt the user to continue |
| 85 | case cachedChecksum != checksum: |
| 86 | return taskfileChangedPrompt |
| 87 | |
| 88 | default: |
| 89 | return "" |
| 90 | } |
| 91 | } |
| 92 | |
| 93 | func (node *CacheNode) Location() string { |
| 94 | return node.filePath("yaml") |
no test coverage detected