From e799f6bccc11d37a955c6c7d8b04604d6f4f87e0 Mon Sep 17 00:00:00 2001 From: Jan Lindemann Date: Sat, 21 Feb 2026 12:04:40 +0100 Subject: [PATCH] pgit.sh: Add command exec Add a command "exec", which takes its arguments and runs it as a shell command within all projects in $PGIT_SH_PROJECTS. Signed-off-by: Jan Lindemann --- scripts/pgit.sh | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/scripts/pgit.sh b/scripts/pgit.sh index 927d137f..417f917c 100644 --- a/scripts/pgit.sh +++ b/scripts/pgit.sh @@ -93,6 +93,24 @@ cmd_run() done ) +cmd_exec() +( + local d + + set_global_variables + cd $projects_dir + + if [ "$PGIT_KEEP_GOING" != y ]; then set -e; fi + for d in $project_dirs; do + cur=`expr $cur + 1` + fat_marker $d: "$@" + ( + cd $d + "$@" + ) + done +) + cmd_commit() ( local d do_cvs @@ -278,7 +296,7 @@ while [ "${1:0:1}" = - ]; do done case $cmd in - get|diff|commit) + get|diff|commit|exec) cmd_${cmd//-/_} "$@" ;; *)