MCPcopy Create free account
hub / github.com/blockmatic/basilic / checkToolExists

Function checkToolExists

scripts/setup-database.mjs:70–87  ·  view source on GitHub ↗
(toolName, checkCommand)

Source from the content-addressed store, hash-verified

68}
69
70function checkToolExists(toolName, checkCommand) {
71 try {
72 execSync(checkCommand, { stdio: 'ignore' })
73 return true
74 } catch {
75 try {
76 execSync(`which ${toolName}`, { stdio: 'ignore' })
77 return true
78 } catch {
79 try {
80 execSync(`where ${toolName}`, { stdio: 'ignore' })
81 return true
82 } catch {
83 return false
84 }
85 }
86 }
87}
88
89function checkDockerRunning() {
90 try {

Callers 3

checkDockerComposeFunction · 0.70
installSupabaseFunction · 0.70
mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected