blob: eb4181d66b83f850d1e3139bb95902eaf3b0bec9 [file] [log] [blame]
Emil Velikovf0bdd132016-12-16 15:08:30 +00001#!/bin/sh
2
3# Script for generating a list of candidates which have typos in the nomination line
4#
5# Usage examples:
6#
7# $ bin/get-typod-pick-list.sh
8# $ bin/get-typod-pick-list.sh > picklist
9# $ bin/get-typod-pick-list.sh | tee picklist
10
11# NB:
12# This script intentionally _never_ checks for specific version tag
13# Should we consider folding it with the original get-pick-list.sh
14
Emil Velikova5f32552017-02-13 00:32:21 +000015# Use the last branchpoint as our limit for the search
16latest_branchpoint=`git merge-base origin/master HEAD`
17
Emil Velikovf0bdd132016-12-16 15:08:30 +000018# Grep for commits with "cherry picked from commit" in the commit message.
Emil Velikova5f32552017-02-13 00:32:21 +000019git log --reverse --grep="cherry picked from commit" $latest_branchpoint..HEAD |\
Emil Velikovf0bdd132016-12-16 15:08:30 +000020 grep "cherry picked from commit" |\
21 sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' > already_picked
22
23# Grep for commits that were marked as a candidate for the stable tree.
Emil Velikova5f32552017-02-13 00:32:21 +000024git log --reverse --pretty=%H -i --grep='^CC:.*mesa-dev' $latest_branchpoint..origin/master |\
Emil Velikovf0bdd132016-12-16 15:08:30 +000025while read sha
26do
27 # Check to see whether the patch is on the ignore list.
28 if [ -f bin/.cherry-ignore ] ; then
29 if grep -q ^$sha bin/.cherry-ignore ; then
30 continue
31 fi
32 fi
33
34 # Check to see if it has already been picked over.
35 if grep -q ^$sha already_picked ; then
36 continue
37 fi
38
39 git log -n1 --pretty=oneline $sha | cat
40done
41
42rm -f already_picked