Skip to content

feat(route/1lou): add keyword search route#22660

Open
JaggerH wants to merge 1 commit into
DIYgod:masterfrom
JaggerH:feature-1lou
Open

feat(route/1lou): add keyword search route#22660
JaggerH wants to merge 1 commit into
DIYgod:masterfrom
JaggerH:feature-1lou

Conversation

@JaggerH

@JaggerH JaggerH commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Involved Issue / 该 PR 相关 Issue

Close #

Example for the Proposed Route(s) / 路由地址示例

/1lou/search/奥本海默

New RSS Route Checklist / 新 RSS 路由检查表

  • New Route / 新的路由
  • Anti-bot or rate limit / 反爬/频率限制
    • If yes, do your code reflect this sign? / 如果有, 是否有对应的措施?
  • Date and time / 日期和时间
    • Parsed / 可以解析
    • Correct time zone / 时区正确
  • New package added / 添加了新的包
  • Puppeteer

Note / 说明

Adds a keyword search route for 1lou (BT 之家). The site exposes a plain GET search at https://www.1lou.me/search.htm?keyword=<keyword>, and its result rows use the exact same li.media.thread.tap markup as the forum listings that the existing /1lou/:params route already parses.

To avoid duplicating that listing + per-thread detail parse, I extracted it into lib/routes/1lou/util.ts (fetchThreads) and reuse it from both the existing generic route and the new /search/:keyword route. The keyword is a path parameter (not a custom query parameter). Detail fetches use cache.tryGet, dates go through parseDate + timezone(+8), and each item carries its .torrent enclosure.

Verified: /1lou/search/奥本海默 returns 20 threads, each with a .torrent enclosure.

1lou.me exposes a GET keyword search at search.htm?keyword=<kw> whose
results are the same li.media.thread.tap markup as the forum listings, so
the existing listing+detail parse applies unchanged. Extract that parse
into util.ts (fetchThreads) and reuse it from both the generic route and a
new /search/:keyword route (keyword as a path param).

Verified: /1lou/search/奥本海默 returns 20 threads with .torrent enclosures.
@github-actions github-actions Bot added the route label Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant