MCPcopy Index your code
hub / github.com/ChinaSiro/claude-code-sourcemap / Ynz

Function Ynz

package/cli.js:2580–2602  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2578 else
2579 alias | sed 's/^alias //g' | sed 's/^/alias -- /' | head -n 1000 >> "$SNAPSHOT_FILE"
2580 fi
2581 `,_}async function Ynz(){let q=process.env.PATH;if(Z1()==="windows"){let Y=await m_("echo $PATH",{shell:!0,reject:!1});if(Y.exitCode===0&&Y.stdout)q=Y.stdout.trim()}let K=qnz(),_="";if(_+=`
2582 # Check for rg availability
2583 echo "# Check for rg availability" >> "$SNAPSHOT_FILE"
2584 echo "if ! (unalias rg 2>/dev/null; command -v rg) >/dev/null 2>&1; then" >> "$SNAPSHOT_FILE"
2585 `,K.type==="function")_+=`
2586 cat >> "$SNAPSHOT_FILE" << 'RIPGREP_FUNC_END'
2587 ${K.snippet}
2588RIPGREP_FUNC_END
2589 `;else{let Y=K.snippet.replace(/'/g,"'\\''");_+=`
2590 echo ' alias rg='"'${Y}'" >> "$SNAPSHOT_FILE"
2591 `}_+=`
2592 echo "fi" >> "$SNAPSHOT_FILE"
2593 `;let z=_nz();if(z!==null)_+=`
2594 # Shadow find/grep with embedded bfs/ugrep (ant-native only)
2595 echo "# Shadow find/grep with embedded bfs/ugrep" >> "$SNAPSHOT_FILE"
2596 cat >> "$SNAPSHOT_FILE" << 'FIND_GREP_FUNC_END'
2597${z}
2598FIND_GREP_FUNC_END
2599 `;return _+=`
2600
2601 # Add PATH to the file
2602 echo "export PATH=${E4([q||""])}" >> "$SNAPSHOT_FILE"
2603 `,_}async function $nz(q,K,_){let z=Da1(q),Y=z.endsWith(".zshrc"),$=_?znz(z):!Y?'echo "shopt -s expand_aliases" >> "$SNAPSHOT_FILE"':"",A=await Ynz();return`SNAPSHOT_FILE=${E4([K])}
2604 ${_?`source "${z}" < /dev/null`:"# No user config file to source"}
2605

Callers 1

$nzFunction · 0.85

Calls 6

m_Function · 0.85
qnzFunction · 0.85
_nzFunction · 0.85
E4Function · 0.85
trimMethod · 0.45
replaceMethod · 0.45

Tested by

no test coverage detected