Linguist: C# is recognized as Prolog

Created on 20 Jul 2018  路  7Comments  路  Source: github/linguist

Preliminary Steps

Problem Description

My PostDredge repository is written in C# but linguist says it's Prolog. I thought waiting for a few days will correct the issue but it's been almost a month.

URL of the affected repository: https://github.com/gldd-se/PostDredge

Last modified on: 2018-07-19

Expected language: C

Detected language: Prolog

Most helpful comment

Issue fixed! Thank you @lildude @pchaigno

All 7 comments

C# but linguist says it's Prolog

Not quite. Linguist is saying Prolog is the predominant language based on bytes of code 馃槈, and it is because you have three heeeeawg Prolog files in your repo:

  • src/Gldd.PostDredge.IntegrationTests/EI_20180617.pro = 37.59MB
  • src/Gldd.PostDredge.IntegrationTests/LB_180525.pro = 12.41MB
  • src/Prototypes/Reporting/Demo/LB_180525.pro = 12.41MB

You'll need to implement an override if you don't want these files to count as they are being correctly identified.

@lildude I don't think those are Prolog files.

@gojanpaolo You'll want to mark those files as vendored to ignore them in statistics.

I guessed they were based on the .pro extension. I didn't even try examining the content as their size wouldn't render on GitHub anyway 馃榿

Ahh! It never occurred to me that it was cause by the test files. Thanks for pointing that out. :) I'll try to override those and close this issue once it's fixed. :)

predominant language based on bytes of code

Should that be included in the How Linguist Works documentation? My initial thought was that it was based on the number of files.

Should that be included in the How Linguist Works documentation? My initial thought was that it was based on the number of files.

It already is. The very last sentence before the pretty picture:

The percentages are calculated based on the bytes of code for each language as reported by the List Languages API.

Issue fixed! Thank you @lildude @pchaigno

Was this page helpful?
0 / 5 - 0 ratings

Related issues

GabLeRoux picture GabLeRoux  路  6Comments

philiparvidsson picture philiparvidsson  路  4Comments

FranklinYu picture FranklinYu  路  4Comments

haskellcamargo picture haskellcamargo  路  3Comments

Haroenv picture Haroenv  路  4Comments