* Question about org-link-file-path-type
@ 2008-11-03 23:24 Matthew Lundin
2008-11-04 3:24 ` Matthew Lundin
0 siblings, 1 reply; 4+ messages in thread
From: Matthew Lundin @ 2008-11-03 23:24 UTC (permalink / raw)
To: emacs-orgmode
I am using org 6.10c. When I set org-link-file-path-type to absolute
and use C-u C-c C-l (org-insert-link with argument), any file in my
home directory above my org directory is given the shortcut ~ -- as in
file:~/pdfs/paper.pdf. (This is the desired behavior.)
But when org-link-file-path-type is set to adaptive and I use
org-insert link, the files above my org-directory are given
unabbreviated names. E.g.: file:/home/matt/pdfs/paper.pdf.
Since I use org on two separate computers with different root
directory structures but also rely on relative links for my website, I
would like the adaptive option to create abbreviated links for the
home directory (i.e., ~). Is this possible?
I seem to remember the adaptive setting resulting in the abbreviated
links in 6.06 (before I upgraded to 6.08 and then 6.10), but I may be
wrong about that.
Thanks,
Matt Lundin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Question about org-link-file-path-type
2008-11-03 23:24 Question about org-link-file-path-type Matthew Lundin
@ 2008-11-04 3:24 ` Matthew Lundin
2008-11-04 11:32 ` Carsten Dominik
2008-11-04 11:45 ` Sebastian Rose
0 siblings, 2 replies; 4+ messages in thread
From: Matthew Lundin @ 2008-11-04 3:24 UTC (permalink / raw)
To: Matthew Lundin; +Cc: emacs-orgmode
Matthew Lundin <mclundin@gmail.com> writes:
> I am using org 6.10c. When I set org-link-file-path-type to absolute
> and use C-u C-c C-l (org-insert-link with argument), any file in my
> home directory above my org directory is given the shortcut ~ -- as in
> file:~/pdfs/paper.pdf. (This is the desired behavior.)
>
> But when org-link-file-path-type is set to adaptive (the default)
> and I use org-insert link, the files above my org-directory are
> given unabbreviated names. E.g.: file:/home/matt/pdfs/paper.pdf.
>
> Since I use org on two separate computers with different root
> directory structures but also rely on relative links for my website, I
> would like the adaptive option to create abbreviated links for the
> home directory (i.e., ~). Is this possible?
>
> I seem to remember the adaptive setting resulting in the abbreviated
> links in 6.06 (before I upgraded to 6.08 and then 6.10), but I may be
> wrong about that.
My mistake. I checked and this was apparently not the behavior of
earlier versions of org-mode.
So let me try to simplify my question: Is it possible to have an
adaptive link option that creates (a) relative links for files in the
same directory as my org files or in subdirectories and (b)
abbreviated absolute links (i.e., ~ for home) for files in other
directories within my home directory? In other words, the behavior of
the absolute link option as part of the adaptive link option. As far
as I can tell, when the adaptive link option is set, org-store-link
and org-insert-link produce unabbreviated links for files in the home
directory.
Thanks (and sorry for the wordiness).
Matt
>
> Thanks,
>
> Matt Lundin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Question about org-link-file-path-type
2008-11-04 3:24 ` Matthew Lundin
@ 2008-11-04 11:32 ` Carsten Dominik
2008-11-04 11:45 ` Sebastian Rose
1 sibling, 0 replies; 4+ messages in thread
From: Carsten Dominik @ 2008-11-04 11:32 UTC (permalink / raw)
To: Matthew Lundin; +Cc: emacs-orgmode
Hi Matt,
I would call this a bug. It is fixed now. Thanks for your report!
- Carsten
On Nov 4, 2008, at 4:24 AM, Matthew Lundin wrote:
> Matthew Lundin <mclundin@gmail.com> writes:
>
>> I am using org 6.10c. When I set org-link-file-path-type to absolute
>> and use C-u C-c C-l (org-insert-link with argument), any file in my
>> home directory above my org directory is given the shortcut ~ -- as
>> in
>> file:~/pdfs/paper.pdf. (This is the desired behavior.)
>>
>> But when org-link-file-path-type is set to adaptive (the default)
>> and I use org-insert link, the files above my org-directory are
>> given unabbreviated names. E.g.: file:/home/matt/pdfs/paper.pdf.
>>
>> Since I use org on two separate computers with different root
>> directory structures but also rely on relative links for my
>> website, I
>> would like the adaptive option to create abbreviated links for the
>> home directory (i.e., ~). Is this possible?
>>
>> I seem to remember the adaptive setting resulting in the abbreviated
>> links in 6.06 (before I upgraded to 6.08 and then 6.10), but I may be
>> wrong about that.
>
> My mistake. I checked and this was apparently not the behavior of
> earlier versions of org-mode.
>
> So let me try to simplify my question: Is it possible to have an
> adaptive link option that creates (a) relative links for files in the
> same directory as my org files or in subdirectories and (b)
> abbreviated absolute links (i.e., ~ for home) for files in other
> directories within my home directory? In other words, the behavior of
> the absolute link option as part of the adaptive link option. As far
> as I can tell, when the adaptive link option is set, org-store-link
> and org-insert-link produce unabbreviated links for files in the home
> directory.
>
> Thanks (and sorry for the wordiness).
> Matt
>
>>
>> Thanks,
>>
>> Matt Lundin
>
>
> _______________________________________________
> 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
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Question about org-link-file-path-type
2008-11-04 3:24 ` Matthew Lundin
2008-11-04 11:32 ` Carsten Dominik
@ 2008-11-04 11:45 ` Sebastian Rose
1 sibling, 0 replies; 4+ messages in thread
From: Sebastian Rose @ 2008-11-04 11:45 UTC (permalink / raw)
Cc: emacs-orgmode
Hi Matthew,
links are always relative, if the file in the same directory as the
file. 'adaptive' means, use absolute path, if file is not in same
directory or below.
Maybe you need to set org-link-file-path-type to 'relative'?
C-h v org-link-file-path-type
------------------------------------------------------------
org-link-file-path-type is a variable defined in `org.el'.
Its value is adaptive
Documentation:
How the path name in file links should be stored.
Valid values are:
relative Relative to the current directory, i.e. the directory of the file
into which the link is being inserted.
absolute Absolute path, if possible with ~ for home directory.
noabbrev Absolute path, no abbreviation of home directory.
adaptive Use relative path for files in the current directory and sub-
directories of it. For other files, use an absolute path.
----------------------------------------------------------------
Or complete the files path in the minibuffer this way:
C-u C-c C-l
~/../../usr/local/share/info/org
TAB completion works for those paths too.
Regards,
Sebastian
Matthew Lundin wrote:
> Matthew Lundin <mclundin@gmail.com> writes:
>
>> I am using org 6.10c. When I set org-link-file-path-type to absolute
>> and use C-u C-c C-l (org-insert-link with argument), any file in my
>> home directory above my org directory is given the shortcut ~ -- as in
>> file:~/pdfs/paper.pdf. (This is the desired behavior.)
>>
>> But when org-link-file-path-type is set to adaptive (the default)
>> and I use org-insert link, the files above my org-directory are
>> given unabbreviated names. E.g.: file:/home/matt/pdfs/paper.pdf.
>>
>> Since I use org on two separate computers with different root
>> directory structures but also rely on relative links for my website, I
>> would like the adaptive option to create abbreviated links for the
>> home directory (i.e., ~). Is this possible?
>>
>> I seem to remember the adaptive setting resulting in the abbreviated
>> links in 6.06 (before I upgraded to 6.08 and then 6.10), but I may be
>> wrong about that.
>
> My mistake. I checked and this was apparently not the behavior of
> earlier versions of org-mode.
>
> So let me try to simplify my question: Is it possible to have an
> adaptive link option that creates (a) relative links for files in the
> same directory as my org files or in subdirectories and (b)
> abbreviated absolute links (i.e., ~ for home) for files in other
> directories within my home directory? In other words, the behavior of
> the absolute link option as part of the adaptive link option. As far
> as I can tell, when the adaptive link option is set, org-store-link
> and org-insert-link produce unabbreviated links for files in the home
> directory.
>
> Thanks (and sorry for the wordiness).
> Matt
>
>> Thanks,
>>
>> Matt Lundin
>
>
> _______________________________________________
> 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
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-11-04 11:45 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-03 23:24 Question about org-link-file-path-type Matthew Lundin
2008-11-04 3:24 ` Matthew Lundin
2008-11-04 11:32 ` Carsten Dominik
2008-11-04 11:45 ` Sebastian Rose
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).