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

@ofi/ledger-cli

v1.0.1

Published

CLI tools to download OFi / Open Collective transactions and convert them to hledger journals

Readme

@ofi/ledger-cli

CLI tools to download OFi / Open Collective transactions and convert them to hledger journals for double-entry accounting.

Tools

| Command | Description | | ------------------------------------------------------ | ------------------------------------------------------ | | ofi-hledger | All-in-one: download, convert, and query journals | | ofi-csv-download | Download transaction CSVs from the Open Collective API | | ofi-hledger-convert | Convert CSVs to hledger journal files | | ofi-balance-download | Download opening balances from the API | | ofi-ledger-cli-init | Initialize an account directory |

Configuration: ofi-ledger.config.js | Rules: rules

Prerequisites

  • Node.js 24+
  • hledger (brew install hledger)
  • (Optional) A PERSONAL_TOKEN from https://opencollective.com/applications for private data
npm install -g @ofi/ledger-cli

Quick start

# Recent data only (recommended for first use)
ofi-hledger eslint --auto --from 2024-01-01 bs

# All history (downloads from oldest transaction)
ofi-hledger eslint --auto bs

This initializes the account directory, downloads transactions and opening balances, converts to a journal, then queries the balance sheet. Without --from, it downloads from the oldest transaction date (set by init in config).

Step by step

Each account lives in its own directory with an ofi-ledger.config.js:

eslint/
  ofi-ledger.config.js
  rules-eslint.js          # optional custom rules
  eslint-opening-balances.csv
  2025/
  2026/
  eslint-transactions.journal

1. Download transactions

ofi-csv-download eslint

2. Convert to journal

ofi-hledger-convert eslint

3. Query

ofi-hledger eslint bs    # Balance sheet
ofi-hledger eslint is    # Income statement

Batch processing

ofi-hledger-convert ofico ofitech opensource raft phpfoundation

Development

npm run lint          # ESLint
npm run lint:fix      # ESLint auto-fix
npm run prettier:check
npm run prettier:write
npm run graphql:update  # Fetch latest GraphQL schema

License

MIT