MCPcopy Create free account
hub / github.com/codeaashu/claude-code / generatePlaceholderSalt

Function generatePlaceholderSalt

src/utils/bash/heredoc.ts:36–39  ·  view source on GitHub ↗

* Generates a random hex string for placeholder uniqueness. * This prevents collision when command text literally contains "__HEREDOC_N__".

()

Source from the content-addressed store, hash-verified

34 * This prevents collision when command text literally contains "__HEREDOC_N__".
35 */
36function 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.

Callers 1

extractHeredocsFunction · 0.85

Calls 1

toStringMethod · 0.65

Tested by

no test coverage detected