fork of https://github.com/sourcegraph/zoekt
1package languages
2
3import "strings"
4
5// This file contains private functions
6// vendored from the go-enry codebase.
7
8// convertToAliasKey is vendored from go-enry to make sure
9// we're normalizing strings the same way.
10func convertToAliasKey(langName string) string {
11 ak := strings.SplitN(langName, `,`, 2)[0]
12 ak = strings.Replace(ak, ` `, `_`, -1)
13 ak = strings.ToLower(ak)
14 return ak
15}