diff --git a/bin/omni b/bin/omni index dd5f9cb..45a4d08 100755 --- a/bin/omni +++ b/bin/omni @@ -230,11 +230,6 @@ update_illumos() fi } -diff_colour() -{ - gegrep --colour '^|^ [^ ].*' -} - upstream_diff() { typeset arg="$1" @@ -248,58 +243,21 @@ upstream_diff() echo "GATE:" echo + git log --reverse --no-merges --abbrev-commit \ - master..upstream_gate \ - | nawk ' - function op() { - if (commit) - printf("%-69s %s\n", issue, commit) - commit = 0 - } - /^commit / { op(); commit = $2 } - /^ (backout: *|Revert ")?[0-9][0-9][0-9][0-9] / { - gsub(/ +/, " ") - issue = substr($0, 0, 69) - } - END { op() } - ' | diff_colour + --pretty="tformat: %C(red bold)%<(67,trunc)%s %C(cyan)%h" \ + master..upstream_gate hash="`joyent_commit`" + head="`git rev-parse upstream_joyent`" echo echo "JOYENT ($hash..):" echo + git log --reverse --no-merges --abbrev-commit \ + --grep='^OS-' \ + --pretty="tformat: %C(red bold)%<(67,trunc)%s %C(cyan)%h" \ + "$hash..$head" - reset_illumos_branch - git checkout -q upstream_joyent - git whatchanged --reverse --no-merges --abbrev-commit \ - "$hash.." | nawk -v "opt=$arg" ' - function op() { - if (matched) - { - printf("%-69s %s\n", issue, commit) - for (i in files) - print " ", files[i] - print "" - matched = 0 - } - # Clear array - split("", files) - } - /^commit / { op(); commit = $2 } - /OS-[0-9]/ { - gsub(/ +/, " ") - issue = substr($0, 0, 69) - } - /^:/ { - files[NR] = sprintf("%s %s", $5, $6) - } - opt == "all" { matched = 1 } - / lx / { matched = 1 } - /(brand|fs)\/lx/ { matched = 1 } - /\/lx_/ { matched = 1 } - END { op() } - ' | diff_colour - git checkout -q "$branch" echo ) }