Skip to content

Identify the code section type automatically #5

Description

@harendra-kumar

There are three types of code sections:

  • standalone
  • ghci shared
  • doctest

Instead of using a markdown tag we can identify these automatically. That will help in using the same haskell markdown tag so that it works with github language highlighting.

The different types of codes can be identified as follows:

  • if the first line starts with >>> then it is doctest
  • if the first line is a comment {- standalone -} then it is standalone Haskell ghci code
  • otherwise it is ghci shared code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions