mirror of
https://github.com/TriliumNext/Trilium.git
synced 2026-10-12 02:09:59 +00:00
edit-docs now writes docs/, the help HTML and the demo with LF, but only part of those trees carried an eol attribute. The rest was left to core.autocrlf, which checks them out with CRLF on Windows, so every export flipped them back and forth: 214 text files, among them the JavaScript, SVG and JSX attachments and the whole demo tree. The flip is invisible in a diff and still shows up in git status, because the index caches each file's size and reports a size mismatch as modified without comparing content, then never refreshes the cached size on its own. Staging is what clears it. Cover the three generated trees with text=auto eol=lf, which also replaces six demo/** rules that matched nothing, the demo living under apps/edit-docs/. No committed blob in those trees holds CRLF, so nothing is restaged; text=auto keeps the images and other binary attachments out of the conversion, verified by checking a PNG, an SVG and a DAT attachment out and comparing them against their blobs. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
24 lines
1001 B
Plaintext
24 lines
1001 B
Plaintext
# Mark files as auto-generated to simplify reviews.
|
|
package-lock.json linguist-generated=true
|
|
**/package-lock.json linguist-generated=true
|
|
apps/server/src/assets/doc_notes/en/User[[:space:]]Guide/** linguist-generated
|
|
|
|
# Ignore from GitHub language stats.
|
|
apps/server/src/assets/doc_notes/** linguist-vendored=true
|
|
apps/edit-docs/demo/** linguist-vendored=true
|
|
docs/** linguist-vendored=true
|
|
|
|
# Normalize line endings. edit-docs writes the three generated trees with LF, so they have to
|
|
# check out with LF too — otherwise every export leaves them looking modified on Windows.
|
|
# `text=auto` keeps the images and other binary attachments they contain out of the conversion.
|
|
patches/** eol=lf
|
|
docs/** text=auto eol=lf
|
|
apps/server/src/assets/doc_notes/** text=auto eol=lf
|
|
apps/edit-docs/demo/** text=auto eol=lf
|
|
*.sh eol=lf
|
|
|
|
# Always diff TypeScript sources as text so a stray control byte (e.g. a NUL in
|
|
# a string literal) doesn't make Git/GitHub treat the whole file as binary.
|
|
*.ts diff
|
|
*.tsx diff
|