-
Notifications
You must be signed in to change notification settings - Fork 144
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: remove games.txt and replace it with an in-code solution (#407)
* feat: remove games.txt and replace it with an in-code solution * docs: update changelog * chore: add todo comment regarding weird game ids to rename * fix: generate games list md file * fix: gemerate games list file to alphabetical id order * fix: update changelog to note removal of some game ids and add geneshift alternative
- Loading branch information
1 parent
2fb9f50
commit ce4cddb
Showing
7 changed files
with
2,456 additions
and
468 deletions.
There are no files selected for viewing
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { games } from './games.js' | ||
|
||
export const lookup = (type) => { | ||
if (!type) { throw Error('No game specified') } | ||
|
||
if (type.startsWith('protocol-')) { | ||
return { | ||
protocol: type.substring(9) | ||
} | ||
} | ||
|
||
const game = games[type] | ||
|
||
if (!game) { throw Error('Invalid game: ' + type) } | ||
|
||
return game.options | ||
} |
Oops, something went wrong.