Searchcode Server includes a database which can be modified to identify file types by extension or by explicit file name. The file is ./include/classifier/database.json
and must be a valid JSON file.
The fields that are used are the following,
To add an explicit file name matcher you could add following entry to the file.
{
"language": "Jenkins Buildfile",
"extensions": [
"jenkinsfile"
],
"keywords": []
}
which would mark any file named "jenkinsfile" ignoring case as being of the language/type "Jenkins File".
To mark files by extension you could use an entry like the following.
{
"language": "HTML",
"extensions": [
"htm",
"html"
],
"keywords": ["nbsp", "class", "span", "font", "href", "html", "name", "title", "the", "bgcolor"]
}
Which could mark any file with the extension of html or html as being HTML.