Commit Graph

9 Commits

Author SHA1 Message Date
ekzyis 845157c954 Add market form + page
* market form with question, description and end date
* markets cost 1k sats
* a goroutine polls pending invoices from the db and checks LND for their status
* markets are listed on front page (after paid)
* market page contains buttons to bet yes or no
* users have names now

TODO:
* show correct market percentage
* show how percentage changed over time in chart
* validate end date
* implement betting / order form
2024-08-24 02:35:15 -05:00
ekzyis db23fbb64a Use hex-encoded tls cert and macaroon 2024-07-15 08:00:57 +02:00
ekzyis ee3e5e82e4 Remove old code
* removed code that will not be used
* removed code that will most likely be rewritten
2024-07-12 11:00:51 +02:00
ekzyis 3d3ae16617 Index page with templ 2024-07-10 04:47:25 +02:00
ekzyis 5f0ddbcbd7 Formatting with blank lines 2024-07-09 12:32:22 +02:00
ekzyis bba752601b Make network configurable 2023-11-23 00:13:51 +01:00
ekzyis 1351439a15 Run invoice checks on startup 2023-11-20 00:38:52 +01:00
ekzyis c66e96bf3f refactor: fix init and use DI
* fix init misuse which makes running tests impossible since tests are run inside a temporary test directory which breaks env loading

* use dependency injection pattern for server creation and global server context in route handlers
2023-11-03 20:34:21 +01:00
ekzyis 7558655458 refactor: Structure code into different packages
I have put too much code into the same files.

Also, I put everything into the same package: main.

This package is only meant for executables.

Therefore, I have refactored my code to use multiple packages. These packages also guarantee separation of concerns since Golang doesn't allow cyclic imports.
2023-09-10 23:13:08 +02:00