Change presubmit flow

Modify presubmit flow as described in #1010 
s/${BASH_REMATCH[**2**]}/${BASH_REMATCH[**1**]}