Re: [Orgmode] org-mode meets git a first proposal ?!

2009-08-02 Thread Carsten Dominik


On Jul 26, 2009, at 10:40 PM, Bastien wrote:


Hi Totti,

just a few words regarding preserving links.

About /finding/ links, I just added this simple function, which is
quite handy I guess:


(defun org-occur-link-in-agenda-files ()
 Create a link and search for it in the agendas.
The link is not stored in `org-stored-links', it is just created
for the search purpose.
 (interactive)
 (let ((link (condition-case nil
  (org-store-link nil)
(error Unable to create a link from here
   (org-occur-in-agenda-files (regexp-quote link


Nice one! I have added a menu entry for it.




For example, you are in your mailbox, you have the nasty feeling that
this old mail you are re-reading has been stored in your agenda, this
function helps you find it.

About preserving links -- yes, this is a problem.  I tried to  
implement

a registry long time ago: this is org-registry.el in the contrib/ dir.
Please have a look.  I don't maintain it anymore, but it might be  
still

usable.  If people are interested in using it more, I will look at it
again.

Another simple and useful approach: I often break links by moving a  
file

from dired.  A solution could be to advise dired-do-rename so that it
checks whether the file(s) at point is/are link(s) in an org file.  If
so, the function could just send a warning, and maybe update the  
links.

That would be a beginning.  Of course, this doesn't fix the problem
when moving files from the shell...


Please also consider using ID links which are made to survive
when files are moved around.  As long as the link definition remains
in one of the agenda files, the links will still work.

- Carsten



As for linking to specific versions of a file under versioning, I have
a few ideas I'm working on, I let you know later.

Thanks!

--
Bastien


___
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode




___
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] org-mode meets git a first proposal ?!

2009-07-26 Thread Bastien
Hi Totti,

just a few words regarding preserving links.

About /finding/ links, I just added this simple function, which is 
quite handy I guess:


(defun org-occur-link-in-agenda-files ()
  Create a link and search for it in the agendas.
The link is not stored in `org-stored-links', it is just created
for the search purpose.
  (interactive)
  (let ((link (condition-case nil
  (org-store-link nil)
(error Unable to create a link from here
(org-occur-in-agenda-files (regexp-quote link


For example, you are in your mailbox, you have the nasty feeling that
this old mail you are re-reading has been stored in your agenda, this
function helps you find it.

About preserving links -- yes, this is a problem.  I tried to implement
a registry long time ago: this is org-registry.el in the contrib/ dir.
Please have a look.  I don't maintain it anymore, but it might be still
usable.  If people are interested in using it more, I will look at it
again.

Another simple and useful approach: I often break links by moving a file
from dired.  A solution could be to advise dired-do-rename so that it
checks whether the file(s) at point is/are link(s) in an org file.  If
so, the function could just send a warning, and maybe update the links.
That would be a beginning.  Of course, this doesn't fix the problem 
when moving files from the shell...

As for linking to specific versions of a file under versioning, I have 
a few ideas I'm working on, I let you know later.

Thanks!

-- 
 Bastien


___
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode