Skip to content

Instantly share code, notes, and snippets.

@jcouyang
Created November 7, 2015 14:26
Show Gist options
  • Save jcouyang/935f664f3f17bc1994ea to your computer and use it in GitHub Desktop.
Save jcouyang/935f664f3f17bc1994ea to your computer and use it in GitHub Desktop.
include a file from gist to you org file

we all know orgmode can #+include localfile, but how we can include a file somewhere on the web, for example gist.

here's how you can embedding a org source from gist and include in your org file.

#+BEGIN_SRC sh :exports results :results raw
curl https://gist.githubusercontent.com/jcouyang/d8086961761f28f35bb9/raw/2c6df28e349ab81ac10e3f6f63d65e20df296729/glist-testing.md
#+END_SRC

or

#+PROPERTY: header-args :results raw
#+NAME: gist
#+BEGIN_SRC sh :exports none
curl $url
#+END_SRC

#+CALL: gist(url="https://gist.githubusercontent.com/jcouyang/d8086961761f28f35bb9/raw/2c6df28e349ab81ac10e3f6f63d65e20df296729/glist-testing.md")

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