void-packages/srcpkgs/xsel/template
Đoàn Trần Công Danh 3353bf4722 srcpkgs/x*: 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

12 lines
474 B
Bash

# Template file for 'xsel'
pkgname=xsel
version=1.2.0
revision=4
build_style="gnu-configure"
makedepends="libXt-devel"
short_desc="Command-line getting and setting the contents of the X selection"
maintainer="Steven R <dev@styez.com>"
license="custom"
homepage="http://www.vergenet.net/~conrad/software/xsel/"
distfiles="http://www.vergenet.net/~conrad/software/xsel/download/xsel-${version}.tar.gz"
checksum=b927ce08dc82f4c30140223959b90cf65e1076f000ce95e520419ec32f5b141c