Pewarta Proxy

πŸ“‹ Server Request & Proxy Logs

Loading active proxy settings...
Developed by Khairul Adha (adhexa.id)
Mengambil log server...

βš™οΈ Pengaturan Proxy Target

Skip to content

About

The Socket CLI

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Β 
Β 

Latest commit

Β 

History

5,692 Commits

Folders and files

Repository files navigation

Socket CLI

Socket Badge CI Coverage

Follow @SocketSecurity

CLI for Socket.dev security analysis. For user documentation, see the socket package on npm.

Getting Started

Prerequisites

  • Node.js 25.8.1+ (see .node-version)
  • pnpm 10.22+ (see packageManager in package.json)

Setup

git clone https://github.com/SocketDev/socket-cli.git
cd socket-cli
pnpm install
pnpm run build

Running the CLI

# Run the built CLI
node packages/cli/dist/index.js --help

# Or use watch mode during development
pnpm dev

Running Tests

# Run all tests
pnpm test

# Run unit tests for a specific file
pnpm --filter @socketsecurity/cli run test:unit src/commands/scan/cmd-scan.test.mts

# Run with pattern matching
pnpm --filter @socketsecurity/cli run test:unit src/commands/scan/cmd-scan.test.mts -t "pattern"

Code Quality

pnpm run check        # Run lint + typecheck
pnpm run fix          # Auto-fix linting and formatting

Project Structure

socket-cli/
β”œβ”€β”€ packages/
β”‚   β”œβ”€β”€ cli/                    # Main CLI package (@socketsecurity/cli)
β”‚   β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”‚   β”œβ”€β”€ commands/       # Command implementations
β”‚   β”‚   β”‚   β”œβ”€β”€ utils/          # Shared utilities
β”‚   β”‚   β”‚   └── cli.mts         # Entry point
β”‚   β”‚   └── dist/               # Built output
β”‚   β”œβ”€β”€ build-infra/            # Build system and tooling
β”‚   └── package-builder/        # Package generation templates
β”œβ”€β”€ scripts/                    # Monorepo scripts
└── test/                       # Shared test utilities

Development Commands

Command Description
pnpm run build Smart build (skips unchanged)
pnpm run build --force Force rebuild everything
pnpm run build:cli Build CLI package only
pnpm run build:sea Build SEA binaries
pnpm dev Watch mode (auto-rebuild)
pnpm test Run all tests
pnpm testu Update test snapshots
pnpm run check Lint + typecheck
pnpm run fix Auto-fix issues

Debug Logging

SOCKET_CLI_DEBUG=1 node packages/cli/dist/index.js <command>

Environment Variables

Key variables for development:

Variable Description
SOCKET_CLI_DEBUG Enable debug logging (1)
SOCKET_CLI_API_TOKEN Socket API token
SOCKET_CLI_ORG_SLUG Socket organization slug
SOCKET_CLI_API_BASE_URL Override API endpoint
SOCKET_CLI_NO_API_TOKEN Disable default API token

Further Reading

See Also


Socket Logo

About

The Socket CLI

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages