1 # This file is part of GNU paxutils
3 # Copyright (c) 2009 Free Software Foundation, Inc.
5 # Written by Sergey Poznyakoff
7 # GNU Paxutils is free software; you can redistribute it and/or modify it
8 # under the terms of the GNU General Public License as published by the
9 # Free Software Foundation; either version 3, or (at your option) any later
12 # GNU Paxutils is distributed in the hope that it will be useful, but
13 # without any warranty; without even the implied warranty of
14 # merchantability or fitness for a particular purpose. see the gnu general
15 # public license for more details.
17 # You should have received a copy of the GNU General Public License along
18 # with GNU Paxutils; if not, write to the Free Software Foundation, Inc.,
19 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21 # This file is part of GNU paxutils
23 # Copyright (c) 2009 Free Software Foundation, Inc.
25 # Written by Sergey Poznyakoff
27 # GNU Paxutils is free software; you can redistribute it and/or modify it
28 # under the terms of the GNU General Public License as published by the
29 # Free Software Foundation; either version 3, or (at your option) any later
32 # GNU Paxutils is distributed in the hope that it will be useful, but
33 # without any warranty; without even the implied warranty of
34 # merchantability or fitness for a particular purpose. see the gnu general
35 # public license for more details.
37 # You should have received a copy of the GNU General Public License along
38 # with GNU Paxutils; if not, write to the Free Software Foundation, Inc.,
39 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
41 # Define the following variables in order to use the ChangeLog rule below:
42 # prev_change_log [optional] Name of the previous ChangeLog file.
43 # gen_start_date [optional] Start ChangeLog from this date.
44 # changelog_dir [mandatory] Directory where to create ChangeLog
48 if test -d .git; then \
49 cmd=$(top_srcdir)/build-aux/gitlog-to-changelog; \
50 if test -n "$(gen_start_date)"; then \
51 cmd="$$cmd --since=\"$(gen_start_date)\""; \
54 sed '/<unknown>$$/d' | fmt -s > $(changelog_dir)/cl-t; \
55 if test -n "$(prev_change_log)" && test -f "$(prev_change_log)"; \
57 echo "" >> $(changelog_dir)/cl-t; \
58 cat "$(prev_change_log)" | \
59 sed '/^Local Variables:/,/^End:/d' >> $(changelog_dir)/cl-t; \
61 echo "Local Variables:" >> $(changelog_dir)/cl-t; \
62 echo "mode: change-log" >> $(changelog_dir)/cl-t; \
63 echo "version-control: never" >> $(changelog_dir)/cl-t; \
64 echo "buffer-read-only: t" >> $(changelog_dir)/cl-t; \
65 echo "End:" >> $(changelog_dir)/cl-t; \
66 rm -f $(changelog_dir)/ChangeLog; \
67 mv $(changelog_dir)/cl-t $(changelog_dir)/ChangeLog; \