Page MenuHomeWildfire Games

[gui] alphabetize credits
ClosedPublic

Authored by Nescio on Nov 16 2019, 7:58 PM.

Details

Reviewers
Stan
Group Reviewers
Restricted Owners Package(Owns No Changed Paths)
Commits
rP23281: Reorders the exceptions in the following files for consistency [EDIT]:
Summary

Today I clicked on “Credits” (which I think ought to be listed between “Scenario Editor” and “Exit”—not below “Donate”—but that's a different discussion) and noticed the programming credits were generally listed alphabetically, but not universally. The principles followed seem to be:

  • case-insensitive
  • numbers before letters
  • sorted by nick; if no nick, then sorted by first name

This patch reorders the exceptions in the following files for consistency [EDIT]:

  • art.json
  • history.json
  • programming.json

and also renames:

  • Hannibal_BaraqHannibal_Barca
  • LordgoodLordGood
  • stanislas69Stan
Test Plan

Check for mistakes and omissions.

Diff Detail

Repository
rP 0 A.D. Public Repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Nescio created this revision.Nov 16 2019, 7:58 PM
Owners added a subscriber: Restricted Owners Package.Nov 16 2019, 7:58 PM
Nescio added a subscriber: Stan.Nov 16 2019, 7:59 PM

Also, @Stan is in the credits listed as stanislas69.

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/589/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1105/display/redirect

Also, credits look ugly. It would be much better if nick and name were listed in two columns, the left one aligned to the right, the right to the left.
(Again, outside the scope of this patch.)

Freagarach added inline comments.
binaries/data/mods/public/gui/credits/texts/programming.json
224 ↗(On Diff #10341)

@Stan, you are now mostly called by Stan, ever thought about changing this? Or adding an aka?

(Sorry, totally missed your comment...)

elexis added a subscriber: elexis.EditedNov 23 2019, 3:27 PM

Check for mistakes and omissions.

How do I achieve that with a program or does performance of the test plan mean going through every line by hand?

I guess I can delete the nick and name prefix (copy paste into text editor then replace all occurrences of the prefix), then sort with a tool (https://alphabetizer.flap.tv/), then do the same with your patched list and compare if it's the same.
So I did run the test plan with that modification and came to the same result except for the two inline comments.

Also the sorting order is kind of irrelevant in the JSON file, the sorting can be performed programmatically.
But I agree the inconsistent order is bothering people when they insert a new author.

Also the whitespace is inconsistent, I guess that can be done in a separate commit, to make the change more visible.

The patch also only updates programming.json, but as noted before stanislas69 is incorrectly ordered in Map Making.

In 2D Art there are also many entries incorrectly ordered.

At this point I wonder whether it's really worth to make an effort to sort these in the database rather than adding 2 lines of JS code to sort them for display?

refs D2436

Updated programming.json:

binaries/data/mods/public/gui/credits/texts/programming.json
36 ↗(On Diff #10341)

Mikołaj is not sorted correctly

60 ↗(On Diff #10341)

Daniel 2 lines lower

Nescio updated this revision to Diff 10393.Nov 23 2019, 3:47 PM
Nescio retitled this revision from Alphabetize programming credits to Alphabetize credits.
Nescio edited the summary of this revision. (Show Details)

Also alphabetized art and misc credits, but not special (I assume the order is chronological), nor donators or translators (I assume they're generated via a script).

Nescio edited the summary of this revision. (Show Details)Nov 23 2019, 3:48 PM

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/630/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1146/display/redirect

Stan added inline comments.Nov 23 2019, 3:55 PM
binaries/data/mods/public/gui/credits/texts/programming.json
224 ↗(On Diff #10341)

Well it doesn't matter much, but if you feel like changing it change it to 'Stan`'

How do I achieve that with a program or does performance of the test plan mean going through every line by hand?

Opening the file and scrolling down works; at least that's what I did (twice).

Also the whitespace is inconsistent

Where?

But I agree the inconsistent order is bothering people when they insert a new author.

Exactly!

Also the sorting order is kind of irrelevant in the JSON file, the sorting can be performed programmatically.
At this point I wonder whether it's really worth to make an effort to sort these in the database rather than adding 2 lines of JS code to sort them for display?

Adding two lines is easier for programmers like you, but not for me; my understanding of javascript is very limited at best.
Also, what if someone wants to sort one list differently, e.g. chronologically?

binaries/data/mods/public/gui/credits/texts/programming.json
36 ↗(On Diff #10341)

I assumed “Bajter” counted as a nickname, but you're right.

60 ↗(On Diff #10341)

Nice catch!

Nescio added inline comments.Nov 23 2019, 4:05 PM
binaries/data/mods/public/gui/credits/texts/programming.json
224 ↗(On Diff #10341)

Your name here on phabricator is Stan, though, without the backtick, and that's how you appear in the commit logs.
@elexis, I suppose there is no option to list two nicks for one name?

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/631/display/redirect

Stan added inline comments.Nov 23 2019, 4:14 PM
binaries/data/mods/public/gui/credits/texts/programming.json
224 ↗(On Diff #10341)

Well there is at least always a capital :) Some stuff like the lobby doesn't allow me to have the backtick.

Yes according to this Aeros (aka CheeZy)

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/632/display/redirect

Nescio added inline comments.Nov 23 2019, 4:17 PM
binaries/data/mods/public/gui/credits/texts/programming.json
224 ↗(On Diff #10341)

That's ugly, because it could be interpreted as if aka is part of the nick.

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1147/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1148/display/redirect

Nescio edited the summary of this revision. (Show Details)Nov 23 2019, 4:22 PM
Nescio updated this revision to Diff 10398.Nov 23 2019, 5:15 PM
Nescio edited the summary of this revision. (Show Details)

Rebased and updated:

  • LordgoodLordGood
  • Hannibal_BaraqHannibal_Barca

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/633/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1149/display/redirect

Stan accepted this revision.Dec 16 2019, 12:36 PM

I'm alright being credited as Stan. The backtick can be omitted as I don't consider part of the nickname as it's mostly for distinction on IRC.

This revision is now accepted and ready to land.Dec 16 2019, 12:36 PM
Stan added a comment.Dec 24 2019, 12:46 AM

I'm sorry was too slow, can you rebase?

Itms added a subscriber: Itms.Dec 24 2019, 10:01 AM

Thanks for the work!

A question though: I thought Hannibal_Baraq and Hannibal_Barca were two different persons. I believe that the former contributed some code and art a while ago, while the latter is our current lobby moderator. Seeing the name in the balancing credits makes me doubt myself, but I'd like to make sure about this...

Stan added a comment.Dec 24 2019, 10:18 AM

They actually might be two different persons D362. @elexis would know...

Itms added a comment.Dec 24 2019, 10:29 AM

Hm I just checked on Trac and I was probably confused. The Phab revisions are all from the lobby moderator and references on Trac all point to him as well. I was thinking we had a H_Baraq contributor way back then, in the 2013s or something, but I'm wrong.

Please ignore me :)

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/884/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1400/display/redirect

Stan accepted this revision.Dec 24 2019, 5:29 PM
Nescio retitled this revision from Alphabetize credits to [gui] alphabetize credits.May 18 2020, 10:27 AM