For now? I'm experimenting on an old concept.
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Got started on a dev mode.


Signed-off-by: MLC Bloeiman <mar@strawmelonjuice.com>

+28 -2
+3 -1
Justfile
··· 67 67 [group("local-devel")] 68 68 local-devel-prep: create-data-dirs 69 69 dbmate up 70 - 70 + # I don't know if I want to build for the devmode script? 71 + # May also make the user from the app, if debug mode is detected. 72 + touch data/debug 71 73 72 74 [doc("Run the server in development mode")] 73 75 [group("local-devel")]
+18
server/dev/devmode.gleam
··· 1 + import gleam/string 2 + import simplifile 3 + import sqlight 4 + 5 + /// This will generate the testing username-password combinations defined in the README, as well 6 + /// as a `/data/debug` file, which sets log levels to... Yup! To debug instead of Info 7 + pub fn main() { 8 + case simplifile.create_file("../data/debug") { 9 + Ok(..) | Error(simplifile.Eexist) -> Nil 10 + Error(fuck) -> { 11 + let fucking_error = string.inspect(fuck) 12 + panic as fucking_error 13 + } 14 + } 15 + use db <- sqlight.with_connection("../data/instance.db") 16 + // todo as "The database changes for creating a user are yet unknown." 17 + Nil 18 + }
+7 -1
server/src/lumina_server.gleam
··· 73 73 } 74 74 75 75 pub fn main() { 76 + let debug = simplifile.is_file("/data/debug") == Ok(True) 76 77 use db <- sqlight.with_connection("/data/instance.db") 77 78 // At some point everything should go here, I think. 78 79 // woof.set_sink(woof.beam_logger_sink) ··· 90 91 91 92 // Logging 92 93 woof.configure(woof.Config( 93 - level: woof.Debug, 94 + level: { 95 + case debug { 96 + True -> woof.Debug 97 + False -> woof.Info 98 + } 99 + }, 94 100 format: woof.Text, 95 101 colors: woof.Auto, 96 102 ))