npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@aryanbhosale/pick

v0.1.26

Published

Extract, filter, and transform values from JSON, YAML, TOML, .env, HTTP headers, logfmt, CSV, and more

Readme

pick

npm downloads CI License: MIT

Extract values from anything — JSON, YAML, TOML, .env, HTTP headers, logfmt, CSV, and more.

npm install -g @aryanbhosale/pick

pick auto-detects the input format and lets you extract, filter, and transform values using a unified selector syntax. Think of it as jq for all config formats.

Usage

# JSON
curl -s https://api.github.com/users/octocat | pick login
# octocat

# .env
cat .env | pick DATABASE_URL
# postgres://localhost:5432/mydb

# YAML
cat config.yaml | pick server.port
# 8080

# TOML
cat Cargo.toml | pick package.version
# 0.1.0

# HTTP headers
curl -sI https://example.com | pick content-type
# text/html; charset=UTF-8

# logfmt
echo 'level=info msg="request handled" status=200' | pick status
# 200

# CSV
cat data.csv | pick '[0].name'
# Alice

Selectors

| Syntax | Description | |---|---| | foo | Top-level key | | foo.bar | Nested key | | foo[0] | Array index | | foo[-1] | Last element | | foo[*].name | All elements, pluck field | | foo[1:3] | Array slice (elements 1 and 2) | | ..name | Recursive descent — find name at any depth | | [0] | Index into root array | | "dotted.key".sub | Quoted key (for keys containing dots) | | name, age | Multiple selectors (union) |

Pipes & Filters

# Filter: find expensive items
cat data.json | pick 'items[*] | select(.price > 100) | name'

# Regex match
cat data.json | pick 'items[*] | select(.email ~ "@gmail") | name'

# Boolean logic
cat data.json | pick 'users[*] | select(.age >= 18 and .active) | name'

# Builtins
cat config.json | pick 'keys()'
cat config.json | pick 'dependencies | length()'

Mutation

# Set a value
cat config.json | pick 'set(.version, "2.0")' --json

# Delete a key
cat config.json | pick 'del(.temp)' --json

Output Formats

cat data.json | pick -o yaml    # Convert to YAML
cat data.json | pick -o toml    # Convert to TOML

Streaming (JSONL)

cat events.jsonl | pick 'user.name' --stream
cat logs.jsonl | pick 'select(.level == "error") | message' --stream

Flags

| Flag | Description | |---|---| | -i, --input <format> | Force input format (json, yaml, toml, env, headers, logfmt, csv, text) | | -o, --output <format> | Output format (json, yaml, toml) | | -f, --file <path> | Read from file instead of stdin | | --json | Output result as JSON | | --raw | Output without trailing newline | | -1, --first | Only first result | | --lines | One element per line | | -d, --default <value> | Fallback value | | -q, --quiet | Suppress error messages | | -e, --exists | Check if selector matches (exit code only) | | -c, --count | Count matches | | --stream | Stream mode: process JSONL line-by-line |

Supported Formats

JSON, YAML, TOML, .env, HTTP headers, logfmt, CSV/TSV, and plain text. Format is auto-detected — use -i to override.

Links

License

MIT