## 为什么
35534b1 把 logs/*.log.gz(10 个)与 __pycache__/*.pyc(18 个)
一起提交了,而仓库**根本没有 .gitignore** —— 那不是手误,是缺一道门。
已 `git rm --cached` 那 28 个(磁盘文件保留,只是不再跟踪)。
## 覆盖三类
① 运行期产物:logs/ *.log.gz __pycache__/ .pytest_cache/ …
② **加载器/mod 的运行时配置**:config/ shaderpacks/ options.txt saves/
datapacks/ resourcepacks/
★ 这类属于**实例**,不属于仓库。实测踩过:Sodium 往**进程 cwd**
写了 config/sodium-mixins.properties,落进了仓库根。
根因已修(base.py:cwd=self.cwd or self.game_dir,让运行时产物
落进实例目录),这里再兜一层。
③ 构建缓存:.mcfold-tools/ build/ dist/ *.egg-info/
29 lines
905 B
Plaintext
29 lines
905 B
Plaintext
# ── 运行期产物(绝不该进版本库)────────────────────────────
|
||
# ★ 这两类都曾被误提交过(35534b1 把 logs/ 与 __pycache__/ 一起带进去,
|
||
# 共 28 个文件)—— 根因是没有 .gitignore。
|
||
logs/
|
||
*.log
|
||
*.log.gz
|
||
|
||
__pycache__/
|
||
*.py[cod]
|
||
.pytest_cache/
|
||
.mypy_cache/
|
||
.ruff_cache/
|
||
|
||
# ── 加载器/mod 的运行时配置(属于**实例**,不属于仓库)────────
|
||
# ★ Sodium 等会往**进程 cwd** 写 config/;正确落点应是实例目录
|
||
# (base.py 已修:cwd=self.cwd or self.game_dir)。这里再兜一层。
|
||
config/
|
||
shaderpacks/
|
||
options.txt
|
||
saves/
|
||
datapacks/
|
||
resourcepacks/
|
||
|
||
# ── 构建/工具缓存 ─────────────────────────────────────────
|
||
.mcfold-tools/
|
||
build/
|
||
dist/
|
||
*.egg-info/
|