Skip to content

Commit

Permalink
Doc & CHANGES
Browse files Browse the repository at this point in the history
Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
  • Loading branch information
rgrinberg committed Mar 30, 2020
1 parent 39d22c4 commit a9ae11f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ Unreleased

- Allow per-package `version` in generated `opam` files (#3287, @toots)

- Add a `(chdir ..)` stanza to allow evaluating stanzas in sub directories.
(#3268, @rgrinberg)

2.4.0 (06/03/2020)
------------------

Expand Down
15 changes: 15 additions & 0 deletions doc/dune-files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1497,6 +1497,21 @@ run this toplevel with:
$ dune exec ./tt.exe
chdir
-----

The ``chdir`` stanza can be used to evaluate stanzas in sub directories. This is
useful for generated files or to override stanzas in vendored direcotries
without editing vendored dune files.

In this example, a ``bar`` target is created in the ``foo`` directory, and a bar
target will be created in ``a/b/bar``:

.. code:: scheme
(chdir foo (rule (with-stdout-to bar (echo baz))))
(chdir a/b (rule (with-stdout-to bar (echo baz))))
external_variant
-----------------

Expand Down

0 comments on commit a9ae11f

Please sign in to comment.