Skip to content

Simple deno server to fetch the contents of a github repo and create a single json representation. Created to supply ChatGPT context of my github repositories through Custom GPT function calling.

Notifications You must be signed in to change notification settings

cameronking4/gh-repo-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fetch Github Repo for ChatGPT context

Download the OpenAI yaml and add to your gpt or chat to begin fetching public Github repos. Clone this repo and self host using DenoDeploy to pull private Github repos using your PAT.

Demo

Screen.Recording.2024-08-03.at.2.48.54.PM.mov

Deno Deploy Server

This Deno server application uses the Oak framework to create a simple API for fetching and displaying the contents of a GitHub repository. The API exposes an endpoint to retrieve the contents of a specified repository, including files and directories, but excludes certain file types (e.g., images and videos).

Features

  • Fetch contents of a specified GitHub repository.
  • Recursively retrieve and display directory contents.
  • Exclude certain file types from retrieval.
  • Return file contents in JSON format.

Prerequisites

  • Deno runtime installed. Install Deno
  • A GitHub Personal Access Token (PAT) with access to the desired repositories.

Environment Variables

  • GITHUB_PAT: Your GitHub Personal Access Token.

Installation

  1. Clone the repository:

    git clone https://github.com/cameronking4/gh-repo-server.git
    cd gh-repo-server

About

Simple deno server to fetch the contents of a github repo and create a single json representation. Created to supply ChatGPT context of my github repositories through Custom GPT function calling.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published