add game slugs and playtime support for them - #1186
Open
itzTheMeow wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
followup to #1182 without the architectural changes
adds a "slug" property to metadata files which is attached to a game
the slug is not unique, multiple games can have the same slug and they will simply share playtime
slugs are normalized to lowercase and spaces removed
if a slug is set on a game, it will be used to store plays in the database for all of the files of the game, overriding any paths/uris
existing plays using uri/path are NOT migrated to the slug pattern, they are just aggregated
also did a quick test for read/write of playtime using slugs
games have their own
play_stats_selfmember which contain play stats added to that specific game independent of any filesthis is summed in along with the individual game file play stats for the total playtime/stats on the game
slugs stored in the database have
pg-slug:prepended to them to differentiate them from paths and other URIswill follow up with a docs PR if approved
closes #1097
closes #1182