Add .gitattributes to enforce consistent line endings

This commit is contained in:
Misaka
2026-03-04 22:19:06 +08:00
parent 2dea1f9556
commit e49191d531
2 changed files with 18 additions and 1 deletions

17
.gitattributes vendored Normal file
View File

@@ -0,0 +1,17 @@
* text=auto
# Force Unix line endings for source files
*.md text eol=lf
*.ts text eol=lf
*.js text eol=lf
*.json text eol=lf
*.yml text eol=lf
*.tsx text eol=lf
*.jsx text eol=lf
*.css text eol=lf
*.scss text eol=lf
*.html text eol=lf
# Force Windows line endings for build artifacts
*.bat text eol=crlf
*.cmd text eol=crlf

View File

@@ -356,7 +356,7 @@ export class ExcelParser {
// Extract material data // Extract material data
const material = this.parseMaterialRowInternal(allRows[dataRow], dataRow + 1) const material = this.parseMaterialRowInternal(allRows[dataRow], dataRow + 1)
if (material) { if (material) {
this.log(' Parsed material:', material.materialCode) //this.log(' Parsed material:', material.materialCode)
materials.push(material) materials.push(material)
} else { } else {
this.log(' Skipped material row at', dataRow + 1) this.log(' Skipped material row at', dataRow + 1)