INNER CODE UNIT · JavaScript
isAvailable
agent-sh/agentsys · lib/binary/index.js:142
function isAvailable() {
const binPath = getBinaryPath();
if (!fs.existsSync(binPath)) return false;
const ver = getVersion();
return meetsMinimumVersion(ver, ANALYZER_MIN_VERSION);
}
/**
* Async check: returns true if the binary exists and meets the minimum version.
* Does NOT download.
* @returns {Promise<boolean>}
*/
async function isAvailableAsync() {
return isAvailable();
}
// ---------------------------------------------------------------------------
// Download + checksum verification