org-babel-init.el 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. ;;; org-babel-init.el --- loads org-babel
  2. ;; Copyright (C) 2009 Eric Schulte
  3. ;; Author: Eric Schulte
  4. ;; Keywords: literate programming, reproducible research
  5. ;; Homepage: http://orgmode.org
  6. ;; Version: 0.01
  7. ;;; License:
  8. ;; This program is free software; you can redistribute it and/or modify
  9. ;; it under the terms of the GNU General Public License as published by
  10. ;; the Free Software Foundation; either version 3, or (at your option)
  11. ;; any later version.
  12. ;;
  13. ;; This program is distributed in the hope that it will be useful,
  14. ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. ;; GNU General Public License for more details.
  17. ;;
  18. ;; You should have received a copy of the GNU General Public License
  19. ;; along with GNU Emacs; see the file COPYING. If not, write to the
  20. ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  21. ;; Boston, MA 02110-1301, USA.
  22. ;;; Commentary:
  23. ;; for more information see the comments in org-babel.el
  24. ;;; Code:
  25. (let* ((babel-dir (expand-file-name
  26. "lisp"
  27. (expand-file-name
  28. "babel"
  29. (expand-file-name
  30. ".." (file-name-directory (or load-file-name buffer-file-name))))))
  31. (langs-dir (expand-file-name "langs" babel-dir))
  32. (load-path (append
  33. (list babel-dir langs-dir)
  34. (or load-path nil))))
  35. ;; org-babel core
  36. (require 'cl)
  37. (require 'org)
  38. (require 'org-exp-blocks)
  39. (require 'org-babel)
  40. (require 'org-babel-ref)
  41. (require 'org-babel-exp)
  42. (require 'org-babel-table)
  43. (require 'org-babel-comint)
  44. (require 'org-babel-lob)
  45. (require 'org-babel-tangle)
  46. ;; org-babel languages
  47. (require 'org-babel-emacs-lisp)
  48. (require 'org-babel-sh)
  49. ;; Library of babel
  50. (defvar org-babel-lob-dir
  51. (expand-file-name ".." babel-dir)
  52. "The directory holding the library-of-babel")
  53. (defun org-babel-load-library-of-babel ()
  54. (org-babel-lob-ingest (expand-file-name "library-of-babel.org" org-babel-lob-dir))))
  55. (provide 'org-babel-init)
  56. ;;; org-babel-init.el ends here