You are browsing as a guest. Sign up (or log in) to start making projects!

jojk

  • 6 Devlogs
  • 15 Total hours

A markup language with parser written in haskell

Ship #1 Pending review

Jojk is a markup interpreter for a markup langage i made. I used this project to learn haskell, so i had lots of issues along the way, but i made it through.

Some of the features are:

  • Output to both HTML and Markdown
  • User specified output file
  • Nested commands
  • Completely deterministic

Getting command nesting to work was difficult, and it still dosent work for edge cases (edge cases being about half the cases)

This project only works on linux. WSL should work

  • 6 devlogs
  • 15h
Try project → See source code →
Open comments for this post

4h 51m logged

Been a while scince the last devlog
Since then i have:

  • Written a readme and security policy
  • Support for nested commands
  • Compiles without warnings
  • even more “haskell like”

Nesting commands dont work super well, but for simpler nesting it should work fine

I have also learnt that haskell types are super weird, somehow theres a difference between String and [Char], and i have no idea what it is

Screenshot is of it compiling without errors

0
0
18
Open comments for this post

2h 12m 27s logged

I have made multiple large changes, including

  • Support for both ordered and unordered lists
  • Output in MarkDown format
  • Rewrite of code to be more haskell like (for example, pattern matching)

Making the markdown output took a lot of time, since i basically had to rewrite every formatting function, but it went faster than with html output, probably because im better at haskell now

0
0
5
Open comments for this post

2h 40m 29s logged

Several notable changes, including:

  • Support for lists!!! (Unordered, ordered coming soon)
  • Lambda notation
  • More concise code and shorter function names

Getting the lists to work was a nightmare, i had to do some cheeky recursion thing and it was not easy. I also had to put parentheses like everywhere for the compiler to understand what ordering i wanted, but it didnt say that, it just said “Couldn’t match expected type with actual type”, and i had no idea what was going on.

0
0
8
Open comments for this post

3h 18m 42s logged

Jojk now has the following features:

  • Support for text types (bold, italic, strikethrough, etc)
  • Can do links!
  • No compiler warnings!

Ive learnt lots, most of it being that haskell is weird, but the compiler warnings are awesome. You forgot to specify the input and return type of a function? The compiler warning literally tells you the type, and gives you the exact codepiece you need to add!

I did encounter a couple of errors, but most of them were just things like haskell needing an int instead of a “maybe int”(what the hell is a maybe int?)

0
0
12
Open comments for this post

1h 30m 48s logged

Jojk is a markup language im making, and im using it to learn haskell, so i anticipate a lot of issues.

Right now it takes a file as an input and outputs the file but in html format

0
0
9

Delete project?

Are you sure you want to permanently delete this project? This action cannot be undone.

All devlogs, followers, and associated data will be removed.

Followers

Loading…