From c28817dd4881cc6a3b16f0de0296a9bc63967020 Mon Sep 17 00:00:00 2001 From: zhangtao25 Date: Thu, 21 Nov 2024 15:31:15 +0800 Subject: [PATCH] chore: repo overall update --- .../canyon-platform/app/api/sourcecode/route.ts | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/packages/canyon-platform/app/api/sourcecode/route.ts b/packages/canyon-platform/app/api/sourcecode/route.ts index 7388a49a..ff300b38 100644 --- a/packages/canyon-platform/app/api/sourcecode/route.ts +++ b/packages/canyon-platform/app/api/sourcecode/route.ts @@ -1,22 +1,7 @@ -// export const dynamic = 'force-static' -// import prisma from "@/lib/prisma"; -// import {decompressedData} from "@/utils/zstd"; - -import axios from "axios"; +import prisma from "@/lib/prisma"; import { getFileInfo } from "@/utils/gitlab.adapter"; import { NextRequest } from "next/server"; -const owner = "canyon-project"; -const repo = "canyon"; -const path = "packages/canyon-report/src/index.tsx"; -const sha = "f721bf684d49254717e03ca14e53a1b1f8882019"; -const token = "YOUR_PERSONAL_ACCESS_TOKEN"; -const url = `https://api.github.com/repos/${owner}/${repo}/contents/${path}?ref=${sha}`; -const headers = { - // Authorization: `token ${token}`, - // Accept: "application/vnd.github.v3+json", -}; - export async function GET(request: NextRequest) { const { searchParams } = request.nextUrl; const projectID = searchParams.get("project_id");