aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown/snippets
diff options
context:
space:
mode:
authorAntonio Ospite <antonio.ospite@collabora.com>2019-03-29 18:23:13 +0100
committerAntonio Ospite <antonio.ospite@collabora.com>2019-04-01 11:51:02 +0200
commite680dbe0658851bc73d8e664909df9619365e714 (patch)
tree2418b3cf85e6c040a2516732b7f5bdd90b8ed4a9 /docs/markdown/snippets
parent5905533fcd7fb9663023e6cf98d95667620d2f12 (diff)
downloadmeson-e680dbe0658851bc73d8e664909df9619365e714.zip
meson-e680dbe0658851bc73d8e664909df9619365e714.tar.gz
meson-e680dbe0658851bc73d8e664909df9619365e714.tar.bz2
Add 'meson subprojects foreach' command
Sometimes it is convenient to run an arbitrary command (e.g. 'git diff') on all subprojects. Add a 'meson subprojects foreach' command to take care of that. For this command the common argument 'subprojects' does not make sense, so only add '--sourcedir' and cover the case of a missing options.subprojects in run().
Diffstat (limited to 'docs/markdown/snippets')
-rw-r--r--docs/markdown/snippets/subproject-foreach.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/markdown/snippets/subproject-foreach.md b/docs/markdown/snippets/subproject-foreach.md
new file mode 100644
index 0000000..3a8ffc4
--- /dev/null
+++ b/docs/markdown/snippets/subproject-foreach.md
@@ -0,0 +1,7 @@
+## Add new `meson subprojects foreach` command
+
+`meson subprojects` has learned a new `foreach` command which accepts a command
+with arguments and executes it in each subproject directory.
+
+For example this can be useful to check the status of subprojects (e.g. with
+`git status` or `git diff`) before performing other actions on them.