Browse Source

Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode

Bastien Guerry 17 years ago
parent
commit
5343394599
9 changed files with 119 additions and 23 deletions
  1. 4 0
      CONTRIB/ChangeLog
  2. 2 4
      CONTRIB/README
  3. 56 0
      CONTRIB/scripts/dir2org.zsh
  4. 10 1
      ChangeLog
  5. 5 1
      Makefile
  6. 12 0
      ORGWEBPAGE/Changes.org
  7. 5 4
      README_GIT
  8. 0 1
      TODO
  9. 25 12
      org.el

+ 4 - 0
CONTRIB/ChangeLog

@@ -1,3 +1,7 @@
+2008-02-08  Phil Jackson  <phil@shellarchive.co.uk>
+
+	* scripts/dir2org.zsh: New file.
+
 2008-02-07  Phil Jackson  <phil@shellarchive.co.uk>
 2008-02-07  Phil Jackson  <phil@shellarchive.co.uk>
 
 
 	* lisp/org-annotate-file.el: New file.
 	* lisp/org-annotate-file.el: New file.

+ 2 - 4
CONTRIB/README

@@ -5,14 +5,11 @@ package.  But the git repository for Org-mode is glad to provide useful way
 to distribute and develop them as long as they are distributed under a free
 to distribute and develop them as long as they are distributed under a free
 software license.
 software license.
 
 
-Please put your contribution in one of these three directories: lisp/,
-packages/, scripts/.
+Please put your contribution in one of these three directories:
 
 
 LISP (emacs-lisp code)
 LISP (emacs-lisp code)
 ======================
 ======================
 
 
-This directory contains emacs-lisp code.
-
 org-annotate-file.el --- Annotate a file with org syntax
 org-annotate-file.el --- Annotate a file with org syntax
 org2rem.el           --- Convert org appointments into reminders
 org2rem.el           --- Convert org appointments into reminders
 org-bibtex.el        --- Org links to BibTeX entries
 org-bibtex.el        --- Org links to BibTeX entries
@@ -37,3 +34,4 @@ org-export-freemind  --- exporting utilities from org-mode to freemind
 SCRIPTS (shell, bash, etc.)
 SCRIPTS (shell, bash, etc.)
 ===========================
 ===========================
 
 
+dir2org.zsh          --- Org compatible fs structure output

+ 56 - 0
CONTRIB/scripts/dir2org.zsh

@@ -0,0 +1,56 @@
+#!/usr/bin/env zsh
+
+# desc:
+#
+# Output an org compatible structure representing the filesystem from
+# the point passed on the command line (or . by default).
+#
+# options:
+#     none
+#
+# usage:
+#     dir2org.bash [DIR]...
+#
+# author:
+#     Phil Jackson (phil@shellarchive.co.uk)
+
+set -e
+
+function headline {
+    local depth="${1}"
+    local text="${2}"
+
+    printf "%${depth}s %s" "" | tr ' ' '*'
+    echo " ${text}"
+}
+
+function scan_and_populate {
+    local depth="${1}"
+    local dir="${2}"
+
+    headline ${depth} "${dir}"
+
+    # if there is no files in dir then just move on
+    [[ $(ls "${dir}" | wc -l) -eq 0 ]] && return
+
+    (( depth += 1 ))
+
+    for f in $(ls -d "${dir}"/*); do
+        if [ -d "${f}" ]; then
+            scan_and_populate ${depth} "${f}"
+        else
+            headline ${depth} "[[file://${f}][${${f##*/}%.*}]]"
+        fi
+    done
+
+    (( depth -= 1 ))
+}
+
+function main {
+    local scan_dir="${1:-$(pwd)}"
+    local depth=0
+
+    scan_and_populate ${depth} "${scan_dir}"
+}
+
+main "${@}"

+ 10 - 1
ChangeLog

@@ -1,9 +1,18 @@
+2008-02-08  Carsten Dominik  <dominik@science.uva.nl>
+
+	* org.el (org-clock-report): Show the clocktable when found.
+	(org-refile): Fix positioning bug when `org-reverse-note-order' is
+	nil.
+
 2008-02-07  Carsten Dominik  <dominik@science.uva.nl>
 2008-02-07  Carsten Dominik  <dominik@science.uva.nl>
 
 
-	* org.el (org-version): With refix argument, insert `org-version'
+	* org.el (org-version): With prefix argument, insert `org-version'
 	at point.
 	at point.
 	(org-agenda-goto): Recenter the window after finding the target
 	(org-agenda-goto): Recenter the window after finding the target
 	location, to make sure the correct position will be displayed.
 	location, to make sure the correct position will be displayed.
+	(org-agenda-get-deadlines): Don't scale priority with the warning
+	period.
+	(org-insert-heading): Don't break line in the middle of the line.
 
 
 2008-02-06  Carsten Dominik  <dominik@science.uva.nl>
 2008-02-06  Carsten Dominik  <dominik@science.uva.nl>
 
 

+ 5 - 1
Makefile

@@ -241,4 +241,8 @@ clean:
 
 
 
 
 push:
 push:
-	git-push git+ssh://repo.or.cz/srv/git/org-mode.git master
+	git-push git+ssh://repo.or.cz/srv/git/org-mode.git master
+
+pushtag:
+	git-tag -m "adding tag" -a $(TAG)
+	git-push git+ssh://repo.or.cz/srv/git/org-mode.git $(TAG)

+ 12 - 0
ORGWEBPAGE/Changes.org

@@ -5,6 +5,18 @@
 #+EMAIL:  carsten at orgmode dot org
 #+EMAIL:  carsten at orgmode dot org
 #+OPTIONS: H:3 num:nil toc:nil \n:nil @:t ::t |:t ^:{} *:t TeX:t LaTeX:nil
 #+OPTIONS: H:3 num:nil toc:nil \n:nil @:t ::t |:t ^:{} *:t TeX:t LaTeX:nil
 
 
+* Version 5.22
+
+** Details
+
+   - M-RET no longer brakes a line in the middle, it will make a
+     new line ofter the current or (if cursor is at the beginning
+     of the line) before the current line.
+
+   - RET, when executed in a headline after the main text and
+     before the tags will leave the tags in the current line and
+     create a new line below the current one.
+
 * Version 5.21
 * Version 5.21
 
 
   Bug fixes, in particular the long-hunted bug about wrong window
   Bug fixes, in particular the long-hunted bug about wrong window

+ 5 - 4
README_GIT

@@ -56,6 +56,7 @@ development.
      hard to preserve this and I would like to ask everyone to
      hard to preserve this and I would like to ask everyone to
      keep this in mind when developing changes.
      keep this in mind when developing changes.
 
 
+
 * The CONTRIB directory
 * The CONTRIB directory
 
 
 The git repository contains a CONTRIB directory.  This directory
 The git repository contains a CONTRIB directory.  This directory
@@ -69,10 +70,9 @@ of commentary in the file.  Please discuss your extensions on
 emacs-orgmode@gnu.org.
 emacs-orgmode@gnu.org.
 
 
 The CONTRIB directory will be part of the Org-mode distribution
 The CONTRIB directory will be part of the Org-mode distribution
-starting with version 6.0 (the first release after 5.20).  When
-that happens, people who want to use extensions will have to make
-sure their search path (executable or Lisp) includes the relevant
-directories.
+starting with version 5.21.  When that happens, people who want
+to use extensions will have to make sure their search path
+(executable or Lisp) includes the relevant directories.
 
 
 After files have been tested in CONTRIB and found to be generally
 After files have been tested in CONTRIB and found to be generally
 useful, we may decide to clarify copyright questions and then
 useful, we may decide to clarify copyright questions and then
@@ -80,3 +80,4 @@ move the file into the Org-mode core.  This means they will be
 moved up to the root directory and will also eventually be added
 moved up to the root directory and will also eventually be added
 to Emacs CVS tree.  The final decision about this rests with the
 to Emacs CVS tree.  The final decision about this rests with the
 maintainer.
 maintainer.
+

+ 0 - 1
TODO

@@ -1,6 +1,5 @@
           -*- mode:org -*-
           -*- mode:org -*-
 
 
-
 Ideas for time estimates:
 Ideas for time estimates:
 
 
  {22}    22 minutes
  {22}    22 minutes

+ 25 - 12
org.el

@@ -6156,9 +6156,8 @@ frame is not changed."
   "Insert a new heading or item with same depth at point.
   "Insert a new heading or item with same depth at point.
 If point is in a plain list and FORCE-HEADING is nil, create a new list item.
 If point is in a plain list and FORCE-HEADING is nil, create a new list item.
 If point is at the beginning of a headline, insert a sibling before the
 If point is at the beginning of a headline, insert a sibling before the
-current headline.  If point is in the middle of a headline, split the headline
-at that position and make the rest of the headline part of the sibling below
-the current headline."
+current headline.  If point is not at the beginning, do not split the line,
+but create the new hedline after the current line."
   (interactive "P")
   (interactive "P")
   (if (= (buffer-size) 0)
   (if (= (buffer-size) 0)
       (insert "\n* ")
       (insert "\n* ")
@@ -6175,13 +6174,19 @@ the current headline."
 	 ((and (org-on-heading-p) (bolp)
 	 ((and (org-on-heading-p) (bolp)
 	       (or (bobp)
 	       (or (bobp)
 		   (save-excursion (backward-char 1) (not (org-invisible-p)))))
 		   (save-excursion (backward-char 1) (not (org-invisible-p)))))
+	  ;; insert before the current line
 	  (open-line (if blank 2 1)))
 	  (open-line (if blank 2 1)))
 	 ((and (bolp)
 	 ((and (bolp)
 	       (or (bobp)
 	       (or (bobp)
 		   (save-excursion
 		   (save-excursion
 		     (backward-char 1) (not (org-invisible-p)))))
 		     (backward-char 1) (not (org-invisible-p)))))
+	  ;; insert right here
 	  nil)
 	  nil)
-	 (t (newline (if blank 2 1))))
+	 (t
+	  ;; in the middle of the line
+	  (org-show-entry)
+	  (end-of-line 1)
+	  (newline (if blank 2 1))))
 	(insert head) (just-one-space)
 	(insert head) (just-one-space)
 	(setq pos (point))
 	(setq pos (point))
 	(end-of-line 1)
 	(end-of-line 1)
@@ -14060,11 +14065,12 @@ heading in the current buffer."
 		(goto-char pos)
 		(goto-char pos)
 		(looking-at outline-regexp)
 		(looking-at outline-regexp)
 		(setq level (org-get-legal-level (funcall outline-level) 1))
 		(setq level (org-get-legal-level (funcall outline-level) 1))
-		(goto-char (or (save-excursion
-				 (if reversed
-				     (outline-next-heading)
-				   (outline-get-next-sibling)))
-			       (point-max)))
+		(goto-char
+		 (if reversed
+		     (outline-next-heading)
+		   (or (save-excursion (outline-get-next-sibling))
+		       (org-end-of-subtree t t)
+		       (point-max))))
 		(bookmark-set "org-refile-last-stored")
 		(bookmark-set "org-refile-last-stored")
 		(org-paste-subtree level))))
 		(org-paste-subtree level))))
 	  (org-cut-special)
 	  (org-cut-special)
@@ -18804,7 +18810,9 @@ When called with a prefix argument, move to the first clock table in the
 buffer and update it."
 buffer and update it."
   (interactive "P")
   (interactive "P")
   (org-remove-clock-overlays)
   (org-remove-clock-overlays)
-  (when arg (org-find-dblock "clocktable"))
+  (when arg
+    (org-find-dblock "clocktable")
+    (org-show-entry))
   (if (org-in-clocktable-p)
   (if (org-in-clocktable-p)
       (goto-char (org-in-clocktable-p))
       (goto-char (org-in-clocktable-p))
     (org-create-dblock (list :name "clocktable"
     (org-create-dblock (list :name "clocktable"
@@ -21388,7 +21396,6 @@ the documentation of `org-diary'."
 	    'undone-face 'org-warning 'done-face 'org-done)
 	    'undone-face 'org-warning 'done-face 'org-done)
 	  (push txt ee))
 	  (push txt ee))
 	(goto-char (point-at-eol))))
 	(goto-char (point-at-eol))))
-;	(outline-next-heading)))
     (nreverse ee)))
     (nreverse ee)))
 
 
 (defun org-agenda-get-deadlines ()
 (defun org-agenda-get-deadlines ()
@@ -21454,7 +21461,7 @@ the documentation of `org-diary'."
 		(org-add-props txt props
 		(org-add-props txt props
 		  'org-marker (org-agenda-new-marker pos)
 		  'org-marker (org-agenda-new-marker pos)
 		  'org-hd-marker (org-agenda-new-marker pos1)
 		  'org-hd-marker (org-agenda-new-marker pos1)
-		  'priority (+ (floor (* dfrac 100.))
+		  'priority (+ (- diff)
 			       (org-get-priority txt))
 			       (org-get-priority txt))
 		  'org-category category
 		  'org-category category
 		  'type (if upcomingp "upcoming-deadline" "deadline")
 		  'type (if upcomingp "upcoming-deadline" "deadline")
@@ -26965,6 +26972,12 @@ See the individual commands for more information."
   (interactive)
   (interactive)
   (cond
   (cond
    ((bobp) (if indent (newline-and-indent) (newline)))
    ((bobp) (if indent (newline-and-indent) (newline)))
+   ((and (org-at-heading-p)
+	 (looking-at
+	  (org-re "\\([ \t]+\\(:[[:alnum:]_@:]+:\\)\\)[ \t]*$")))
+    (org-show-entry)
+    (end-of-line 1)
+    (newline))
    ((org-at-table-p)
    ((org-at-table-p)
     (org-table-justify-field-maybe)
     (org-table-justify-field-maybe)
     (call-interactively 'org-table-next-row))
     (call-interactively 'org-table-next-row))