citadel

My dotfiles, scripts and nix configs
git clone git://jb55.com/citadel
Log | Files | Refs | README | LICENSE

git-children-of (262B)


      1 #!/usr/bin/env bash
      2 # given a commit, find immediate children of that commit.
      3 
      4 for arg in "$@"; do
      5 for commit in $(git rev-parse $arg^0); do
      6 for child in $(git log --format='%H %P' --all | grep -F " $commit" | cut -f1 -d' '); do
      7       echo $child
      8 done
      9 done
     10 done