ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* texexec from parent directory
@ 2006-09-01  5:20 Aditya Mahajan
  2006-09-02  7:24 ` Aditya Mahajan
  0 siblings, 1 reply; 3+ messages in thread
From: Aditya Mahajan @ 2006-09-01  5:20 UTC (permalink / raw)


Hi,

  I have the following project structure

base/
   |
   +--project.tex
   |
   +--product.tex
   |
   +--environment.tex
   +
  subdir/
     |
     +---component.tex


If I in subdir and texexec component it compiles fine. If I am in base 
and texexec subdir/component it works fine. However, if I am in the 
parent directory of base and

texexec base/subdir/component

it does not work as the environment file is not found. It seems that 
the search for files is taking place relative to the directory from 
where texexec is invoked, rather than relative to the directory where 
the file resides. Is there some way I can make the component file 
compile from the parent directory of base?

Thanks,
Aditya

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

* Re: texexec from parent directory
  2006-09-01  5:20 texexec from parent directory Aditya Mahajan
@ 2006-09-02  7:24 ` Aditya Mahajan
  2006-09-03  4:46   ` Aditya Mahajan
  0 siblings, 1 reply; 3+ messages in thread
From: Aditya Mahajan @ 2006-09-02  7:24 UTC (permalink / raw)


On Fri, 1 Sep 2006, Aditya Mahajan wrote:

> Hi,
>
>  I have the following project structure
>
> base/
>   |
>   +--project.tex
>   |
>   +--product.tex
>   |
>   +--environment.tex
>   +
>  subdir/
>     |
>     +---component.tex
>
>
> If I in subdir and texexec component it compiles fine. If I am in base
> and texexec subdir/component it works fine. However, if I am in the
> parent directory of base and
>
> texexec base/subdir/component
>
> it does not work as the environment file is not found. It seems that
> the search for files is taking place relative to the directory from
> where texexec is invoked, rather than relative to the directory where
> the file resides. Is there some way I can make the component file
> compile from the parent directory of base?

Looking into tex.rb, shouldn't --autopath take care of this? (It does
not).

I also tried

texexec --environments=environment.tex base/subdir/component.tex

and I get

! You can't use `\relax' after \the.
<recently read> \@sl@\currentcomponentpath

\popmacro ...name \@sl@ \@@pushedmacro \endcsname
                                                   \@@pushedmacro 
\endcsname ...

\doprevlevel ->\popmacro \currentcomponentpath
                                                \popmacro 
\currentcomponent \...
l.129 \stopcomponent

I'm forgetting what you said and using zero instead.

! You can't use `\relax' after \advance.
<recently read> \@sl@\currentcomponentpath

\popmacro ...name \@sl@ \@@pushedmacro \endcsname
                                                   \minusone
\doprevlevel ->\popmacro \currentcomponentpath
                                                \popmacro 
\currentcomponent \...
l.129 \stopcomponent

I'm forgetting what you said and not changing anything.

! Missing number, treated as zero.
<to be read again>
                    \xdef
\popmacro #1->\xdef
                     \@@pushedmacro {\string #1}\@EA \let \@EA 
#1\csname \the...

\doprevlevel ...tpath \popmacro \currentcomponent
                                                   \setsystemmode 
\currentcom...
l.129 \stopcomponent

A number should have been here; I inserted `0'.
(If you can't figure out why I needed to see a number,
look up `weird error' in the index to The TeXbook.)

etc....

Am I missing some texexec switch?

Aditya

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

* Re: texexec from parent directory
  2006-09-02  7:24 ` Aditya Mahajan
@ 2006-09-03  4:46   ` Aditya Mahajan
  0 siblings, 0 replies; 3+ messages in thread
From: Aditya Mahajan @ 2006-09-03  4:46 UTC (permalink / raw)


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

On Sat, 2 Sep 2006, Aditya Mahajan wrote:

> On Fri, 1 Sep 2006, Aditya Mahajan wrote:
>
>> Hi,
>>
>>  I have the following project structure
>>
>> base/
>>   |
>>   +--project.tex
>>   |
>>   +--product.tex
>>   |
>>   +--environment.tex
>>   +
>>  subdir/
>>     |
>>     +---component.tex
>>
>>
>> If I in subdir and texexec component it compiles fine. If I am in base
>> and texexec subdir/component it works fine. However, if I am in the
>> parent directory of base and
>>
>> texexec base/subdir/component
>>
>> it does not work as the environment file is not found. It seems that
>> the search for files is taking place relative to the directory from
>> where texexec is invoked, rather than relative to the directory where
>> the file resides. Is there some way I can make the component file
>> compile from the parent directory of base?
>
> Looking into tex.rb, shouldn't --autopath take care of this? (It does
> not).
>
> I also tried
>
> texexec --environments=environment.tex base/subdir/component.tex
>
> and I get

Sorry for the noise. --environment works. I was getting the error 
because of a typo in the environment file. Strange that I did not get 
the error while compiling the component file. See the end for the 
description.

However the pdf is created in the directory from which texexec was 
called. Hans, whenever you work on tex.rb next, can you implement a 
switch that will "cd directory" and then run everything.


Here is a description of the error. Consider the attached directory 
structure of files. environment.tex has a typo. It starts with

\startenvironment

but ends with

\stopcomponent

If I 'texexec component' it runs fine.

If I 'texexec --environment=environment component' I get

! You can't use `\relax' after \the.
<recently read> \@sl@\currentcomponentpath

Can the error message be made easier to understand? Can I get an
error or warning when I just 'texexec component'?


Aditya

[-- Attachment #2: Type: APPLICATION/ZIP, Size: 835 bytes --]

[-- Attachment #3: Type: text/plain, Size: 139 bytes --]

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

end of thread, other threads:[~2006-09-03  4:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-09-01  5:20 texexec from parent directory Aditya Mahajan
2006-09-02  7:24 ` Aditya Mahajan
2006-09-03  4:46   ` Aditya Mahajan

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).