Skip to content

Commit 22ac71c

Browse files
committed
[i18n] Patch Lunaria package to allow cloning private repos
1 parent 0ed1d6f commit 22ac71c

File tree

3 files changed

+25
-4
lines changed

3 files changed

+25
-4
lines changed

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,8 @@
129129
"starlight-openapi": "patches/starlight-openapi.patch",
130130
"@scalar/api-client": "patches/@scalar__api-client.patch",
131131
132-
"@vercel/node": "patches/@vercel__node.patch"
132+
"@vercel/node": "patches/@vercel__node.patch",
133+
"@lunariajs/[email protected]": "patches/@[email protected]"
133134
},
134135
"overrides": {
135136
"vite": "^6",

patches/@[email protected]

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
diff --git a/dist/status/git.mjs b/dist/status/git.mjs
2+
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
3+
--- a/dist/status/git.mjs
4+
+++ b/dist/status/git.mjs
5+
@@ -22,7 +22,11 @@ async function handleShallowRepo({ cloneDir, repository }) {
6+
const target = resolve(cloneDir);
7+
if (existsSync(target))
8+
rmSync(target, { recursive: true, force: true });
9+
- await git.clone(gitHostingLinks.clone(), target, ["--bare", "--filter=blob:none"]);
10+
+ const token = process.env.GITHUB_TOKEN;
11+
+ const cloneUrl = token
12+
+ ? `https://${token}@github.com/${repository.name}.git`
13+
+ : gitHostingLinks.clone();
14+
+ await git.clone(cloneUrl, target, ["--bare", "--filter=blob:none"]);
15+
await git.cwd({ path: target, root: true });
16+
}
17+
return isShallowRepo;

pnpm-lock.yaml

Lines changed: 6 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)