# Git attributes file for libfrankapy
# This file controls how Git handles line endings and other file attributes
# across different platforms (Windows, Linux, macOS)

# Default behavior: Let Git automatically handle line endings
* text=auto

# Source code files - ensure consistent LF line endings
*.py text eol=lf
*.cpp text eol=lf
*.hpp text eol=lf
*.c text eol=lf
*.h text eol=lf
*.pyx text eol=lf
*.pxd text eol=lf
*.pxi text eol=lf

# Configuration and data files
*.yml text eol=lf
*.yaml text eol=lf
*.json text eol=lf
*.toml text eol=lf
*.cfg text eol=lf
*.ini text eol=lf
*.conf text eol=lf
*.xml text eol=lf

# Documentation files
*.md text eol=lf
*.rst text eol=lf
*.txt text eol=lf
*.rtf text eol=lf

# Build and project files
*.cmake text eol=lf
CMakeLists.txt text eol=lf
Makefile text eol=lf
*.mk text eol=lf
*.in text eol=lf
*.am text eol=lf
*.ac text eol=lf

# Python specific files
requirements*.txt text eol=lf
setup.py text eol=lf
setup.cfg text eol=lf
pyproject.toml text eol=lf
MANIFEST.in text eol=lf
*.pyi text eol=lf

# Git and CI files
.gitignore text eol=lf
.gitattributes text eol=lf
.pre-commit-config.yaml text eol=lf

# Shell scripts (Unix line endings)
*.sh text eol=lf
*.bash text eol=lf
*.zsh text eol=lf
*.fish text eol=lf

# Windows batch files (Windows line endings)
*.bat text eol=crlf
*.cmd text eol=crlf
*.ps1 text eol=crlf

# Binary files - do not modify
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.ico binary
*.svg binary
*.pdf binary
*.zip binary
*.tar binary
*.gz binary
*.bz2 binary
*.xz binary
*.7z binary
*.rar binary
*.exe binary
*.dll binary
*.so binary
*.dylib binary
*.a binary
*.lib binary
*.o binary
*.obj binary
*.pyc binary
*.pyo binary
*.pyd binary
*.whl binary
*.egg binary

# Font files
*.ttf binary
*.otf binary
*.woff binary
*.woff2 binary
*.eot binary

# Audio/Video files
*.mp3 binary
*.mp4 binary
*.avi binary
*.mov binary
*.wav binary
*.flac binary

# Archive and package files
*.tar.gz binary
*.tar.bz2 binary
*.tar.xz binary
*.tgz binary
*.tbz2 binary

# IDE and editor files
*.code-workspace text eol=lf
*.vscode/* text eol=lf
*.idea/* text eol=lf

# Special handling for specific files
# License files should use LF
LICENSE text eol=lf
COPYING text eol=lf
CHANGELOG* text eol=lf
README* text eol=lf
CONTRIBUTING* text eol=lf

# Jupyter notebooks - treat as text but don't convert line endings
*.ipynb text

# Data files - usually should not be modified
*.csv text
*.tsv text
*.dat binary
*.bin binary
*.npy binary
*.npz binary
*.pkl binary
*.pickle binary

# Log files
*.log text

# Temporary and cache files
*.tmp binary
*.cache binary
*.swp binary
*.swo binary
*~ binary

# Language specific attributes
# Ensure Python files are detected correctly
*.py linguist-language=Python
*.pyx linguist-language=Python
*.pxd linguist-language=Python
*.pxi linguist-language=Python

# Ensure C++ files are detected correctly
*.cpp linguist-language=C++
*.hpp linguist-language=C++
*.cc linguist-language=C++
*.cxx linguist-language=C++
*.hxx linguist-language=C++

# Documentation files for GitHub linguist
docs/* linguist-documentation
*.md linguist-documentation
*.rst linguist-documentation

# Generated files should not be included in language statistics
*_pb2.py linguist-generated
*_pb2_grpc.py linguist-generated
*.pb.go linguist-generated
