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

fileflow-clitool

v1.0.2

Published

A smart CLI tool to organize files, bulk rename, convert data formats, and automate repetitive file tasks.

Readme

FileFlow CLI

A smart command-line tool to automate repetitive file tasks — organize, rename, convert, and find duplicates in seconds.

Node.js License Status


Features

| Command | Description | |---|---| | organize | Auto-sort files into folders by type, date, or size | | rename | Bulk rename using templates, find/replace, or case conversion | | convert | Convert data files between CSV, JSON, and Excel | | duplicates | Find and remove duplicate files using MD5 hashing | | watch | Monitor a folder and auto-process new files |


Installation

Global install (recommended)

Install once, use fileflow anywhere on your system:

npm install -g fileflow-clitool
# Then use directly:
fileflow --help
fileflow organize ./downloads
fileflow rename ./photos --find "IMG_" --replace "photo_"

Local install (per project)

Install into a specific project folder:

npm install fileflow-clitool
# Use via npx (no -g required):
npx fileflow --help
npx fileflow organize ./downloads
npx fileflow rename ./photos --find "IMG_" --replace "photo_"

| | Global (-g) | Local (no -g) | |---|---|---| | Command | fileflow ... | npx fileflow ... | | Available from | Anywhere | Only inside that project folder | | Best for | End users | Scripts / CI pipelines |

Clone and link locally (for development)

git clone https://github.com/Vall-Here/fileflow-cli.git
cd fileflow-cli
npm install
npm link

Usage

organize — Sort files into folders

# Sort by file type (images, documents, videos...)
fileflow organize ./downloads

# Sort by month (2024-01, 2024-02...)
fileflow organize ./photos --by date

# Sort by size (small, medium, large, huge)
fileflow organize ./downloads --by size

# Preview without moving anything
fileflow organize ./downloads --dry-run

# Include subdirectories
fileflow organize ./downloads --recursive

rename — Bulk rename files

# Rename with a template
fileflow rename ./invoices --pattern "invoice_{date}_{index:3}"
# → invoice_2024-01-15_001.pdf, invoice_2024-01-16_002.pdf

# Find and replace in filenames
fileflow rename ./photos --find "IMG_" --replace "photo_"
# → photo_001.jpg, photo_002.jpg

# Change case style
fileflow rename ./docs --case kebab
# → my-document.pdf, another-file.txt

# Only rename .jpg files
fileflow rename ./photos --case snake --ext jpg

# Preview first
fileflow rename ./files --pattern "{name}_{date}" --dry-run

Template tokens:

| Token | Description | Example | |---|---|---| | {name} | Original filename (no extension) | report | | {ext} | File extension | pdf | | {index} | Sequential number | 1, 2, 3 | | {index:3} | Zero-padded number | 001, 002 | | {date} | File modification date | 2024-01-15 | | {timestamp} | Unix timestamp | 1705276800 |

convert — Convert data files

# Single file
fileflow convert data.csv --to json
fileflow convert data.json --to xlsx
fileflow convert data.xlsx --to csv

# Batch convert entire folder
fileflow convert ./data-folder --to json

# Specify Excel sheet
fileflow convert report.xlsx --to csv --sheet "Sales Q4"

# Custom output directory
fileflow convert data.csv --to json --output ./output

# Minify JSON output
fileflow convert data.csv --to json --minify

duplicates — Find and clean duplicates

# Find duplicates (report only)
fileflow duplicates ./downloads

# Include subdirectories
fileflow duplicates ./photos --recursive

# Preview what would be deleted
fileflow duplicates ./downloads --delete --dry-run

# Actually delete duplicates (keeps first copy)
fileflow duplicates ./downloads --delete

watch — Auto-process new files

# Watch and auto-organize by file type
fileflow watch ./downloads

# Watch and organize by date
fileflow watch ./inbox --by date

Project Structure

fileflow-cli/
├── bin/
│   └── fileflow.js          # CLI entry point
├── src/
│   ├── commands/
│   │   ├── organize.js      # File organizer
│   │   ├── rename.js        # Bulk renamer
│   │   ├── convert.js       # Data converter
│   │   ├── duplicates.js    # Duplicate finder
│   │   └── watch.js         # Folder watcher
│   └── utils/
│       ├── fileHelpers.js   # Shared file utilities
│       └── logger.js        # Consistent CLI output
├── tests/
│   └── commands/
│       └── organize.test.js
├── package.json
└── README.md

Development

# Run tests
npm test

# Run tests in watch mode
npm run test:watch

# Lint code
npm run lint

# Run locally without installing
node bin/fileflow.js organize ./test-folder

🛠️ Tech Stack


Roadmap

  • [ ] Config file support (.fileflowrc)
  • [ ] Plugin system for custom actions
  • [ ] Image resize/compress command
  • [ ] Undo last operation
  • [ ] Interactive mode with prompts

License

MIT © Ahmad Noval


Contributing

Pull requests welcome! Please open an issue first to discuss major changes.

git checkout -b feature/your-feature
npm test
git commit -m "feat: add your feature"
git push origin feature/your-feature