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 🙏

© 2024 – Pkg Stats / Ryan Hefner

gitload-txt

v1.0.7

Published

Generate summaries of GitHub repositories including file contents

Downloads

470

Readme

gitload-txt

Generate enriched, AI-ready summaries of GitHub repositories as text files. Perfect for use with AI-powered IDEs like Cursor and other development tools.

npm version License: MIT

Features

  • 📦 Download any public GitHub repository as an enriched text summary
  • 🔍 Smart filtering of relevant code and documentation
  • 📝 Includes key architectural decisions and patterns
  • 🏷️ Auto-generated tags for better organization
  • 🚀 Compatible with popular AI coding assistants
  • 💻 Simple CLI interface

Installation

npm install -g gitload-txt

Usage

Basic usage:

gitload https://github.com/username/repository

This will create a repository-name.txt file in a repos folder in your current directory with an enriched summary of the repository.

Output Format

The generated text file includes:

  1. Repository Overview

    • Basic information
    • Main technologies used
    • Architecture overview
    • Dependencies
  2. Code Structure

    • Directory layout
    • Key files and their purposes
    • Important patterns and conventions
  3. Documentation Summary

    • README highlights
    • API documentation
    • Contributing guidelines
    • License information
  4. Auto-generated Tags (when --tags is used)

    • Technology stack
    • Programming paradigms
    • Architecture patterns
    • Domain categories

Example Output

Repository: awesome-project
URL: https://github.com/username/awesome-project
Generated: 2024-12-04

OVERVIEW
========
A Node.js backend service using Express.js and MongoDB...

ARCHITECTURE
============
- Microservices architecture
- REST API endpoints
- JWT authentication
- Redis caching layer

KEY COMPONENTS
=============
/src
  /routes - API endpoint definitions
  /controllers - Business logic
  /models - MongoDB schemas
  /middleware - Auth and validation
  /utils - Helper functions

[... continues with more detailed information ...]

TAGS
====
#nodejs #express #mongodb #microservices #jwt #redis

Using with AI IDEs

Cursor

  1. Import the generated text file into your Cursor workspace
  2. Use @repository-name.txt to query the summary
  3. Generate code based on the repository

Other AI IDEs

The generated summaries are compatible with most AI-powered development tools that accept context in text format.

Configuration

Create a .gitloadrc file in your home directory to set default options:

{
  "outputDir": "./summaries",
  "defaultDepth": "detailed",
  "includeTags": true,
  "excludePatterns": ["*.test.js", "*.spec.js"],
  "maxFileSize": "10mb"
}

API Usage

You can also use gitload-txt programmatically in your Node.js applications:

const { generateSummary } = require('gitload-txt');

async function getSummary() {
  try {
    const summary = await generateSummary('https://github.com/username/repository', {
      depth: 'detailed',
      includeTags: true
    });
    console.log(summary);
  } catch (error) {
    console.error('Error generating summary:', error);
  }
}

Contributing

Contributions are welcome! Please read our Contributing Guide for details on our code of conduct and the process for submitting pull requests.

Development Setup

# Clone the repository
git clone https://github.com/username/gitload-txt

# Install dependencies
npm install

# Run tests
npm test

# Build the project
npm run build

License

This project is licensed under the MIT License - see the LICENSE file for details.

Credits

Created and maintained by Siddhant Paliwal

Support

Changelog

See CHANGELOG.md for a list of changes and migration guides.

Roadmap

  • [ ] Custom summary templates
  • [ ] pip package
  • [ ] Enhanced code analysis features