Git Product home page Git Product logo

foroxasciidoc's Introduction

https://melpa.org/packages/ox-asciidoc-badge.svg https://github.com/yashi/org-asciidoc/actions/workflows/tests.yml/badge.svg

org-asciidoc

An Org Mode Exporter Backend For AsciiDoc and Asciidoctor

Setup

  1. Make sure you have org-mode v8.0 or later
  2. Clone this repository
  3. Add the following to your .emacs
    (add-to-list 'load-path "~/path/to/org-asciidoc/")
    (require 'ox-asciidoc)
        
  4. open a .org file and run org-asciidoc-export-as-asciidoc

AsciiDoc specific attributes

AsciiDoc backend understands the following attributes in a ATTR_ASCIIDOC line.

Source Code Blocks

:asciidoctor-diagram
Export a source code block as an Asciidoctor Diagram. Set it as t to generate a listing block for an asciidoctor diagram.

Make sure to set :exports to something non-standard, diagram. This allows us to get :file parameter in the exporter.

e.g)

#+ATTR_ASCIIDOC: :asciidoctor-diagram t
#+BEGIN_SRC ditaa :file images/hello-world.png :exports diagram
+--------------+
| Hello World! |
+--------------+
#+END_SRC
    

Tables

:width
a percentage value to specify the table width with in the current column. Valid values: 1โ€ฆ99.

e.g)

#+ATTR_ASCIIDOC: :width 50
| Name  | Phone | Age |
| Peter |  1234 |  17 |
| Anna  |  4321 |  25 |
    
:pgwide
a boolean value to specify the table should be column width or full page width in multi-column setup. Valid values: t or nil.

e.g)

#+ATTR_ASCIIDOC: :pgwide t
| Name  | Phone | Age |
| Peter |  1234 |  17 |
| Anna  |  4321 |  25 |
    

org-publish

If you want to use `org-publish` with ox-asciidoc, setup your `org-publish-project-alist` like this:

 (setq org-publish-project-alist
	  '(("my-proj"
	     :base-directory "/tmp/my-dir"
	     :publishing-directory "/tmp/pub-dir"
	     :publishing-function org-asciidoc-publish-to-asciidoc)))

foroxasciidoc's People

Contributors

yashi avatar yasuyk avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.