diff --git a/admin/sync/themes.go b/admin/sync/themes.go index b76952ec..620f44fb 100644 --- a/admin/sync/themes.go +++ b/admin/sync/themes.go @@ -3,6 +3,7 @@ package sync import ( "fmt" "path" + "regexp" "strings" "srs.epita.fr/fic-server/libfic" @@ -32,7 +33,17 @@ func getAuthors(i Importer, tname string) ([]string, error) { if authors, err := getFileContent(i, path.Join(tname, "AUTHORS.txt")); err != nil { return nil, err } else { - return strings.Split(strings.TrimSpace(authors), "\n"), nil + var ret []string + re := regexp.MustCompile("^([^<]+)(?: +<(.*)>)?$") + for _, a := range strings.Split(strings.TrimSpace(authors), "\n") { + grp := re.FindStringSubmatch(a) + if len(grp) < 2 || grp[2] == "" { + ret = append(ret, a) + } else { + ret = append(ret, fmt.Sprintf("%s", grp[2], grp[1])) + } + } + return ret, nil } } diff --git a/frontend/static/css/fic.css b/frontend/static/css/fic.css index 3ec67c86..673c11f2 100644 --- a/frontend/static/css/fic.css +++ b/frontend/static/css/fic.css @@ -126,6 +126,10 @@ a:hover .teamname { text-shadow: 0px 0px 10px #888888; } +.authors a { + color: #3A3F44; +} + .heading { font-style: italic; margin-top: -7px; diff --git a/frontend/static/index.html b/frontend/static/index.html index 23352d85..ebe6a4d2 100644 --- a/frontend/static/index.html +++ b/frontend/static/index.html @@ -92,7 +92,7 @@