Shell Snippets Check if Git Directories belong to user for d in ./*/; do (cd "$d" && git config --get remote.origin.url); done | grep "user" Applying the changes from branch b to a, without merging or adding commits git merge --no-commit --squash branchA git reset HEAD # to unstage the changes