Skip to content

Latest commit

 

History

History
57 lines (38 loc) · 1.26 KB

README.org

File metadata and controls

57 lines (38 loc) · 1.26 KB

Orgmode

A Clojure library designed to parse mode files into clojure data structures.

Status

Usable, but not perfect, parse the test file to see some of the issues.

Installation

Using deps, add the coordinate to your deps.edn:

{:deps {
        orgmode {:git/url "https://github.com/bnbeckwith/orgmode"
                 :sha "5b83296a645af8011ed282b86de1d5995a9914f8"}
        }}

If you are using lein, just add it as a dependency:

[bnbeckwith.com/orgmode "0.7.5"]

Usage

In your favorite terminal, launch a repl with

clojure -Adev
(ns main
  (:require [orgmode.core :as org]))

(org/parse-str "* Headline")
; {:content [{:type :headline, :text "Headline", :todo nil, :level 1, :content [], :tags nil}], :level 0}

(org/parse-str "[[http://clojure.org][Clojure]]")
; {:content [{:inline true, :type :link, :uri "http://clojure.org", :content ["Clojure"]}], :level 0}

(org/parse "File.org")
; File structure

License

Copyright © 2012-2020 Benjamin Beckwith

Distributed under the Eclipse Public License, the same as Clojure.

Contributors

  • Benjamin Beckwith
  • David Pham