colordiff: Update to 1.0.19

This commit is contained in:
Alexey Pavlov 2020-05-30 11:45:07 +03:00
parent cbbd8328c8
commit b96ce3828c
3 changed files with 18 additions and 40 deletions

View File

@ -1,18 +0,0 @@
diff -aurN 000/colordiff.pl 001/colordiff.pl
--- 000/colordiff.pl
+++ 001/colordiff.pl
@@ -503,7 +503,13 @@
}
}
elsif ($diff_type eq 'diffu') {
- if (/^-/) {
+ if (/^--- /) {
+ print "$colour{darkyellow}";
+ }
+ elsif (/^\+\+\+ /) {
+ print "$colour{darkyellow}";
+ }
+ elsif (/^-/) {
print "$file_old";
}
elsif (/^\+/) {

View File

@ -1,12 +1,12 @@
diff -aurN 001/Makefile 002/Makefile
--- 001/Makefile
+++ 002/Makefile
@@ -20,7 +20,7 @@
@@ -21,7 +21,7 @@
perl -p -i -e 's#<div class=\"refentry\"#<div id=\"content\"><div class=\"refentry\"#' colordiff.html
.PHONY: install
-install:
+install: doc
install -d ${DESTDIR}${INSTALL_DIR}
$(INSTALL) -d ${DESTDIR}${INSTALL_DIR}
sed -e "s%/etc%${ETC_DIR}%g" colordiff.pl > \
${DESTDIR}${INSTALL_DIR}/colordiff

View File

@ -1,36 +1,32 @@
# Maintainer: Renato Silva <br.renatosilva@gmail.com>
pkgname='colordiff'
pkgver='1.0.18'
pkgname=colordiff
pkgver=1.0.19
pkgrel=1
pkgdesc='Diff wrapper with pretty syntax highlighting'
url='https://www.colordiff.org/'
license=('GPL2')
arch=(any)
depends=(diffutils perl)
arch=('any')
depends=('diffutils' 'perl')
makedepends=(w3m)
backup=(etc/colordiffrc)
source=(${pkgname}-${pkgver}.tar.gz::"https://github.com/daveewart/colordiff/archive/v${pkgver}.tar.gz"
001-colorize-filenames.patch
002-build-fix.patch)
sha256sums=('b78686a64e90032aec7fbfa7477eba2365b9e4ff5d396a1b22744ac2b976eaad'
'deb380507f19aaa2eb73d7cbff208572f4799b4e94de0cecbba2e3f5f19e2308'
'24f406f30a5fe3d67b8bbb8ffbb5fd482b44a8774c87197a5181cf16ee1db01b')
sha256sums=('bdfd418bf1bcf96497f9809f76565ad7e03b9eb0a1b685e91348d231ccc2cca4'
'8d2f99a79126763babdf93ff1691c9e037a843f94afe5e631e1e7fcfae22713d')
prepare() {
cd "${pkgname}-${pkgver}"
patch -p1 -i "${srcdir}/001-colorize-filenames.patch"
patch -p1 -i "${srcdir}/002-build-fix.patch"
# xmlto txt conversion apparently does not work even with w3m
# anyhow only man page is packaged
sed -i "s/xmlto -vv txt colordiff.xml//" makefile
sed -i "s/mv colordiff.txt README//" makefile
cd "${pkgname}-${pkgver}"
patch -p1 -i "${srcdir}/002-build-fix.patch"
# xmlto txt conversion apparently does not work even with w3m
# anyhow only man page is packaged
sed -i "s/xmlto -vv txt colordiff.xml//" makefile
sed -i "s/mv colordiff.txt README//" makefile
}
package() {
cd "${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" MAN_DIR='/usr/share/man/man1' INSTALL_DIR='/usr/bin' install doc
install -Dm644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
cd "${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" MAN_DIR='/usr/share/man/man1' INSTALL_DIR='/usr/bin' install doc
install -Dm644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
}