Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions templates/github-connector/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/versions

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# env files (can opt-in for committing if needed)
.env*

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts

supabase/.temp/
23 changes: 23 additions & 0 deletions templates/github-connector/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# GitHub x Echo Connector

Powered by Echo for LLM generations.

## Getting Started

First, run the development server:

```bash
pnpm dev
```

## GitHub App Integration

Set the following environment variables for the GitHub App flow:
Create a [GitHub App](https://github.com/settings/apps/new).

```bash
GITHUB_APP_ID=123456
GITHUB_APP_SLUG=your-app-slug
# Private key in PKCS8 format. If multi-line, use \n escaped newlines.
GITHUB_APP_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n"
```
22 changes: 22 additions & 0 deletions templates/github-connector/components.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"$schema": "https://ui.shadcn.com/schema.json",
"style": "new-york",
"rsc": true,
"tsx": true,
"tailwind": {
"config": "",
"css": "src/app/globals.css",
"baseColor": "neutral",
"cssVariables": true,
"prefix": ""
},
"iconLibrary": "lucide",
"aliases": {
"components": "@/components",
"utils": "@/lib/utils",
"ui": "@/components/ui",
"lib": "@/lib",
"hooks": "@/hooks"
},
"registries": {}
}
15 changes: 15 additions & 0 deletions templates/github-connector/env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@

GITHUB_APP_ID=1926031
GITHUB_APP_SLUG=echo-merit-ranker
GITHUB_APP_PRIVATE_KEY=""

# Supabase (Service role key is required for server-side upserts)
SUPABASE_URL=
SUPABASE_SERVICE_ROLE_KEY=
SUPABASE_DB_PASSWORD=
SUPABASE_PROJECT_REF=

# Webhooks & State
GITHUB_WEBHOOK_SECRET=
GITHUB_APP_STATE_SECRET=
NEXT_PUBLIC_APP_URL=http://localhost:3000
25 changes: 25 additions & 0 deletions templates/github-connector/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import { dirname } from "path";
import { fileURLToPath } from "url";
import { FlatCompat } from "@eslint/eslintrc";

const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);

const compat = new FlatCompat({
baseDirectory: __dirname,
});

const eslintConfig = [
...compat.extends("next/core-web-vitals", "next/typescript"),
{
ignores: [
"node_modules/**",
".next/**",
"out/**",
"build/**",
"next-env.d.ts",
],
},
];

export default eslintConfig;
13 changes: 13 additions & 0 deletions templates/github-connector/next.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import type { NextConfig } from 'next';
import { dirname } from 'path';
import { fileURLToPath } from 'url';

const __dirname = dirname(fileURLToPath(import.meta.url));

const nextConfig: NextConfig = {
turbopack: {
root: __dirname,
},
};

export default nextConfig;
56 changes: 56 additions & 0 deletions templates/github-connector/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
{
"name": "github-connector",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev --turbopack",
"build": "next build --turbopack",
"start": "next start",
"lint": "eslint",
"db:migrate": "tsx scripts/migrate.ts",
"db:link": "npx supabase@latest link",
"db:migrate:cli": "npx supabase@latest db push"
},
"dependencies": {
"@ai-sdk/react": "^2.0.39",
"@merit-systems/echo-next-sdk": "^0.0.9",
"@octokit/app": "^16.1.0",
"@octokit/auth-app": "^8.1.0",
"@octokit/core": "^7.0.3",
"@octokit/webhooks": "^14.1.3",
"@radix-ui/react-collapsible": "^1.1.12",
"@radix-ui/react-dropdown-menu": "^2.1.16",
"@radix-ui/react-select": "^2.2.6",
"@radix-ui/react-slot": "^1.2.3",
"@radix-ui/react-use-controllable-state": "^1.2.2",
"@supabase/supabase-js": "^2.57.4",
"ai": "^5.0.39",
"class-variance-authority": "^0.7.1",
"clsx": "^2.1.1",
"dotenv": "^17.2.2",
"jose": "^6.1.0",
"lucide-react": "^0.543.0",
"next": "15.5.2",
"pg": "^8.16.3",
"react": "19.1.0",
"react-dom": "19.1.0",
"shiki": "^3.12.2",
"streamdown": "^1.2.0",
"tailwind-merge": "^3.3.1"
},
"devDependencies": {
"@eslint/eslintrc": "^3",
"@octokit/types": "^14.1.0",
"@tailwindcss/postcss": "^4",
"@types/node": "^20",
"@types/pg": "^8.15.5",
"@types/react": "^19",
"@types/react-dom": "^19",
"eslint": "^9",
"eslint-config-next": "15.5.2",
"tailwindcss": "^4",
"tsx": "^4.20.5",
"tw-animate-css": "^1.3.8",
"typescript": "^5"
}
}
Loading