Make WordPress Core

Opened 2 years ago

Last modified 7 months ago

#55973 new enhancement

Add .gitattributes file to annotate generated files

Reported by: swissspidy's profile swissspidy Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords:
Focuses: Cc:


To make development on GitHub easier, we could consider adding a .gitattributes file for annotating generated files.

The linguist-generated attribute can be used to mark or unmark paths that should be ignored for the repository's language statistics and hidden by default in diffs.

See for more details

This came to mind when reviewing

Change History (2)

#1 @desrosj
7 months ago

@swissspidy could you give an example of a file you'd want to ignore or hide?

#2 @swissspidy
7 months ago

For example

  • tests/qunit/fixtures/wp-api-generated.js
  • src/wp-includes/blocks/require-dynamic-blocks.php
  • src/wp-includes/blocks/require-static-blocks.php
  • src/js/_enqueues/vendor/codemirror
  • All other block files copied from Gutenberg
Note: See TracTickets for help on using tickets.