.gitignore 里原本写的是 `./outputs` —— gitignore 不认 `./` 前缀,整条规则失效, 于是 247 个产物(预览快照、截图、历史 review 报告)一直被跟踪, 每次跑 TestGenPreview 都会脏一遍工作区。 改成 `/outputs/` 并 git rm -r --cached outputs:索引里删除,磁盘文件全部保留。 克隆者不再拿到这些一次性产物;需要预览快照时跑 TEST_PREVIEW=1 go test ./templates -run TestGenPreview 重新生成。
35 lines
783 B
Plaintext
35 lines
783 B
Plaintext
# ---> Go
|
|
# If you prefer the allow list template instead of the deny list, see community template:
|
|
# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore
|
|
#
|
|
# Binaries for programs and plugins
|
|
*.exe
|
|
*.exe~
|
|
*.dll
|
|
*.so
|
|
*.dylib
|
|
|
|
# Test binary, built with `go test -c`
|
|
*.test
|
|
|
|
# Output of the go coverage tool, specifically when used with LiteIDE
|
|
*.out
|
|
|
|
# Dependency directories (remove the comment below to include it)
|
|
# vendor/
|
|
|
|
# Go workspace file
|
|
go.work
|
|
go.work.sum
|
|
|
|
# env file
|
|
.env
|
|
|
|
# otherfile
|
|
./workbuddy
|
|
./scripts
|
|
# 注意:gitignore 不认 "./" 前缀,/outputs 才是「仓库根下的 outputs」。
|
|
# outputs 里全是 TestGenPreview / 主题生成器 / 截图这类一次性产物,
|
|
# 每次跑都会变,跟版本库无关。
|
|
/outputs/
|