Skip to content

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Sep 19, 2025

GitHub was incorrectly identifying the Shimmy repository as a "Makefile" project instead of "Rust" due to the overwhelming number of build-generated dependency files. The Rust build system creates 530+ .d files with Makefile syntax that were dominating GitHub's language detection algorithm, despite the repository containing 57 actual Rust source files.

This PR adds a .gitattributes file that:

  • Prioritizes Rust detection by explicitly marking *.rs files as linguist-detectable=true
  • Excludes build artifacts by setting *.d dependency files and Makefile variants as linguist-detectable=false
  • Marks generated files like target/, Cargo.lock, and profiling data as linguist-generated=true
  • Preserves important config files by keeping .toml, .yml, and .yaml files detectable

The configuration has been tested with git check-attr to ensure proper pattern matching, and the project continues to build successfully. This follows Git linguist best practices for language override and addresses the core issue with minimal changes.

Fixes #55.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

@Copilot Copilot AI changed the title [WIP] [Enhancement]: add a .gitattributes file to override GitHub’s language detection. Add .gitattributes file to override GitHub's language detection from Makefile to Rust Sep 19, 2025
Copilot finished work on behalf of Michael-A-Kuykendall September 19, 2025 22:28
@Michael-A-Kuykendall Michael-A-Kuykendall merged commit 6c8c3ca into main Sep 19, 2025
Michael-A-Kuykendall pushed a commit that referenced this pull request Oct 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Enhancement]: add a .gitattributes file to override GitHub’s language detection.

2 participants