File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change 10641064 "description" : " Use garavatar icons in log viewers" ,
10651065 "default" : true
10661066 },
1067+ "svn.gravatar.icon_url" : {
1068+ "type" : " string" ,
1069+ "description" : " Url for the gravitar icon using the <AUTHOR>, <AUTHOR_MD5> and <SIZE> placeholders" ,
1070+ "examples" : [
1071+ " https://www.gravatar.com/avatar/<AUTHOR_MD5>.jpg?s=<SIZE>&d=https%3A%2F%2Fui-avatars.com%2Fapi%2F/<AUTHOR>/128"
1072+ ],
1073+ "default" : " https://www.gravatar.com/avatar/<AUTHOR_MD5>.jpg?s=<SIZE>&d=robohash"
1074+ },
10671075 "svn.ignoreMissingSvnWarning" : {
10681076 "type" : " boolean" ,
10691077 "description" : " Ignores the warning when SVN is missing" ,
Original file line number Diff line number Diff line change @@ -214,9 +214,13 @@ export function getCommitIcon(
214214 return gravatar ;
215215 }
216216
217- gravatar = Uri . parse (
218- `https://www.gravatar.com/avatar/${ md5 ( author ) } .jpg?s=${ size } &d=robohash`
219- ) ;
217+ const gravitarUrl = configuration
218+ . get ( "gravatar.icon_url" , "" )
219+ . replace ( "<AUTHOR>" , author )
220+ . replace ( "<AUTHOR_MD5>" , md5 ( author ) )
221+ . replace ( "<SIZE>" , size . toString ( ) ) ;
222+
223+ gravatar = Uri . parse ( gravitarUrl ) ;
220224
221225 gravatarCache . set ( author , gravatar ) ;
222226
You can’t perform that action at this time.
0 commit comments