On 2010-09-11 01:00 , rai...@macports.org wrote:
> Revision: 71380
>           http://trac.macports.org/changeset/71380
> Author:   rai...@macports.org
> Date:     2010-09-10 16:00:39 -0700 (Fri, 10 Sep 2010)
> Log Message:
> -----------
> pextlib1.0:
> Add new 'system -W path' which changes into the given directory before
> executing the command.

As a longer explanation, this revision adds a new parameter to `system`
which changes to the given directory before executing the shell command.
This should make it easier to write often used constructs as shown below.

This example
  system "cd ${worksrcpath} && touch foo"

can now be written as
  system -W ${worksrcpath} "touch foo"

The new form has better readability in my opinion, especially with
syntax highlighting.

I called this new parameter `-W`, as there is the pre-existing `xinstall
-W` in our Tcl extensions which is similar.

Rainer
_______________________________________________
macports-dev mailing list
macports-dev@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo.cgi/macports-dev

Reply via email to