summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorRyan Kavanagh <rak@rak.ac>2020-05-30 19:16:03 -0400
committerRyan Kavanagh <rak@rak.ac>2020-05-31 00:04:48 -0400
commitc760484c1abfed9cd85db8ec5eb4d659ad16ba2a (patch)
tree3997432e131028c5947687b0722304fb739558db /bin
parentInitial import of a text/gemini parser (diff)
Added a build system and adopt modules
Diffstat (limited to '')
-rw-r--r--bin/dune4
-rw-r--r--bin/leda.ml20
2 files changed, 24 insertions, 0 deletions
diff --git a/bin/dune b/bin/dune
new file mode 100644
index 0000000..ddff424
--- /dev/null
+++ b/bin/dune
@@ -0,0 +1,4 @@
+(executable
+ (public_name leda)
+ (name main)
+ (libraries base gemini))
diff --git a/bin/leda.ml b/bin/leda.ml
new file mode 100644
index 0000000..139f5fe
--- /dev/null
+++ b/bin/leda.ml
@@ -0,0 +1,20 @@
+module M = Gemini.MimeTextGemini
+
+let test_gemini = "\
+ => /blah mylink\r\n\
+ => /blah\r\n\
+ ```\r\n\
+ preformatted\r\n\
+ ``` ending preformatted text\r\n\
+ some text\r\n\
+ more text\r\n\
+ \r\n\
+ * unordered list\r\n"
+
+let _ = print_endline test_gemini
+
+let _ = print_endline "\n\n...gets parsed as...\n\n"
+
+let test_parse s = s (* M.gemini_to_str (M.str_to_gemini s) *)
+
+let _ = print_endline (test_parse test_gemini)