Skip to content

Commit 0db1d21

Browse files
authored
Merge branch 'InvolutionHell:main' into yoyo
2 parents c1960a2 + cc13065 commit 0db1d21

File tree

115 files changed

+6293
-589
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+6293
-589
lines changed

.github/workflows/sync-uuid.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: Docs Backfill (on docs changes)
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- feat/contributor
8+
paths:
9+
- "app/docs/**"
10+
- "scripts/uuid.mjs"
11+
- "scripts/backfill-contributors.mjs"
12+
- "package.json"
13+
- "pnpm-lock.yaml"
14+
- ".github/workflows/sync-uuid.yml"
15+
- "generated/doc-contributors.json"
16+
workflow_dispatch: {}
17+
18+
concurrency:
19+
group: backfill-${{ github.ref }}
20+
cancel-in-progress: true
21+
22+
jobs:
23+
backfill:
24+
# 防止 fork、限定 main、并避免机器人循环
25+
if: github.repository == 'InvolutionHell/involutionhell.github.io' &&
26+
(github.ref == 'refs/heads/main' || github.ref == 'refs/heads/feat/contributor') &&
27+
github.actor != 'github-actions[bot]'
28+
runs-on: ubuntu-latest
29+
permissions:
30+
contents: write
31+
env:
32+
DATABASE_URL: ${{ secrets.DATABASE_URL }}
33+
GITHUB_TOKEN: ${{ secrets.GH_PAT }} # 供脚本调用 GitHub API 提升速率
34+
DOCS_DIR: app/docs
35+
36+
steps:
37+
- uses: actions/checkout@v4
38+
39+
- uses: pnpm/action-setup@v4
40+
with:
41+
version: 9
42+
43+
- uses: actions/setup-node@v4
44+
with:
45+
node-version: 20
46+
cache: "pnpm" # 顺便启用 pnpm 缓存,加速
47+
48+
- name: Install deps
49+
run: pnpm install --frozen-lockfile
50+
51+
- name: Generate Prisma Client
52+
run: pnpm prisma generate
53+
54+
- name: Ensure docId frontmatter
55+
run: pnpm exec node scripts/uuid.mjs
56+
57+
- name: Backfill contributors & sync DB
58+
run: pnpm exec node scripts/backfill-contributors.mjs
59+
60+
- name: Auto-commit doc metadata (if any)
61+
uses: stefanzweifel/git-auto-commit-action@v5
62+
with:
63+
commit_message: "chore(docs): sync doc metadata [skip ci]" # ← 防循环
64+
file_pattern: "app/docs/**/*.md app/docs/**/*.mdx generated/doc-contributors.json"
65+
66+
- name: Upload snapshot JSON
67+
uses: actions/upload-artifact@v4
68+
with:
69+
name: doc-contributors-snapshot
70+
path: generated/doc-contributors.json
71+
if-no-files-found: ignore

app/components/Contributors.tsx

Lines changed: 60 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,25 @@
11
import Image from "next/image";
22
import Link from "next/link";
3+
import type { DocContributorsRecord } from "@/lib/contributors";
34

4-
interface Contributor {
5-
login: string;
6-
avatar_url: string;
7-
html_url: string;
5+
interface ContributorsProps {
6+
entry: DocContributorsRecord | null;
87
}
98

10-
export function Contributors({
11-
contributors,
12-
}: {
13-
contributors: Contributor[];
14-
}) {
9+
function formatLastContributedAt(value: string | null) {
10+
if (!value) return null;
11+
const date = new Date(value);
12+
if (Number.isNaN(date.getTime())) return null;
13+
return new Intl.DateTimeFormat("zh-CN", {
14+
year: "numeric",
15+
month: "2-digit",
16+
day: "2-digit",
17+
}).format(date);
18+
}
19+
20+
export function Contributors({ entry }: ContributorsProps) {
21+
const contributors = entry?.contributors ?? [];
22+
1523
if (contributors.length === 0) {
1624
return null;
1725
}
@@ -21,25 +29,54 @@ export function Contributors({
2129
<hr className="border-border/70 !mt-10 !mb-5" />
2230
<h2 id="contributors-heading">贡献者</h2>
2331
<ul className="mt-0 mb-0 flex flex-wrap items-center gap-x-6 gap-y-4 list-none p-0">
24-
{contributors.map((contributor) => (
25-
<li key={contributor.login}>
26-
<Link
27-
href={contributor.html_url}
28-
target="_blank"
29-
rel="noopener noreferrer"
30-
className="inline-flex items-center gap-3 text-base font-medium text-primary transition-colors hover:text-primary/80 no-underline"
31-
>
32+
{contributors.map((contributor) => {
33+
const displayName = contributor.login ?? `#${contributor.githubId}`;
34+
const href = contributor.htmlUrl ?? undefined;
35+
const avatarSrc =
36+
contributor.avatarUrl ??
37+
`https://avatars.githubusercontent.com/u/${contributor.githubId}`;
38+
const lastDate = formatLastContributedAt(
39+
contributor.lastContributedAt,
40+
);
41+
42+
const content = (
43+
<>
3244
<Image
33-
src={contributor.avatar_url}
34-
alt={contributor.login}
45+
src={avatarSrc}
46+
alt={displayName}
3547
width={35}
3648
height={35}
3749
className="!m-0 h-10 w-10 rounded-full border border-border/50 object-cover shadow-sm"
3850
/>
39-
<span>{contributor.login}</span>
40-
</Link>
41-
</li>
42-
))}
51+
<span className="flex flex-col text-left leading-tight">
52+
<span className="font-medium">{displayName}</span>
53+
<span className="text-sm text-muted-foreground">
54+
贡献 {contributor.contributions}
55+
{lastDate ? ` · 最近 ${lastDate}` : ""}
56+
</span>
57+
</span>
58+
</>
59+
);
60+
61+
return (
62+
<li key={contributor.githubId}>
63+
{href ? (
64+
<Link
65+
href={href}
66+
target="_blank"
67+
rel="noopener noreferrer"
68+
className="inline-flex items-center gap-3 text-base text-primary transition-colors hover:text-primary/80 no-underline"
69+
>
70+
{content}
71+
</Link>
72+
) : (
73+
<div className="inline-flex items-center gap-3 text-base">
74+
{content}
75+
</div>
76+
)}
77+
</li>
78+
);
79+
})}
4380
</ul>
4481
<hr className="!mb-0 !mt-5 border-border/70" />
4582
</section>

app/components/GiscusComments.tsx

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,25 @@
1-
'use client';
1+
"use client";
22

3-
import Giscus from '@giscus/react';
3+
import Giscus from "@giscus/react";
44

55
interface GiscusCommentsProps {
66
className?: string;
7+
docId?: string | null;
78
}
89

9-
export function GiscusComments({ className }: GiscusCommentsProps) {
10+
export function GiscusComments({ className, docId }: GiscusCommentsProps) {
11+
const normalizedDocId = typeof docId === "string" ? docId.trim() : "";
12+
const useSpecificMapping = normalizedDocId.length > 0;
13+
1014
return (
1115
<div className={className}>
1216
<Giscus
1317
repo="InvolutionHell/involutionhell.github.io"
1418
repoId="R_kgDOPuD_8A"
1519
category="Comments"
1620
categoryId="DIC_kwDOPuD_8M4Cvip8"
17-
mapping="pathname"
21+
mapping={useSpecificMapping ? "specific" : "pathname"}
22+
term={useSpecificMapping ? normalizedDocId : undefined}
1823
strict="0"
1924
reactionsEnabled="1"
2025
emitMetadata="0"
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
title: 学生邮箱能免费领的AI提效工具系列
3+
description: ""
4+
date: "2025-10-03"
5+
tags:
6+
- edu-email
7+
- ai-tools
8+
- productivity
9+
docId: mgb41edhi9cz1kxzae074an0
10+
---
11+
12+
学生邮箱能免费领取很多AI产品,
13+
这两年靠着免费体验,有几款AI工具已经融入了我的生活,对我的工作效率蛮有帮助
14+
所以打算开个栏目,分享一下这些AI产品和使用经验,帮大家把学费的钱薅回来。
15+
16+
目前这个系列能想到的暂时只有3款产品,想不到的说明用处不大,就不提了。
17+
按使用频率从高到低来排是:perplexity Comet, Cursor, V0.dev
18+
19+
写完这三款产品,后面应该会不局限于学生免费,去分享一些别的对我很有用的免费/付费产品:gemini cli, codex等
Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
---
2+
title: Perplexity Comet 浏览器:能当私人管家的自动化浏览器
3+
description: ""
4+
date: "2025-10-03"
5+
tags:
6+
- perlexity
7+
- comet
8+
- productivity
9+
docId: eej2awin6irhbdgcy8vvs3xb
10+
---
11+
12+
## 关键信息
13+
14+
**学生免费一年领取地址:[Get Comet with free Perplexity Pro. The AI browser built for students.](https://www.perplexity.ai/students)**
15+
到这个链接,领取一年的Perplexity会员,
16+
然后你就可以下载他们的Comet浏览器来使用了:
17+
[Comet Browser: a Personal AI Assistant](https://www.perplexity.ai/comet/)
18+
19+
## Comet 介绍
20+
21+
该系列的第一篇是Perplexity Comet,一个AI浏览器。
22+
因为它的使用频率是最高的,甚至超越了cursor,毕竟是要天天打开的浏览器。
23+
24+
目前市面上的AI浏览器还比较多,什么Dia,微软的Edge也做成了AI浏览器,Chrome也在发力中。
25+
但我跟别人了解了一下,也许是得益于Perplexity的早早布局,Comet有一些很强大的别的浏览器做不到的功能。
26+
![ab3becf9-fe7f-40f3-92f3-8e861e68f1fc.png](https://img.coly.cc/obs-img/2025/10/1df9eb3648e7893e32c0139de7ad5a6d.png)
27+
28+
它的牛逼之处在于主要有两点
29+
30+
1. 能够帮我操作浏览器,做一点我懒得做的工作——虽然精准度和速度不一定好,但好处就是可以把任务丢给它然后自己去做别的事情,
31+
2. 替换掉我的滴答清单,成为安排我一天工作的管家:整合邮件,整合近期事项,提醒我。
32+
33+
### 浏览器自动操作
34+
35+
它的浏览器自动操作有两种方式:
36+
37+
1. 后台自动访问页面并执行工作
38+
2. 前台直接对你当前的页面自动化操作
39+
40+
#### 后台的使用案例
41+
42+
帮你翻邮件,翻Moodle课程网站自动查分等
43+
44+
如果你提前登录过Moodle,你可以直接在它的输入框里要求它:
45+
![image.png](https://img.coly.cc/obs-img/2025/10/2979472a93976749b4f45b5960906c57.png)
46+
![image.png](https://img.coly.cc/obs-img/2025/10/bff8830b849d3d64ad5ee40f4eb589d8.png)
47+
然后你能看到它正在后台一步步地访问对应页面并执行对应的操作
48+
![image.png](https://img.coly.cc/obs-img/2025/10/5e31b513d633a1383ef637293e320c3e.png)
49+
最后得到结果。
50+
51+
同理,你还可以让它帮你查邮箱,把垃圾邮件删除之类的工作。这里就不一一举例了,你理解意思了,就知道这个后台AI能做哪些活了。
52+
注意Comet浏览器默认会用自研的模型,效果很一般,记得自己手动换成目前最牛逼的模型:
53+
![image.png](https://img.coly.cc/obs-img/2025/10/aeba741491cad07e3c105db3f49cdf1a.png)
54+
55+
#### 前台的使用案例
56+
57+
自动操作Coles,将清单里的商品一一加入购物车。
58+
![8c574a67ac53577520eb8758b7e892a5.png](https://img.coly.cc/obs-img/2025/10/0759eb80fe077ad310c0f235bf8843c3.png)
59+
用法是打开登录好的coles页面,点击右上角的Assistant按钮,然后给他下指令:把xxx加入购物车
60+
然后你就会看见页面上浮现一个蓝框,它吭哧吭哧地开始工作了。
61+
虽然是前台,但你依然可以切到其他页面去,该干啥干啥
62+
其实我也没搞懂前后台有啥区别,但效果好像是有些页面后台操作不够精准,容易出错,前台的话会精准一点。
63+
64+
### 连接邮箱,日历的私人管家
65+
66+
现在我每天早上起来的第一件事,就是在输入框输入我自己定义好的命令
67+
![image.png](https://img.coly.cc/obs-img/2025/10/98605f02a120be2cb67a090c85a40b2b.png)
68+
提醒我啥时候该收衣服,悉尼雨季多次被淋透衣服的痛……
69+
提醒我啥时候换汇划算
70+
提醒我最近有啥事要做
71+
帮我整理邮件
72+
73+
你首先到设置,连接器里添加好你的账号,我主要用的是谷歌服务,如果还有别的东西你也用,那么它一样可以连接起来优化你的效率。
74+
![image.png](https://img.coly.cc/obs-img/2025/10/ed069ee778622782832ed06b947c24d6.png)
75+
76+
然后去设置里添加一个快捷方式,这样后面每天就不用手动输一大段prompt,直接打几个命令就能执行了。
77+
![image.png](https://img.coly.cc/obs-img/2025/10/feb661e4aa4c71b5cf2c68fd5284f294.png)
78+
79+
效果是这样的:
80+
![image.png](https://img.coly.cc/obs-img/2025/10/26eb7f9cb633787058b0efe5ecfa86e6.png)
81+
![image.png](https://img.coly.cc/obs-img/2025/10/751ab79cce1abfd9c194d09666cb6061.png)
82+
还是蛮方便的。
83+
84+
我最喜欢的就是日历连接功能,自从用上它以后,滴答清单就彻底不用了,谷歌日历也不打开了,课表之类的会自动添加到日历的事件,它会提醒。你有自己的事件要记录,也可以直接跟他对话,提醒我xxxx
85+
![image.png](https://img.coly.cc/obs-img/2025/10/8feab1d5662ba82d64855d47b46cb949.png)
86+
它会帮你记录在你的日历里,然后每日命令执行时候,发现最近会有事件,就会在对话里提醒你,并且还能通过浏览器通知+email的方式一起提醒,很难忘事了。
87+
88+
## Perplexity 介绍
89+
90+
除了Comet以外,Perplexity其实本身是一家做AI搜索引擎的公司,所以除了浏览器,它本身的产品也蛮好用的,但跟GPT啥的相比也没有特别显著的优势,但好在是各家模型都能随便用,还算是一个很不错的AI chat.
91+
![image.png](https://img.coly.cc/obs-img/2025/10/544381e5bde62b83b952ce3ad96b3820.png)
92+
93+
## 下期预告
94+
95+
最高频的 Perplexity Comet 讲完了,下一个是Cursor,主题应该是目前许多人最关心的,开发新手怎么样快速做项目,能帮助快速充实自己的简历。
96+
这玩意真的是神,用了它的这一年里我快速完成了好多质量不错的项目。
97+
但缺点就是长期依赖下,个人的代码能力会变弱……
98+
所以我其实很犹豫要不要讲Cursor。

app/docs/CommunityShare/Geek/CommonUsedMarkdown.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: 常用Markdown语法
3-
date: 2025-09-20 14:25:39
3+
date: 2025-09-20T14:25:39.000Z
4+
docId: xqz5iiv3p52h6d9g3c0w2baf
45
---
56

67
## 基础标题+字体样式

app/docs/CommunityShare/Geek/Katex/Seb1.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: 个人常用字符
3-
date: 2025-09-20 14:25:39
3+
date: 2025-09-20T14:25:39.000Z
4+
docId: r0inttjcby48tly602p410vo
45
---
56

67
## 希腊字母

app/docs/CommunityShare/Geek/Katex/Seb2.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: 数学公式语法
3-
date: 2025-09-20 14:25:39
3+
date: 2025-09-20T14:25:39.000Z
4+
docId: khcrztruqdku9fntd3dwzvwe
45
---
56

67
## 求和、求积、二项式

app/docs/CommunityShare/Geek/Katex/index.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: 常用Katex语法
3-
date: 2025-09-20 14:25:39
3+
date: 2025-09-20T14:25:39.000Z
4+
docId: yxd2qpfl2li6092bjx8bz7vb
45
---
56

67
Katex 与 Latex 有些许的不同,稍作整理以便自己查阅

0 commit comments

Comments
 (0)