void-packages/srcpkgs/urlview/template
Đoàn Trần Công Danh 5769f150de srcpkgs/u*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

24 lines
756 B
Bash

# Template file for 'urlview'
pkgname=urlview
version=0.9
revision=1
build_style=gnu-configure
hostmakedepends="mk-configure"
makedepends="ncurses-devel"
conf_files="/etc/urlview.conf"
short_desc="Extract URLs from a text file and allow the user to select via a menu"
maintainer="Liam Howley <liam.howley@hotmail.com>"
license="GPL-2.0"
homepage="https://github.com/sigpipe/urlview"
distfiles="https://gnupg.org/ftp/mutt/contrib/$pkgname-$version.tar.gz"
checksum=74d18026e84e3cd70a3fdd1a7247a68031b0c1c1c6d761d64b7063ff71091cc3
pre_configure() {
sed -i '/install-data-local/,/^$/d' Makefile.am
}
post_install() {
vbin url_handler.sh
vinstall sample.urlview 0644 etc urlview.conf
vinstall sample.urlview 0644 etc/skel .urlview
vman urlview.{man,1}
}