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

Function interp_basename

src/discover/language.c:1087–1090  ·  view source on GitHub ↗

Basename of an interpreter path: the segment after the last '/'. Shebangs * are a POSIX convention, so only '/' is treated as a separator. */

Source from the content-addressed store, hash-verified

1085/* Basename of an interpreter path: the segment after the last '/'. Shebangs
1086 * are a POSIX convention, so only '/' is treated as a separator. */
1087static const char *interp_basename(const char *path) {
1088 const char *slash = strrchr(path, '/');
1089 return slash ? slash + SKIP_ONE : path;
1090}
1091
1092/* "python" optionally followed by an explicit numeric version (digits and dots
1093 * only, e.g. "python3", "python3.12"). Bounded and explicit so arbitrary

Callers 1

lang_shebangFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected