X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=scripts%2Fgenerate-code-contributors.ts;h=5635d988952e052131507e0fe0ef92be6cf3cc29;hb=18ec47d48c591d3ccb015a1a519243b692abb74d;hp=8493d3d0ca2e04f7d74203c66452e6a8334325ea;hpb=2aaa1a3fdc49be77aec5309dab5507865c38d392;p=github%2FChocobozzz%2FPeerTube.git diff --git a/scripts/generate-code-contributors.ts b/scripts/generate-code-contributors.ts index 8493d3d0c..5635d9889 100755 --- a/scripts/generate-code-contributors.ts +++ b/scripts/generate-code-contributors.ts @@ -1,8 +1,10 @@ import { registerTSPaths } from '../server/helpers/register-ts-paths' + registerTSPaths() import { doRequest } from '../server/helpers/requests' import { readFileSync } from 'fs-extra' +import { uniqBy } from 'lodash' run() .then(() => process.exit(0)) @@ -89,5 +91,5 @@ async function fetchZanata (zanataUsername: string, zanataPassword: string) { get(year2019, headers) ]) - return results2018.concat(results2019) + return uniqBy(results2018.concat(results2019) as { username: string }[], 'username') }