diff --git a/.pypt/commitlog b/.pypt/commitlog index 19c0e5c..6a35499 100755 --- a/.pypt/commitlog +++ b/.pypt/commitlog @@ -88,7 +88,7 @@ def main(): new_version = args.new_version[0] with open(filename) as fh: - e = re.findall('#~ C(.*?) MESSAGE START ~#\n(.*?)\n#~ C(.*?) MESSAGE ' + e = re.findall('#~ (C[A-Z]+) MESSAGE START ~#\n(.*?)\n#~ (C[A-Z]+) MESSAGE ' 'END ~#', fh.read(), flags=re.S) for i in e: @@ -97,7 +97,6 @@ def main(): print('ERROR: mismatched tags') return 1 else: - i[0] = 'C' + i[0] # regexp hack if i[0] == 'COMMIT': with open(filename + '-commit', 'w') as fh: fh.write(i[1]) diff --git a/release b/release index b396f9d..dd28d74 100755 --- a/release +++ b/release @@ -138,8 +138,8 @@ sed "s/# $PROJECT v.*/# $PROJECT v$version/" $PROJECTLC/**/*.py -i sed "s/__version__ = .*/__version__ = '$version'/g" $PROJECTLC/__init__.py -i sed "s/:Date: .*/:Date: $date/g" docs/*.rst -i -sed "s/pkgver=.*/pkgver=$version/g" PKGBUILD -i || true -sed "s/pkgver=.*/pkgver=$version/g" PKGBUILD-git -i || true +[[ -e "PKGBUILD" ]] && sed "s/pkgver=.*/pkgver=$version/g" PKGBUILD -i || true +[[ -e "PKGBUILD-git" ]] && sed "s/pkgver=.*/pkgver=$version/g" PKGBUILD-git -i || true cp docs/README.rst docs/CHANGELOG.rst docs/CONTRIBUTING.rst . cp docs/README.rst README