ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* problem with url in \setupexternalfigures
@ 2010-01-07  9:14 Peter Münster
  2010-01-07  9:19 ` Hans Hagen
  2010-01-13 21:13 ` Hans Hagen
  0 siblings, 2 replies; 7+ messages in thread
From: Peter Münster @ 2010-01-07  9:14 UTC (permalink / raw)
  To: ConTeXt list

Hello,

This used to work:

\setupexternalfigures[directory={\currentvalue, http://pmrb.free.fr/tmp/}]
\starttext
\externalfigure[hacker-test]
\stoptext

But with the latest version, the figure is not found...

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-07  9:14 problem with url in \setupexternalfigures Peter Münster
@ 2010-01-07  9:19 ` Hans Hagen
  2010-01-13 21:13 ` Hans Hagen
  1 sibling, 0 replies; 7+ messages in thread
From: Hans Hagen @ 2010-01-07  9:19 UTC (permalink / raw)
  To: ConTeXt list

On 7-1-2010 10:14, Peter Münster wrote:
> Hello,
>
> This used to work:
>
> \setupexternalfigures[directory={\currentvalue, http://pmrb.free.fr/tmp/}]
> \starttext
> \externalfigure[hacker-test]
> \stoptext
>
> But with the latest version, the figure is not found...

hm, i didn't realize that one would put an url there ... i'll look into it

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-07  9:14 problem with url in \setupexternalfigures Peter Münster
  2010-01-07  9:19 ` Hans Hagen
@ 2010-01-13 21:13 ` Hans Hagen
  2010-01-13 23:04   ` Aditya Mahajan
  2010-01-14  8:18   ` Peter Münster
  1 sibling, 2 replies; 7+ messages in thread
From: Hans Hagen @ 2010-01-13 21:13 UTC (permalink / raw)
  To: ConTeXt list

On 7-1-2010 10:14, Peter Münster wrote:
> Hello,
>
> This used to work:
>
> \setupexternalfigures[directory={\currentvalue, http://pmrb.free.fr/tmp/}]
> \starttext
> \externalfigure[hacker-test]
> \stoptext
>
> But with the latest version, the figure is not found...

ok, i can fix that but there is a problem ...

if no suffix is given, the quality list is followed and the first 
request will be

http://pmrb.free.fr/tmp/hacker-test.pdf

which gives a home page which is no pdf of course and luatex does not 
like that

as i don't want to complicate the lookup mechanism even more, i will not 
catch this and users can best use a suffix when using an url

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-13 21:13 ` Hans Hagen
@ 2010-01-13 23:04   ` Aditya Mahajan
  2010-01-14 23:19     ` Hans Hagen
  2010-01-14  8:18   ` Peter Münster
  1 sibling, 1 reply; 7+ messages in thread
From: Aditya Mahajan @ 2010-01-13 23:04 UTC (permalink / raw)
  To: mailing list for ConTeXt users

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1360 bytes --]

On Wed, 13 Jan 2010, Hans Hagen wrote:

> On 7-1-2010 10:14, Peter Münster wrote:
>> Hello,
>> 
>> This used to work:
>> 
>> \setupexternalfigures[directory={\currentvalue, http://pmrb.free.fr/tmp/}]
>> \starttext
>> \externalfigure[hacker-test]
>> \stoptext
>> 
>> But with the latest version, the figure is not found...
>
> ok, i can fix that but there is a problem ...
>
> if no suffix is given, the quality list is followed and the first request 
> will be
>
> http://pmrb.free.fr/tmp/hacker-test.pdf
>
> which gives a home page which is no pdf of course and luatex does not like 
> that
>
> as i don't want to complicate the lookup mechanism even more, i will not 
> catch this and users can best use a suffix when using an url

Does it make sense to add the look-up to \usemodule?

For example, the following works:

\input 
http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste.tex

But it will be nice if I could also do

\usemodule[http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste.tex]

or

\usemodule[http://..../t-cut-n-paste] % no .tex

or (not really serious here)

\usemodule[http:// ...][t-cut-n-paste] % like \usemodule[p][name] etc.

Of course, this will only work for moudles that provide only one file.

Aditya

[-- Attachment #2: Type: text/plain, Size: 486 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-13 21:13 ` Hans Hagen
  2010-01-13 23:04   ` Aditya Mahajan
@ 2010-01-14  8:18   ` Peter Münster
  2010-01-14 23:24     ` Hans Hagen
  1 sibling, 1 reply; 7+ messages in thread
From: Peter Münster @ 2010-01-14  8:18 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Wed, Jan 13 2010, Hans Hagen wrote:

> ok, i can fix that but there is a problem ...
>
> if no suffix is given, the quality list is followed and the first request 
> will be
>
> http://pmrb.free.fr/tmp/hacker-test.pdf
>
> which gives a home page which is no pdf of course and luatex does not like 
> that

Hello Hans,

I get error 404 (not found):

wget http://pmrb.free.fr/tmp/hacker-test.pdf
--2010-01-14 09:05:32--  http://pmrb.free.fr/tmp/hacker-test.pdf
Resolving pmrb.free.fr... 212.27.63.139
Connecting to pmrb.free.fr|212.27.63.139|:80... connected.
HTTP request sent, awaiting response... 404 Not Found
2010-01-14 09:05:32 ERROR 404: Not Found.


> as i don't want to complicate the lookup mechanism even more, i will not 
> catch this and users can best use a suffix when using an url

Not really optimal, but should not be a problem.

Thanks, Peter

-- 
Contact information: http://pmrb.free.fr/contact/


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-13 23:04   ` Aditya Mahajan
@ 2010-01-14 23:19     ` Hans Hagen
  0 siblings, 0 replies; 7+ messages in thread
From: Hans Hagen @ 2010-01-14 23:19 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 14-1-2010 0:04, Aditya Mahajan wrote:

> Of course, this will only work for moudles that provide only one file.

you can pick up the test version and play with ...

\enabletrackers[modules.loading]

\input 
http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste.tex

% 
\usemodule[http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste.tex]
\usemodule[http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste]

% \usemodule[x][set-12]

\starttext
     file:

 
\typefile{http://github.com/adityam/cut-n-paste/raw/master/tex/context/third/cut-n-paste/t-cut-n-paste.tex}
\stoptext

a suffix is mandate with http etc as otherwise we get a match anyway (a 
homepage or some error page)

eventually all file loading will be scheme aware

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: problem with url in \setupexternalfigures
  2010-01-14  8:18   ` Peter Münster
@ 2010-01-14 23:24     ` Hans Hagen
  0 siblings, 0 replies; 7+ messages in thread
From: Hans Hagen @ 2010-01-14 23:24 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 14-1-2010 9:18, Peter Münster wrote:
> On Wed, Jan 13 2010, Hans Hagen wrote:
>
>> ok, i can fix that but there is a problem ...
>>
>> if no suffix is given, the quality list is followed and the first request
>> will be
>>
>> http://pmrb.free.fr/tmp/hacker-test.pdf
>>
>> which gives a home page which is no pdf of course and luatex does not like
>> that
>
> Hello Hans,
>
> I get error 404 (not found):
>
> wget http://pmrb.free.fr/tmp/hacker-test.pdf
> --2010-01-14 09:05:32--  http://pmrb.free.fr/tmp/hacker-test.pdf
> Resolving pmrb.free.fr... 212.27.63.139
> Connecting to pmrb.free.fr|212.27.63.139|:80... connected.
> HTTP request sent, awaiting response... 404 Not Found
> 2010-01-14 09:05:32 ERROR 404: Not Found.

at some point i want to use the built in socket code instead of calling 
curl in which case we can intercept the 404 case (i had no time for that 
yet)

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-01-14 23:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-07  9:14 problem with url in \setupexternalfigures Peter Münster
2010-01-07  9:19 ` Hans Hagen
2010-01-13 21:13 ` Hans Hagen
2010-01-13 23:04   ` Aditya Mahajan
2010-01-14 23:19     ` Hans Hagen
2010-01-14  8:18   ` Peter Münster
2010-01-14 23:24     ` Hans Hagen

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 NNTP newsgroup(s).