New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

treepick

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

treepick

Interactive file tree picker for Claude Code and other AI CLI tools

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

TreePick 🌲

Interactive file tree picker for AI CLI tools like Claude Code, OpenAI Codex, and Google Gemini CLI.

Features

  • 🌲 Interactive File Tree - Beautiful terminal-based file picker
  • Multi-select - Choose multiple files and folders easily
  • 🚀 AI Integration - Automatically passes selected files to AI tools
  • 🎯 Smart Filtering - Ignores common non-essential directories
  • Fast & Lightweight - Built with Node.js and blessed

Quick Start

npm

# Install dependencies
npm install

# Run the tool
npm start

# Or use directly
node bin/fselect.js

bun

# Install dependencies
bun i

# Link for global usage
bun link treepick

Usage

Basic Usage

# Start with default settings (scans current directory for Claude)
treepick

# Specify a different directory  
treepick -d /path/to/your/project

# Use with different AI tools
treepick -t codex    # OpenAI Codex
treepick -t gemini   # Google Gemini CLI

# Dry run (see selected files without executing)
treepick --dry-run

Interactive Controls

KeyAction
↑/↓Navigate through files
SpaceSelect/deselect file or folder
EnterConfirm selection and start AI tool
Ctrl+ASelect all files
Ctrl+DClear all selections
Esc or QCancel and exit

How It Works

  • File Tree Display - Shows your project structure in an interactive tree
  • Multi-Select - Use spacebar to select files and folders you want to work with
  • AI Integration - Automatically starts your chosen AI tool (Claude, Codex, etc.)
  • File Context - Selected files are automatically added using the tool's syntax (e.g., @file.js)
  • Interactive Session - You can then chat with the AI about your selected files

Example Workflow

$ treepick
# Interactive file tree appears
# Select src/components/Header.jsx
# Select src/utils/api.js  
# Select README.md
# Press Enter

🚀 Starting claude...
📎 Adding 3 files to claude...
✅ Files added successfully!

# Claude starts with: @src/components/Header.jsx @src/utils/api.js @README.md 
# You can now type: "Please review these files for potential bugs"

Configuration

The tool automatically ignores common directories:

  • node_modules
  • .git
  • .next
  • target
  • dist
  • build
  • .venv
  • __pycache__

Supported AI Tools

  • Claude Code (claude) - Anthropic's terminal coding assistant
  • OpenAI Codex (codex) - OpenAI's CLI coding tool
  • Google Gemini (gemini) - Google's CLI tool
  • Easily extensible for other tools

Requirements

  • Node.js 16+
  • The AI tool you want to use must be installed and accessible in PATH
    • For Claude Code: Follow installation guide
    • For OpenAI Codex: npm install -g @openai/codex
    • For Google Gemini: Install Google AI CLI

Installation

# Install globally from npm
npm install -g treepick

# Or for development
cd /path/to/treepick
npm install
npm link

Development

# Run in development mode
npm run dev

# Test with dry run
npm start -- --dry-run

License

MIT License - feel free to use and modify!

Contributing

This is an MVP - contributions welcome! Areas for improvement:

  • Better error handling
  • Configuration file support
  • More AI tool integrations
  • Performance optimizations
  • Tests

Made for developers who want to work smarter with AI tools 🚀

Keywords

claude-code

FAQs

Package last updated on 10 Aug 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts