Skip to content

Commit 39a79d2

Browse files
authored
Update deletedFiles.yml with the current ISO date.
Finally, the list of newly removed entries receives a header "# removed in $(date -I)" with the current ISO date.
1 parent 3d8dbb1 commit 39a79d2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/deletedFiles.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
# It compares the current master with the stable branch and adds all deleted files to the data/deleted.files file
44
# unless they are already listed there or are excluded from the release archives (export-ignore in .gitattributes).
55
# Any additions are made to the top of the list with a single trailing line before the first "# removed in" line.
6+
# Finally, the list of newly removed entries receives a header "# removed in $(date -I)" with the current ISO date.
67

78
name: "Update deleted files"
89
on:
@@ -38,10 +39,14 @@ jobs:
3839
if grep -q "^$F$" data/deleted.files; then
3940
continue
4041
fi
42+
if ( ! test -f "data/deleted.files.tmp"); then
43+
awk -v "input=# newly removed" '/# removed in/ && !found {print input; found=1} 1' data/deleted.files > data/deleted.files.tmp && cp data/deleted.files{.tmp,}
44+
fi
4145
awk -v "input=$F" '/# removed in/ && !found {print input; found=1} 1' data/deleted.files > data/deleted.files.tmp && cp data/deleted.files{.tmp,}
4246
done
4347
if (test -f "data/deleted.files.tmp"); then
4448
awk '/# removed in/ && !found {printf("\n"); found=1} 1' data/deleted.files > data/deleted.files.tmp && mv data/deleted.files{.tmp,}
49+
sed -i "s/^# newly removed/# removed in $(date -I)/" data/deleted.files
4550
fi
4651
4752
- name: Create Pull Request

0 commit comments

Comments
 (0)