File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -9,19 +9,22 @@ for schemaDir in schemas/v3* ; do
99 version=${vVersion: 1}
1010 echo $version
1111
12+ # list of schemas to process, dependent schemas come first
1213 schemas=(meta.yaml dialect.yaml schema.yaml schema-base.yaml)
1314
14- # find the latest commit date for each schema
15+ # find the newest commit date for each schema
1516 maxDate=" "
1617 declare -A datesHash
1718 for schema in " ${schemas[@]} " ; do
1819 if [ -f " $schemaDir /$schema " ]; then
19- lastCommitDate=$( git log -1 --format=" %ad" --date=short " $schemaDir /$schema " )
20- if [ " $lastCommitDate " \> " $maxDate " ]; then
21- maxDate=$lastCommitDate
20+ newestCommitDate=$( git log -1 --format=" %ad" --date=short " $schemaDir /$schema " )
21+
22+ # the newest date across a schema and all its dependencies is its date stamp
23+ if [ " $newestCommitDate " \> " $maxDate " ]; then
24+ maxDate=$newestCommitDate
2225 fi
2326 datesHash[" $schema " ]=$maxDate
24- echo $schema changed at $lastCommitDate
27+ echo $schema changed at $newestCommitDate
2528 fi
2629 done
2730
You can’t perform that action at this time.
0 commit comments