summaryrefslogtreecommitdiff
path: root/openttd-git/update-patches
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-01-10 11:34:59 +0100
committerErich Eckner <git@eckner.net>2019-01-10 11:34:59 +0100
commitc6ce0195cb5ea8bcb092190e3e45fb42fad6cf33 (patch)
tree1831e3fa24175b67b5e3624635eabea08d2529f8 /openttd-git/update-patches
parent154965bb0a96db004e56d8c7b3b69f4c6c58c07c (diff)
downloadarchlinuxewe-c6ce0195cb5ea8bcb092190e3e45fb42fad6cf33.tar.xz
openttd-git: update-patches neu zum einfacheren aktualisieren der Patches
Diffstat (limited to 'openttd-git/update-patches')
-rwxr-xr-xopenttd-git/update-patches22
1 files changed, 22 insertions, 0 deletions
diff --git a/openttd-git/update-patches b/openttd-git/update-patches
new file mode 100755
index 000000000..02811856f
--- /dev/null
+++ b/openttd-git/update-patches
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+cd "$(dirname "$0")"
+eval "$(
+ sed -n '
+ /^source=(/,/)/ p
+ ' PKGBUILD
+)"
+
+git -C openttd-git fetch local
+git -C openttd-git fetch --all -p
+
+printf '%s\n' "${source[@]}" \
+ | sed '
+ s/\.patch$//
+ t
+ d
+ ' \
+ | while read -r patch; do
+ git -C openttd-git diff master "remotes/local/${patch}" -- \
+ > "${patch}.patch"
+ done