From bbac318d7a12500b1c3d0a57d0620d27edcd0422 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Wed, 21 Jan 2015 16:28:24 +1000 Subject: Add make rule to update copyright years Usage: make update-copyright OLD=2014 NEW=2015 Signed-off-by: Allan McRae --- Makefile.am | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index d2a11ebd..34489df8 100644 --- a/Makefile.am +++ b/Makefile.am @@ -62,6 +62,11 @@ update-po: $(MAKE) -C scripts/po update-po $(MAKE) -C src/pacman/po update-po -.PHONY: update-po +update-copyright: + for file in $(shell sh -c 'git grep -l "Copyright .* Pacman Development" | grep -v "\.po"'); do \ + sed -i -e "/Copyright (/s/-$(OLD)/-$(NEW)/" -e "/Copyright (/s/ $(OLD)/ $(OLD)-$(NEW)/" "$$file"; \ + done + +.PHONY: update-po update-copyright # vim:set noet: -- cgit v1.2.3-70-g09d2