* Generates a random hex string for placeholder uniqueness. * This prevents collision when command text literally contains "__HEREDOC_N__".
()
| 34 | * This prevents collision when command text literally contains "__HEREDOC_N__". |
| 35 | */ |
| 36 | function generatePlaceholderSalt(): string { |
| 37 | // Generate 8 random bytes as hex (16 characters) |
| 38 | return randomBytes(8).toString('hex') |
| 39 | } |
| 40 | |
| 41 | /** |
| 42 | * Regex pattern for matching heredoc start syntax. |
no test coverage detected