void-packages/srcpkgs/sudoku/template
Đoàn Trần Công Danh 4b97cd2fb4 srcpkgs/s*: 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

19 lines
546 B
Bash

# Template file for 'sudoku'
pkgname=sudoku
version=1.0.5
revision=1
build_style=gnu-makefile
makedepends="ncurses-devel"
short_desc="Sudoku solver based on the initial work of Michael Kennett"
maintainer="Nick Hahn <nick.hahn@hotmail.de>"
license="Public Domain"
homepage="https://github.com/cinemast/sudoku"
distfiles="https://github.com/cinemast/sudoku/archive/v${version}.tar.gz"
checksum=3ce6d9b237546d4ac7cdb7a6bb0e47d5c99e696a710b8935bce40dc706d32ff2
do_install() {
vbin sudoku
vman sudoku.6
vinstall template 644 /usr/share/sudoku/
}