better support for README.md; timeout for svn2cl and git2cl
This commit is contained in:
@@ -171,7 +171,7 @@ AC_DEFUN([AX_INIT_STANDARD_PROJECT], [
|
||||
AX_SUBST(HOME)
|
||||
if test -f README.md; then
|
||||
README=$(tail -n +3 README.md)
|
||||
DESCRIPTION=$(head -1 README.md)
|
||||
DESCRIPTION=$(head -1 README.md | sed 's,^#\+ *,,;s, *#\+$,,')
|
||||
else
|
||||
README=$(tail -n +3 README)
|
||||
DESCRIPTION=$(head -1 README)
|
||||
|
@@ -143,7 +143,7 @@ GENERATED FILES
|
||||
* test/runtests.sh - template file to run test scripts, i.e. docker based
|
||||
* AUTHORS - replace your name in AUTHORS before first run
|
||||
* NEWS - empty file add your project's news
|
||||
* README - add project description (first line is header, followed by an empty line)
|
||||
* README (or README.md) - add project description (first line: header, followed by empty line)
|
||||
* configure.ac - global configuration file template
|
||||
* makefile.am - global makefile template
|
||||
* ${DEFAULT_PROJECT_NAME}.desktop.in - linux desktop file
|
||||
@@ -514,13 +514,18 @@ vcs2cl() {
|
||||
else
|
||||
touch "ChangeLog"
|
||||
fi
|
||||
if test -x $(which timeout); then
|
||||
local TIMEOUT="timeout 10"
|
||||
else
|
||||
local TIMEOUT=
|
||||
fi
|
||||
if test -x $(which ${VCS}2cl); then
|
||||
if test "${VCS}" = "git"; then
|
||||
${VCS}2cl > ChangeLog
|
||||
$TIMEOUT ${VCS}2cl || true > ChangeLog
|
||||
elif test "${VCS}" = "svn"; then
|
||||
${VCS}2cl --break-before-msg -a -i
|
||||
$TIMEOUT ${VCS}2cl --break-before-msg -a -i || true
|
||||
elif test -n "${VCS}"; then
|
||||
${VCS}2cl
|
||||
$TIMEOUT ${VCS}2cl || true
|
||||
fi
|
||||
fi
|
||||
if test $exists -eq 0; then
|
||||
@@ -563,11 +568,18 @@ EOF
|
||||
to NEWS <<EOF && notice "please edit NEWS"
|
||||
$(date) created ${DEFAULT_PROJECT_NAME}
|
||||
EOF
|
||||
to README <<EOF && notice "please edit README"
|
||||
if test -e README.md; then
|
||||
README=README.md
|
||||
else
|
||||
README=README
|
||||
to README <<EOF && notice "please edit README"
|
||||
|
||||
${DEFAULT_PROJECT_NAME}
|
||||
|
||||
add description for ${DEFAULT_PROJECT_NAME}
|
||||
EOF
|
||||
fi
|
||||
DESCRIPTION=$(head -1 $README | sed 's,^#\+ *,,;s, *#\+$,,')
|
||||
to configure.ac <<EOF && notice "please edit configure.ac, then rerun $0" && exit 0
|
||||
${HEADER}# default is generated from AUTHORS and project name
|
||||
PROJECT_URL=
|
||||
@@ -1052,7 +1064,7 @@ to --condition AX_USE_NODEJS nodejs/etc/default/${PACKAGE_NAME} <<EOF
|
||||
EOF
|
||||
to --condition AX_USE_NODEJS nodejs/etc/init/${PACKAGE_NAME}.conf <<EOF
|
||||
#!upstart
|
||||
description "$(head -1 README)"
|
||||
description "$DESCRIPTION"
|
||||
author "$(head -1 AUTHORS)"
|
||||
|
||||
start on (local-filesystems and net-device-up)
|
||||
@@ -1092,7 +1104,7 @@ end script
|
||||
EOF
|
||||
to --condition AX_USE_NODEJS nodejs/etc/systemd/system/${PACKAGE_NAME}.service <<EOF
|
||||
[Unit]
|
||||
Description=$(head -1 README)
|
||||
Description=$DESCRIPTION
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/nodejs /usr/share/${PACKAGE_NAME}/nodejs/${PACKAGE_NAME}
|
||||
@@ -1220,11 +1232,11 @@ to --condition AX_USE_NODEJS nodejs/views/index.ejs <<EOF
|
||||
<link href="stylesheets/style.css" rel="stylesheet" type="text/css" />
|
||||
<script type="text/javascript" src="/socket.io/socket.io.js"></script>
|
||||
<script type="text/javascript" src="javascripts/${PACKAGE_NAME}.js"></script>
|
||||
<title>$(head -1 README)</title>
|
||||
<title>$DESCRIPTION</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>$(head -1 README)</h1>
|
||||
<h1>$DESCRIPTION</h1>
|
||||
<p>generated by bootstrap, please edit</p>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1575,7 +1587,7 @@ EOF2
|
||||
EOF
|
||||
to debian/docs <<EOF
|
||||
NEWS
|
||||
README
|
||||
$README
|
||||
EOF
|
||||
to --condition AX_USE_LIBTOOL debian/${PACKAGE_NAME}.install <<EOF
|
||||
usr/lib/lib*.so.*
|
||||
@@ -1620,7 +1632,7 @@ fi)
|
||||
$(if testtag AX_RPM_DEPEND; then echo "Requires: @RPM_DEPEND@"; fi)
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
BuildRequires: which, pkgconfig, gnupg, expect, ${VCSDEPENDS_RPM}make, automake, autoconf, rpm-build$(
|
||||
BuildRequires: which, pkgconfig, pandoc, gnupg, expect, ${VCSDEPENDS_RPM}make, automake, autoconf, rpm-build$(
|
||||
if testtag AX_USE_CXX; then
|
||||
echo -n ", binutils-devel, gcc-c++"
|
||||
fi
|
||||
@@ -1800,8 +1812,15 @@ dist_noinst_DATA = ax_check_qt.m4 bootstrap.sh \\
|
||||
mac-create-app-bundle.sh resolve-debbuilddeps.sh \\
|
||||
dependency-graph.sh template.sh \\
|
||||
sql-to-dot.sed
|
||||
dist_doc_DATA = AUTHORS NEWS README COPYING INSTALL ChangeLog
|
||||
dist_doc_DATA = AUTHORS NEWS $README COPYING INSTALL ChangeLog
|
||||
$(if test -e README.md -a ! -e README; then
|
||||
cat <<EOF2
|
||||
|
||||
README: README.md
|
||||
|
||||
CLEANFILES = README
|
||||
EOF2
|
||||
fi)
|
||||
MAINTAINERCLEANFILES = makefile.in
|
||||
EOF
|
||||
to --condition AX_USE_LIBTOOL src/${PACKAGE_NAME}.pc.in <<EOF
|
||||
|
Reference in New Issue
Block a user