UNPKG

@dreamhorizonorg/sentinel

Version:

Open-source, zero-dependency tool that blocks compromised packages BEFORE download. Built to counter supply chain and credential theft attacks like Shai-Hulud.

60 lines (48 loc) 1.25 kB
/** * CLI-specific constants * Constants used for command-line interface operations */ export const CLI_BINARY_NAME = 'sentinel'; export const LOCKFILE_NAMES = [ 'package-lock.json', 'yarn.lock', 'pnpm-lock.yaml', 'bun.lock' ]; export const PACKAGE_JSON_FILENAME = 'package.json'; export const CLI_COMMANDS = { SCAN: 'scan', LIST: 'list', ADD: 'add', REMOVE: 'remove', STATUS: 'status', INIT: 'init', HELP: 'help', VERSION: 'version' }; export const CLI_SUBCOMMANDS = { ALIASES: 'aliases' }; export const HELP_FLAGS = ['--help', '-h', 'help']; export const VERSION_FLAGS = ['--version', '-v', 'version']; export const BOOLEAN_STRING_VALUES = { TRUE: 'true', FALSE: 'false' }; /** * Full command strings for display in help text and messages */ export const FULL_COMMANDS = { ADD_ALIASES: `${CLI_BINARY_NAME} add aliases`, REMOVE_ALIASES: `${CLI_BINARY_NAME} remove aliases`, INIT: `${CLI_BINARY_NAME} init`, STATUS: `${CLI_BINARY_NAME} status`, SCAN: `${CLI_BINARY_NAME} scan`, LIST: `${CLI_BINARY_NAME} list`, HELP: `${CLI_BINARY_NAME} --help`, VERSION: `${CLI_BINARY_NAME} --version` }; /** * Maximum number of command suggestions to show */ export const MAX_COMMAND_SUGGESTIONS = 3;