Question

I'm looking at the lines of code estimate given in Git Extensions and I don't think it is counting the .cu and .cuh CUDA lines of code in those files.

How do I add the .cu and .cuh file extensions into the various Git Gui and Git Extensions tools?

Is there a special file I have to add *.cu and *.cuh into?

Was it helpful?

Solution

This looks like something that is specific to Git Extensions, not Git itself (Git cares very little about file types1).

I have not used Git Extensions, but a look through the source code turned up a likely candidate for the default list of extensions used in the statistics plugin. It looks like this is intended to be configurable, but I have not investigated the code enough to find out if it actually is configurable. Maybe it is only configurable through the registry? (somewhere under CurrentUser\Software\ GitExtensions\GitExtensions\<version>?)


1 Git does include a default set of “diff drivers” (and lets you define other such drivers) that locate the text to use after each “hunk header” (@@ -k,l +n,m @@ line) and how to break up words in “word diff” mode. Diff drivers are assigned via attribute (.gitattributes, $GIT_DIR/info/attributes, or (in Git 1.7.4 and later) /etc/gitattributes, or the file named by the core.attributesfile configuration variable), but they are not strictly based on extensions themselves (though that is, effectively, how most attributes are assigned in practice).

OTHER TIPS

You can edit list of code files extensions in Plugins > Settings > Statistics

Check your .gitingore file and your .gitexcludes.

As the exact path of the registry entry has not yet been posted here, I'll do it now: HKEY_CURRENT_USER\Software\GitExtensions\GitExtensions\StatisticsCode files

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top