Skip to content

Commit

Permalink
DMF branch resync from master as of 2017-08-02 (#458)
Browse files Browse the repository at this point in the history
* gitlog2changelog: Date header only occurs at start of line

Alternative to #427

* gitlog2changelog: log parse errors for Author and Date

Suggested by Jim Klimov.

* configure.ac : move comment to a more relevant line

* docs/man/Makefile.am : small typo in comment

* configure.ac : refer to detailed doc from --with-doc help text; preset explicit nut_with_doc=man=auto value

* m4/nut_check_asciidoc.m4 configure.ac : parametrize the required minimum versions (asciidoc/a2x, dblatex)

* configure.ac docs/man/Makefile.am : track DOC_INSTALL_DISTED_MANS fallback behavior

* docs/man/Makefile.am : do not rebuild docs and do not error out if a prebuilt copy is among sources (not only in builddir as before)

* docs/Makefile.am : make sure the builddir copy of docbook-xsl.css is writeable (file is copied from OS, some distros have it 444 and not 644)

* docs/man/Makefile.am : Fix up manpage source timestamps when dist-ing

* docs/man/Makefile.am : Fix up dist-ed manpage source timestamps regardless of DOC_INSTALL_DISTED_MANS value

* docs/man/Makefile.am : Suffice to have prebuilt docs in dist-ed sources only if DOC_INSTALL_DISTED_MANS is enabled

* usbhid-ups: only check iOEMInformation once for openups2

This prevents the 'libusb_get_string: invalid argument' message from being
logged continously.

Patch provided by Alphonse <alphsteiner@gmail.com>

http://lists.alioth.debian.org/pipermail/nut-upsdev/2017-July/007314.html

* Re-merged drivers/eaton-mib.c from upstream/master and regenerated DMF
  • Loading branch information
jimklimov authored and aquette committed Aug 23, 2017
1 parent 1f7503a commit c1a853e
Show file tree
Hide file tree
Showing 8 changed files with 85 additions and 33 deletions.
34 changes: 24 additions & 10 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -298,8 +298,9 @@ dnl a second-class citizen (if both are set, the old option name wins).
dnl Also note that the legacy default was "man=yes" due to requirements
dnl of the "make distcheck", but it was reduced to "man=auto" so that
dnl the usual builds can pass by default on systems without asciidoc.
nut_with_docs="man=auto"
NUT_ARG_WITH([docs], [build and install documentation (alias to --with-doc)], [man=auto])
NUT_ARG_WITH([doc], [build and install documentation], [${nut_with_docs}])
NUT_ARG_WITH([doc], [build and install documentation (see docs/configure.txt for many variants of the option)], [${nut_with_docs}])

dnl ----------------------------------------------------------------------
dnl Check for presence and compiler flags of various libraries
Expand Down Expand Up @@ -679,6 +680,8 @@ NUT_CHECK_ASCIIDOC
NUT_REPORT_FEATURE([build and install documentation], [${nut_with_doc}], [],
[WITH_ASCIIDOC], [Define to enable Asciidoc support])

DOC_INSTALL_DISTED_MANS=no

case "${nut_with_doc}" in
yes|all)
nut_doc_build_list="man html-single html-chunked pdf"
Expand All @@ -703,8 +706,6 @@ dnl If user passed --with-doc='' they they want nothing, right?
;;
esac

dnl Note: Do not cover ${nut_doc_build_list} in braces or quotes here,
dnl to ensure that it is processed as several space-separated tokens
if test -z "${abs_srcdir}" ; then
case "${srcdir}" in
/*) abs_srcdir="${srcdir}";;
Expand All @@ -714,6 +715,9 @@ if test -z "${abs_srcdir}" ; then
fi
DOCTESTDIR="$(mktemp -d configure-test.docbuild.$$.XXXXXXX)" && \
DOCTESTDIR="$(cd "$DOCTESTDIR" && pwd)"

dnl Note: Do not cover ${nut_doc_build_list} in braces or quotes here,
dnl to ensure that it is processed as several space-separated tokens
for nut_doc_build_target in $nut_doc_build_list; do
case "${nut_doc_build_target}" in
*=*=*) rm -rf "${DOCTESTDIR}"
Expand Down Expand Up @@ -747,9 +751,9 @@ dnl to detect if we can build the wanted documentation format and yet
dnl not fail if we have no tools to generate it (so add to SKIP list).

html-single*)
AC_MSG_CHECKING([if asciidoc version can build ${nut_doc_build_target_base} (minimum required 8.6.3)])
AC_MSG_CHECKING([if asciidoc version can build ${nut_doc_build_target_base} (minimum required ${ASCIIDOC_MIN_VERSION})])
can_build_doc_html_single=no
AX_COMPARE_VERSION([${ASCIIDOC_VERSION}], [ge], [8.6.3], [
AX_COMPARE_VERSION([${ASCIIDOC_VERSION}], [ge], [${ASCIIDOC_MIN_VERSION}], [
( cd "$DOCTESTDIR" && ${A2X} --attribute=xhtml11_format --format=xhtml --xsl-file="${abs_srcdir}"/docs/xhtml.xsl --destination-dir=. "${abs_srcdir}"/docs/asciidoc.txt && test -s asciidoc.html ) && can_build_doc_html_single=yes
rm -f "$DOCTESTDIR"/asciidoc*.htm*
], [])
Expand All @@ -768,9 +772,9 @@ dnl not fail if we have no tools to generate it (so add to SKIP list).
;;

html-chunked*)
AC_MSG_CHECKING([if a2x version can build ${nut_doc_build_target_base} (minimum required 8.6.3)])
AC_MSG_CHECKING([if a2x version can build ${nut_doc_build_target_base} (minimum required ${ASCIIDOC_MIN_VERSION})])
can_build_doc_html_chunked=no
AX_COMPARE_VERSION([${A2X_VERSION}], [ge], [8.6.3], [
AX_COMPARE_VERSION([${A2X_VERSION}], [ge], [${ASCIIDOC_MIN_VERSION}], [
( cd "$DOCTESTDIR" && ${A2X} --attribute=chunked_format --format=chunked --xsl-file="${abs_srcdir}"/docs/chunked.xsl --destination-dir=. "${abs_srcdir}"/docs/FAQ.txt && test -s FAQ.chunked/index.html ) && can_build_doc_html_chunked=yes
rm -rf "${DOCTESTDIR}"/FAQ*.chunked*
], [])
Expand All @@ -789,9 +793,9 @@ dnl not fail if we have no tools to generate it (so add to SKIP list).
;;

pdf*)
AC_MSG_CHECKING([if dblatex version can build ${nut_doc_build_target_base} (minimum required 0.2.5)])
AC_MSG_CHECKING([if dblatex version can build ${nut_doc_build_target_base} (minimum required ${DBLATEX_MIN_VERSION})])
can_build_doc_pdf=no
AX_COMPARE_VERSION([${DBLATEX_VERSION}], [ge], [0.2.5], [
AX_COMPARE_VERSION([${DBLATEX_VERSION}], [ge], [${DBLATEX_MIN_VERSION}], [
( cd "$DOCTESTDIR" && ${A2X} --format=pdf --destination-dir=. "${abs_srcdir}"/docs/asciidoc.txt && test -s asciidoc.pdf ) && can_build_doc_pdf=yes
rm -f "${DOCTESTDIR}"/asciidoc.pdf
], [])
Expand Down Expand Up @@ -826,6 +830,15 @@ dnl not fail if we have no tools to generate it (so add to SKIP list).
AC_MSG_WARN([Unable to build ${nut_doc_build_target_base} documentation which you requested])
else
DOC_SKIPBUILD_LIST="${DOC_SKIPBUILD_LIST} ${nut_doc_build_target_base}"
if test "${nut_doc_build_target_flag}" = "auto" ; then
dnl Test that groff files exist (building from dist'ed tarball, not git repo)
if test -s "${abs_srcdir}"/docs/man/snmp-ups.8 ; then
AC_MSG_WARN([Unable to build ${nut_doc_build_target_base} documentation, but can install pre-built dist'ed copies])
DOC_INSTALL_DISTED_MANS="yes"
else
AC_MSG_WARN([Unable to build ${nut_doc_build_target_base} documentation, and unable to install pre-built dist'ed copies because they are absent])
fi
fi # Other variants include "no", "skip"...
fi
fi
;;
Expand Down Expand Up @@ -869,7 +882,7 @@ NUT_REPORT_FEATURE([build specific documentation format(s)], [${nut_with_doc}],

WITH_MANS=no
SKIP_MANS=no
if echo "${DOC_BUILD_LIST}" | grep -w "man" >/dev/null ; then
if echo "${DOC_BUILD_LIST}" | grep -w "man" >/dev/null || test "${DOC_INSTALL_DISTED_MANS}" = "yes" ; then
WITH_MANS=yes
fi
if echo "${DOC_SKIPBUILD_LIST}" | grep -w "man" >/dev/null ; then
Expand All @@ -882,6 +895,7 @@ dnl just mans) instead. Note that for WITH_MANS=yes the SKIP_MANS value
dnl is effectively ignored by docs/man/Makefile.am at this time.
AM_CONDITIONAL(WITH_MANS, test "${WITH_MANS}" = "yes")
AM_CONDITIONAL(SKIP_MANS, test "${SKIP_MANS}" = "yes")
AM_CONDITIONAL(DOC_INSTALL_DISTED_MANS, test "${DOC_INSTALL_DISTED_MANS}" = "yes")

dnl ----------------------------------------------------------------------
dnl checks related to --with-dev
Expand Down
3 changes: 3 additions & 0 deletions docs/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -113,12 +113,15 @@ A2X_COMMON_OPTS = $(ASCIIDOC_VERBOSE) --attribute icons \
# and do not forget to fix up docs/man/Makefile.am too ;)

.txt.html: common.xsl xhtml.xsl
@if test -s "${builddir}/docbook-xsl.css" && test -r "${builddir}/docbook-xsl.css" && ! test -w "${builddir}/docbook-xsl.css" ; then chmod +w "${builddir}/docbook-xsl.css" ; fi
$(A2X) $(A2X_COMMON_OPTS) --attribute=xhtml11_format --format=xhtml --xsl-file=$(srcdir)/xhtml.xsl $<

.txt.chunked: common.xsl chunked.xsl
@if test -s "${builddir}/docbook-xsl.css" && test -r "${builddir}/docbook-xsl.css" && ! test -w "${builddir}/docbook-xsl.css" ; then chmod +w "${builddir}/docbook-xsl.css" ; fi
$(A2X) $(A2X_COMMON_OPTS) --attribute=chunked_format --format=chunked --xsl-file=$(srcdir)/chunked.xsl $<

.txt.pdf: docinfo.xml
@if test -s "${builddir}/docbook-xsl.css" && test -r "${builddir}/docbook-xsl.css" && ! test -w "${builddir}/docbook-xsl.css" ; then chmod +w "${builddir}/docbook-xsl.css" ; fi
$(A2X) $(A2X_COMMON_OPTS) --attribute=pdf_format --format=pdf -a docinfo1 $<

if HAVE_ASPELL
Expand Down
36 changes: 29 additions & 7 deletions docs/man/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,17 @@
# Notes:
# - sources (.txt) and groff formats are both distributed,
# - only sources are versioned ; groff files are generated at worst
# during 'make dist'
# during 'make dist' (while preparing a release tarball)
# - HTML files are built upon request, if AsciiDoc is available,
# - groff update will only happen if AsciiDoc is available too,
# - all this can probably (and hopefully) be improved, but I've not
# found a way to do pattern replacement on the fly for target deps!
# FIXME: investigate an autogen.sh hook
# - Ref: http://www.gnu.org/software/hello/manual/automake/Man-pages.html
# - WITH_MANS can be enabled if either we are building man-pages, or if
# the --with-doc=man=auto detected an inability to build the man-pages
# but enabled the DOC_INSTALL_DISTED_MANS toggle so we deliver disted
# files from source tree

# Base configuration and client manpages, always installed
SRC_CONF_PAGES = \
Expand Down Expand Up @@ -628,13 +632,21 @@ EXTRA_DIST = \
if ! WITH_MANS
if ! SKIP_MANS
# Cause "make dist" to fail, unless caller (like the stack of distcheck-dmf)
# runs ./configure --with-doc=skip (or --with-man=skip specifically)
# runs ./configure --with-doc=skip (or --with-doc=man=skip specifically)
EXTRA_DIST += dist
dist:
echo "ERROR: Manpage building was disabled by configure script, and these pages are required for our proper 'make dist'" >&2 ; false
endif
endif

# For builds done from dist'ed sources, there may be a conflict of timestamps
# between original *.txt files and pre-built manpages etc. leading to skipping
# of manpage re-generation even if that activity is possible and requested.
# Possibly a cleaner, but less portable, solution would be to touch the
# generated files to long ago. Current solution assumes good valid clocks :)
dist-hook:
@echo "Fix up manpage source timestamps" && cd $(distdir) && touch $(SRC_ALL_PAGES)

HTML_MANS = \
$(HTML_CONF_MANS) \
$(HTML_CLIENT_MANS) \
Expand All @@ -660,6 +672,16 @@ CLEANFILES = *.xml *.html

SUFFIXES = .txt .html .1 .3 .5 .8

# For builds with allowed installation of prebuild man pages, check that
# they exist in sources (make would pull them automatically as a fallback
# from failed lookup in build products). For builds that require rebuild
# of man pages, abort with error if build product is missing.
if DOC_INSTALL_DISTED_MANS
SRC_PREBUILT_CLAUSE=|| [ -r "$(srcdir)/`basename $@`" ]
else
SRC_PREBUILT_CLAUSE=
endif

if HAVE_ASCIIDOC

.txt.html:
Expand Down Expand Up @@ -693,7 +715,7 @@ A2X_MANPAGE_OPTS = --doctype manpage --format manpage \
else !HAVE_ASCIIDOC

.txt.html:
@if [ -r "$@" ]; then \
@if [ -r "$@" ] $(SRC_PREBUILT_CLAUSE); then \
echo "Not (re)building $@ manual page, since 'asciidoc', 'xmllint' or 'xsltproc' were not found." ; \
else \
echo "Could not find prebuilt $@ manual page." ; \
Expand All @@ -702,7 +724,7 @@ else !HAVE_ASCIIDOC
fi

.txt.1:
@if [ -r "$@" ]; then \
@if [ -r "$@" ] $(SRC_PREBUILT_CLAUSE); then \
echo "Not (re)building $@ manual page, since 'asciidoc', 'xmllint' or 'xsltproc' were not found." ; \
else \
echo "Could not find prebuilt $@ manual page." ; \
Expand All @@ -711,7 +733,7 @@ else !HAVE_ASCIIDOC
fi

.txt.3:
@if [ -r "$@" ]; then \
@if [ -r "$@" ] $(SRC_PREBUILT_CLAUSE); then \
echo "Not (re)building $@ manual page, since 'asciidoc', 'xmllint' or 'xsltproc' were not found." ; \
else \
echo "Could not find prebuilt $@ manual page." ; \
Expand All @@ -720,7 +742,7 @@ else !HAVE_ASCIIDOC
fi

.txt.5:
@if [ -r "$@" ]; then \
@if [ -r "$@" ] $(SRC_PREBUILT_CLAUSE); then \
echo "Not (re)building $@ manual page, since 'asciidoc', 'xmllint' or 'xsltproc' were not found." ; \
else \
echo "Could not find prebuilt $@ manual page." ; \
Expand All @@ -729,7 +751,7 @@ else !HAVE_ASCIIDOC
fi

.txt.8:
@if [ -r "$@" ]; then \
@if [ -r "$@" ] $(SRC_PREBUILT_CLAUSE); then \
echo "Not (re)building $@ manual page, since 'asciidoc', 'xmllint' or 'xsltproc' were not found." ; \
else \
echo "Could not find prebuilt $@ manual page." ; \
Expand Down
5 changes: 3 additions & 2 deletions drivers/eaton-mib.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@

/* FIXME: split into multiple files (1 per snmp_info_t) and have XX_VERSION
* per file */

#define EATON_APHEL_MIB_VERSION "0.50"

/* APHEL-GENESIS-II-MIB (monitored ePDU)
Expand Down Expand Up @@ -233,7 +234,7 @@ static snmp_info_t eaton_aphel_revelation_mib[] = {
/* Eaton PDU-MIB - Marlin MIB
* ************************** */

#define EATON_MARLIN_MIB_VERSION "0.41"
#define EATON_MARLIN_MIB_VERSION "0.42"
#define EATON_MARLIN_SYSOID ".1.3.6.1.4.1.534.6.6.7"
#define EATON_MARLIN_OID_MODEL_NAME ".1.3.6.1.4.1.534.6.6.7.1.2.1.2.0"

Expand Down Expand Up @@ -639,7 +640,7 @@ static snmp_info_t eaton_marlin_mib[] = {
{ "outlet.%i.power", 0, 1.0, ".1.3.6.1.4.1.534.6.6.7.6.5.1.2.%i.%i", NULL, SU_OUTLET | SU_TYPE_DAISY_1, NULL, NULL },
/* FIXME: handle non switchable units (only measurements), which do not expose this OID */
{ "outlet.%i.switchable", ST_FLAG_STRING, SU_INFOSIZE, ".1.3.6.1.4.1.534.6.6.7.6.6.1.3.%i.%i", "no", SU_FLAG_STATIC | SU_OUTLET | SU_FLAG_OK | SU_TYPE_DAISY_1, &eaton_outlet_switchability_info[0], NULL },
{ "outlet.%i.type", ST_FLAG_STRING, SU_INFOSIZE, ".1.3.6.1.4.1.534.6.6.7.6.6.1.5.%i.%i", "unknown", SU_FLAG_STATIC | SU_OUTLET | SU_TYPE_DAISY_1, &eaton_outlet_type_info[0], NULL },
{ "outlet.%i.type", ST_FLAG_STRING, SU_INFOSIZE, ".1.3.6.1.4.1.534.6.6.7.6.1.1.5.%i.%i", "unknown", SU_FLAG_STATIC | SU_OUTLET | SU_TYPE_DAISY_1, &eaton_outlet_type_info[0], NULL },

/* TODO: handle statistics
* outletWh.0.1
Expand Down
2 changes: 1 addition & 1 deletion drivers/openups-hid.c
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ static hid_info_t openups_hid2nut[] = {

/* Battery */
{"battery.type", 0, 0, "UPS.PowerSummary.iDeviceChemistry", NULL, "%s", HU_FLAG_STATIC, stringid_conversion},
{"battery.mfr.date", 0, 0, "UPS.PowerSummary.iOEMInformation", NULL, "%s", 0, stringid_conversion},
{"battery.mfr.date", 0, 0, "UPS.PowerSummary.iOEMInformation", NULL, "%s", HU_FLAG_STATIC, stringid_conversion},
{"battery.voltage", 0, 0, "UPS.PowerSummary.Voltage", NULL, "%.2f", HU_FLAG_QUICK_POLL, NULL},
/* { "battery.voltage.nominal", 0, 0, "UPS.PowerSummary.ConfigVoltage", NULL, NULL, HU_FLAG_QUICK_POLL, openups_vbat_info }, */
{"battery.current", 0, 0, "UPS.PowerSummary.Current", NULL, "%.3f", HU_FLAG_QUICK_POLL, NULL},
Expand Down
12 changes: 8 additions & 4 deletions m4/nut_check_asciidoc.m4
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ AC_DEFUN([NUT_CHECK_ASCIIDOC],
[
if test -z "${nut_have_asciidoc_seen}"; then
nut_have_asciidoc_seen=yes
# Note: this is for both asciidoc and a2x at this time
ASCIIDOC_MIN_VERSION="8.6.3"
# Note: this is checked in the configure script if PDF is of interest at all
DBLATEX_MIN_VERSION="0.2.5"
AC_PATH_PROGS([ASCIIDOC], [asciidoc])
if test -n "${ASCIIDOC}"; then
Expand Down Expand Up @@ -79,17 +83,17 @@ if test -z "${nut_have_asciidoc_seen}"; then
dnl Note that a common "nut_have_asciidoc" variable is in fact a flag
dnl that we have several tools needed for the documentation generation
dnl TODO? Rename the script variable and makefile flags to reflect this?
AC_MSG_CHECKING([if asciidoc version can build manpages (minimum required 8.6.3)])
AX_COMPARE_VERSION([${ASCIIDOC_VERSION}], [ge], [8.6.3], [
AC_MSG_CHECKING([if asciidoc version can build manpages (minimum required ${ASCIIDOC_MIN_VERSION})])
AX_COMPARE_VERSION([${ASCIIDOC_VERSION}], [ge], [${ASCIIDOC_MIN_VERSION}], [
AC_MSG_RESULT(yes)
nut_have_asciidoc="yes"
], [
AC_MSG_RESULT(no)
nut_have_asciidoc="no"
])
AC_MSG_CHECKING([if a2x version can build manpages (minimum required 8.6.3)])
AX_COMPARE_VERSION([${A2X_VERSION}], [ge], [8.6.3], [
AC_MSG_CHECKING([if a2x version can build manpages (minimum required ${ASCIIDOC_MIN_VERSION})])
AX_COMPARE_VERSION([${A2X_VERSION}], [ge], [${ASCIIDOC_MIN_VERSION}], [
AC_MSG_RESULT(yes)
], [
AC_MSG_RESULT(no)
Expand Down
4 changes: 2 additions & 2 deletions scripts/DMF/dmfsnmp/eaton-mib.dmf
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@
<snmp_info multiplier="0.001" name="outlet.%i.voltage.high.critical" oid=".1.3.6.1.4.1.534.6.6.7.6.3.1.7.%i.%i" outlet="yes" positive="yes" type_daisy="1" writable="yes"/>
<snmp_info multiplier="1.0" name="outlet.%i.power" oid=".1.3.6.1.4.1.534.6.6.7.6.5.1.2.%i.%i" outlet="yes" type_daisy="1"/>
<snmp_info default="no" flag_ok="yes" lookup="eaton_outlet_switchability_info" multiplier="128.0" name="outlet.%i.switchable" oid=".1.3.6.1.4.1.534.6.6.7.6.6.1.3.%i.%i" outlet="yes" static="yes" string="yes" type_daisy="1"/>
<snmp_info default="unknown" lookup="eaton_outlet_type_info" multiplier="128.0" name="outlet.%i.type" oid=".1.3.6.1.4.1.534.6.6.7.6.6.1.5.%i.%i" outlet="yes" static="yes" string="yes" type_daisy="1"/>
<snmp_info default="unknown" lookup="eaton_outlet_type_info" multiplier="128.0" name="outlet.%i.type" oid=".1.3.6.1.4.1.534.6.6.7.6.1.1.5.%i.%i" outlet="yes" static="yes" string="yes" type_daisy="1"/>
<snmp_info default="0" multiplier="1.0" name="outlet.group.count" oid=".1.3.6.1.4.1.534.6.6.7.1.2.1.21.%i" static="yes"/>
<snmp_info multiplier="128.0" name="outlet.group.%i.id" oid=".1.3.6.1.4.1.534.6.6.7.5.1.1.2.%i.%i" outlet_group="yes" static="yes" string="yes" type_daisy="1"/>
<snmp_info multiplier="128.0" name="outlet.group.%i.name" oid=".1.3.6.1.4.1.534.6.6.7.5.1.1.3.%i.%i" outlet_group="yes" static="yes" string="yes" type_daisy="1" writable="yes"/>
Expand Down Expand Up @@ -411,7 +411,7 @@
<snmp_info battery_status="yes" command="yes" multiplier="2.0" name="outlet.%i.load.off" oid=".1.3.6.1.4.1.20677.2.6.2.%i.0" outlet="yes"/>
<snmp_info battery_status="yes" command="yes" multiplier="3.0" name="outlet.%i.load.cycle" oid=".1.3.6.1.4.1.20677.2.6.2.%i.0" outlet="yes"/>
</snmp>
<mib2nut auto_check=".1.3.6.1.4.1.534.6.6.7.1.2.1.2.0" mib_name="eaton_epdu" name="eaton_marlin" oid=".1.3.6.1.4.1.534.6.6.7" snmp_info="eaton_marlin_mib" version="0.41"/>
<mib2nut auto_check=".1.3.6.1.4.1.534.6.6.7.1.2.1.2.0" mib_name="eaton_epdu" name="eaton_marlin" oid=".1.3.6.1.4.1.534.6.6.7" snmp_info="eaton_marlin_mib" version="0.42"/>
<mib2nut auto_check=".1.3.6.1.4.1.534.6.6.6.1.1.12.0" mib_name="aphel_revelation" name="aphel_revelation" oid=".1.3.6.1.4.1.534.6.6.6" snmp_info="eaton_aphel_revelation_mib" version="0.50"/>
<mib2nut auto_check=".1.3.6.1.4.1.17373.3.1.1.0" mib_name="aphel_genesisII" name="aphel_genesisII" oid=".1.3.6.1.4.1.17373" snmp_info="eaton_aphel_genesisII_mib" version="0.50"/>
<mib2nut auto_check=".1.3.6.1.4.1.20677.1" mib_name="pulizzi_switched1" name="pulizzi_switched1" oid=".1.3.6.1.4.1.20677.1" snmp_info="eaton_pulizzi_switched_mib" version="0.2"/>
Expand Down
22 changes: 15 additions & 7 deletions tools/gitlog2changelog.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,17 +44,25 @@
files = ""
continue
# Match the author line and extract the part we want
# (Don't use startswith to allow Author override inside commit message.)
elif 'Author:' in line:
authorList = re.split(': ', line, 1)
author = authorList[1]
author = author[0:len(author)-1]
authorFound = True
try:
author = authorList[1]
author = author[0:len(author)-1]
authorFound = True
except:
print ("Could not parse authorList = '%s'" % (line))

# Match the date line
elif 'Date:' in line:
elif line.startswith('Date:'):
dateList = re.split(': ', line, 1)
date = dateList[1]
date = date[0:len(date)-1]
dateFound = True
try:
date = dateList[1]
date = date[0:len(date)-1]
dateFound = True
except:
print ("Could not parse dateList = '%s'" % (line))
# The Fossil-IDs are ignored:
elif line.startswith(' Fossil-ID:') or line.startswith(' [[SVN:'):
continue
Expand Down

0 comments on commit c1a853e

Please sign in to comment.