void-packages/srcpkgs/moon-buggy/template
Đoàn Trần Công Danh 765e304c4b srcpkgs/m*: 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

18 lines
589 B
Bash

# Template file for 'moon-buggy'
pkgname=moon-buggy
version=1.0.51
revision=5
build_style=gnu-configure
configure_args="--sharedstatedir=/var/db"
make_dirs="/var/db/moon-buggy 777 root root"
makedepends="ncurses-devel"
short_desc="A simple character graphics game"
maintainer="Enno Boland <gottox@voidlinux.org>"
license="GPL-2.0-only"
homepage="http://www.seehuhn.de/pages/moon-buggy"
distfiles="http://m.seehuhn.de/programs/$pkgname-$version.tar.gz"
checksum=352dc16ccae4c66f1e87ab071e6a4ebeb94ff4e4f744ce1b12a769d02fe5d23f
post_extract() {
sed -i 's/key_name/Key_Name/g' keyboard.c
}