[liuhui998/gitbook] c65c46: 修复构建系统并迁移到 kramdown + GFM

0 views
Skip to first unread message

liuhui

unread,
Dec 11, 2025, 8:49:02 AM (5 days ago) Dec 11
to gitbo...@googlegroups.com
Branch: refs/heads/master
Home: https://github.com/liuhui998/gitbook
Commit: c65c46510657fe54479000f57e33ef16017e6339
https://github.com/liuhui998/gitbook/commit/c65c46510657fe54479000f57e33ef16017e6339
Author: Peter.Liu <liuh...@gmail.com>
Date: 2025-12-11 (Thu, 11 Dec 2025)

Changed paths:
A CLAUDE.md
M Gemfile
M Gemfile.lock
M README.md
M script/html.rb
M script/merge.rb
M text_zh/01_Introduction/00_Section_Introduction.markdown
M text_zh/05_Installing_Git/00_Section.markdown
M text_zh/06a_Getting_A_Repo/00_Section_Basic_Usage.markdown
M text_zh/12a_Ignoring_Files/00_Section_Intermediate_Usage.markdown
M text_zh/24_Creating_New_Empty_Branches/00_Section_Advanced_Git.markdown
M text_zh/31_Git_Hooks/0_ Git_Hooks.markdown
M text_zh/35_Git_on_Windows/00_Section_Working_with_Git.markdown
M text_zh/48_How_Git_Stores_Objects/00_Section_Internals_and_Plumbing.markdown

Log Message:
-----------
修复构建系统并迁移到 kramdown + GFM

主要改进:
- 迁移 markdown 解析器:rdiscount → kramdown + kramdown-parser-gfm
- 修复 Ruby 3.2+ 兼容性问题(rdiscount 无法编译)
- 修复章节生成问题:现在正确生成全部 7 个章节(之前只有 5 个)
- 修复代码块格式:将 tab 缩进改为 GFM 三反引号格式
- 修复章节标题格式:添加缺失的空格(# 后需要空格)
- 新增 CLAUDE.md:为未来的 AI 助手提供项目文档和构建指南
- 改进 README.md:添加完整的构建说明和项目结构文档

技术细节:
- script/html.rb:启用 GFM 支持,修复 HTML 解析正则,修复 Builder 语法
- script/merge.rb:修复换行符(\r\n → \n\n)确保 kramdown 正确识别块
- text_zh/31_Git_Hooks:修复导致解析器错误的 tab 缩进代码块
- 8 个章节标题文件:统一格式,确保 # 后有空格

现在构建完全正常,生成完整的 7 章内容和所有子章节。



To unsubscribe from these emails, change your notification settings at https://github.com/liuhui998/gitbook/settings/notifications
Reply all
Reply to author
Forward
0 new messages