@@ -31,6 +31,7 @@ filter_include=$(jq '.source.commit_filter.include // []' <<< "$payload")
3131filter_include_all_match=$( jq -r ' .source.commit_filter.include_all_match // false' <<< " $payload" )
3232filter_exclude=$( jq ' .source.commit_filter.exclude // []' <<< " $payload" )
3333filter_exclude_all_match=$( jq -r ' .source.commit_filter.exclude_all_match // false' <<< " $payload" )
34+ version_depth=$( jq -r ' .source.version_depth // 1' <<< " $payload" )
3435reverse=false
3536
3637configure_git_global " ${git_config_payload} "
@@ -121,31 +122,32 @@ else
121122 paths_search=` echo " -- $paths $ignore_paths " | tr " \n\r" " " `
122123fi
123124
125+ set -x
124126list_command=" git rev-list --all --first-parent $log_range $paths_search "
125127if jq -e ' length > 0' <<< " $filter_include"
126128then
127129 list_command+=" | git rev-list --stdin --date-order --first-parent --no-walk=unsorted "
128- if [ " $filter_include_all_match " == " true" ]; then
129- list_command+=" --all-match"
130- fi
131130 include_items=$( echo $filter_include | jq -r -c ' .[]' )
132131 for wli in " $include_items "
133132 do
134133 list_command+=" --grep=\" $wli \" "
135134 done
135+ if [ " $filter_include_all_match " == " true" ]; then
136+ list_command+=" --all-match"
137+ fi
136138fi
137139
138140if jq -e ' length > 0' <<< " $filter_exclude"
139141then
140- list_command+=" | git rev-list --stdin --date-order --invert-grep --first-parent --no-walk=unsorted "
141- if [ " $filter_exclude_all_match " == " true" ]; then
142- list_command+=" --all-match"
143- fi
142+ list_command+=" | git rev-list --stdin --date-order --invert-grep --first-parent --no-walk=unsorted "
144143 exclude_items=$( echo $filter_exclude | jq -r -c ' .[]' )
145144 for bli in " $exclude_items "
146145 do
147146 list_command+=" --grep=\" $bli \" "
148147 done
148+ if [ " $filter_exclude_all_match " == " true" ]; then
149+ list_command+=" --all-match"
150+ fi
149151fi
150152
151153
0 commit comments