MCPcopy
hub / github.com/idank/explainshell / gen_perl_cleanup_cmd

Function gen_perl_cleanup_cmd

tools/loadtest.py:121–130  ·  view source on GitHub ↗

perl HTML tag-split pipeline.

(rng: random.Random)

Source from the content-addressed store, hash-verified

119
120
121def gen_perl_cleanup_cmd(rng: random.Random) -> str:
122 """perl HTML tag-split pipeline."""
123 rd = _pick(READ_VARIANTS, rng)
124 p1, p2, p3 = (_pick(PERL_VARIANTS, rng) for _ in range(3))
125 gr = _pick(GREP_VARIANTS, rng)
126 return (
127 f"{rd} - | {p1} -pe 's{{\\n}}{{ }}g' | "
128 f"{p2} -pe 's{{>}}{{>\\n}}g' | "
129 f"{p3} -pe 's{{<}}{{\\n<}}g' | {gr} -v '<'"
130 )
131
132
133def gen_hardlink_cmd(rng: random.Random) -> str:

Callers

nothing calls this directly

Calls 2

_pickFunction · 0.85
rangeFunction · 0.85

Tested by

no test coverage detected