worg.el 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. ;;; worg.el --- this is code for Worg
  2. ;;
  3. ;; Copyright 2008 Bastien Guerry
  4. ;;
  5. ;; Emacs Lisp Archive Entry
  6. ;; Filename: worg.el
  7. ;; Version: 0.1
  8. ;; Author: Bastien Guerry <bzg AT altern DOT org>
  9. ;; Maintainer: Bastien Guerry <bzg AT altern DOT org>
  10. ;; Keywords: org, wp, toc
  11. ;; Description: Shows a browsable table of contents for Org buffer
  12. ;;
  13. ;; This program is free software; you can redistribute it and/or modify
  14. ;; it under the terms of the GNU General Public License as published by
  15. ;; the Free Software Foundation; either version 3, or (at your option)
  16. ;; any later version.
  17. ;;
  18. ;; This program is distributed in the hope that it will be useful,
  19. ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
  20. ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  21. ;; GNU General Public License for more details.
  22. ;;
  23. ;; You should have received a copy of the GNU General Public License
  24. ;; along with this program; if not, write to the Free Software
  25. ;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  26. ;;
  27. ;;; Commentary:
  28. ;;
  29. ;; This file provides dynamic blocks for editing Worg pages.
  30. ;; See the Worg project here: https://code.orgmode.org/bzg/worg.
  31. ;;
  32. ;; Put this file into your load-path and the following into your ~/.emacs:
  33. ;; (require 'worg)
  34. ;;
  35. ;;; Code:
  36. (eval-when-compile
  37. (require 'cl))
  38. (defun org-dblock-write:timestamp (params)
  39. "Insert a simple timestamp.
  40. Params are: string (like \"Updated: \"
  41. format (the formatting string)"
  42. (let ((string (or (plist-get params :string) "Updated: "))
  43. (time-format (or (plist-get params :format)
  44. (car org-time-stamp-formats))))
  45. (insert string (format-time-string time-format))))
  46. (provide 'worg)
  47. ;;; User Options, Variables
  48. ;;; worg.el ends here