MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / ci_bash_shell

Function ci_bash_shell

src/pipeline/pass_ci.c:408–417  ·  view source on GitHub ↗

A shell GitHub runs a step with as bash: `bash ...` / `sh ...`. */

Source from the content-addressed store, hash-verified

406
407/* A shell GitHub runs a step with as bash: `bash ...` / `sh ...`. */
408static bool ci_bash_shell(const char *sh) {
409 size_t k = strncmp(sh, "bash", strlen("bash")) == 0 ? strlen("bash")
410 : strncmp(sh, "sh", strlen("sh")) == 0 ? strlen("sh")
411 : 0;
412 if (!k) {
413 return false;
414 }
415 char ch = sh[k];
416 return !(ch == '_' || (ch >= '0' && ch <= '9') || ((ch | ' ') >= 'a' && (ch | ' ') <= 'z'));
417}
418
419/* `s` contains `word` (lowercase ASCII), ignoring case. */
420static bool ci_has_word(const char *s, const char *word) {

Callers 1

ci_gha_stepsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected