ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* RFC: path relative to current file.
@ 2012-10-13  1:34 Andre Caldas
  2012-10-15 17:56 ` Hans Hagen
  2012-10-15 18:20 ` Hans Hagen
  0 siblings, 2 replies; 19+ messages in thread
From: Andre Caldas @ 2012-10-13  1:34 UTC (permalink / raw)
  To: ConTeXt users

Hello, list!

A while ago, I raised a question about how to, in a tex, specify a
file with a path relative to the currently being processed file.
http://www.ntg.nl/pipermail/ntg-context/2012/069132.html
http://www.ntg.nl/pipermail/ntg-context/2012/068902.html

Even though the issue did not get much attention, I do believe it is
the right thing to do. I wrote a module to implement a macro I called
"\pathrelativetome". My code is still a lot ugly. I don't know how to
do many things in Lua, LuaTeX and ConTeXt. It can be found here:
https://bitbucket.org/andrecaldas/math-video-classes/src/bade74046a6b/lib

It would be REALLY NICE if the functionality of "pathrelativetome" was
provided by ConTeXt.

call it using, for example:
context --usemodule=lib/relativetome src/products/assorted.tex

Ugly things remaining:
1. pathstack should be initialized with the path of the first tex
script. I.e.: src/products/, instead of
pathstack[1] = 'src/products'

2. Functions pop and push should be local. (relativetome.lua)

3. Call function "pop" automatically, just like the "push" function is
called automatically.

4. Avoid having to define "\xproject", "\xproduct", "\xcomponent" and
"\xenvironment".
http://www.ntg.nl/pipermail/ntg-context/2012/069305.html


Any suggestions/improvements are very welcome!


Cheers,
André Caldas.
___________________________________________________________________________________
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] 19+ messages in thread

end of thread, other threads:[~2012-11-08 16:30 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-13  1:34 RFC: path relative to current file Andre Caldas
2012-10-15 17:56 ` Hans Hagen
2012-10-15 18:20 ` Hans Hagen
2012-10-15 19:42   ` Andre Caldas
2012-10-15 20:04     ` Hans Hagen
2012-10-15 21:27       ` Aditya Mahajan
2012-10-15 21:38         ` Marco Patzer
2012-10-15 22:11         ` Hans Hagen
2012-10-15 22:26       ` Andre Caldas
2012-10-16  7:33         ` Hans Hagen
2012-10-16 11:25           ` Andre Caldas
2012-11-03  0:35   ` Andre Caldas
2012-11-03 10:13     ` Sietse Brouwer
2012-11-03 12:47       ` Hans Hagen
2012-11-07 19:34   ` Andre Caldas
2012-11-07 20:35     ` Hans Hagen
2012-11-08 12:14       ` Andre Caldas
2012-11-08 12:43         ` Hans Hagen
2012-11-08 16:30           ` Andre Caldas

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