-
Notifications
You must be signed in to change notification settings - Fork 0
/
gabs-pop-mesa
executable file
·43 lines (34 loc) · 1.25 KB
/
gabs-pop-mesa
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/zsh -x
BASE_PATH="$(pwd)/builtin_packages/mesa-git-gentz"
[[ "${1}" == "" ]] && exit
cd ${1} || exit $?
ssh-add ~/.ssh/id_ed25519_mesa
[[ "$(git status | grep "git am --abort")" != "" ]] && git am --abort
git remote rm upstream
git remote rm origin
git remote add upstream git@gitlab.freedesktop.org:mesa/mesa.git
git remote add origin git@gitlab.freedesktop.org:ZeGentzy/mesa.git
rm src -rf
git checkout -- .
git fetch upstream || exit $?
git fetch origin || exit $?
make_branch() {
read -q "REPLY?Do ${1}? "
[[ ${REPLY} =~ ^[Yy]$ ]] || return
git checkout upstream/master || exit $?
git branch -D "${1}"
git checkout -b "${1}" || exit $?
for PATCH in "${@:2}"; do
git am "${PATCH}" || exit $?
done
rm "${@:2}"
git format-patch HEAD~"$(( $# - 1 ))" | xargs -I% mv % "${BASE_PATH}"
git push --set-upstream origin "${1}" --force || exit $?
}
make_branch egl-trans-sup \
"${BASE_PATH}/0001-egl-Add-EGL_CONFIG_SELECT_GROUP_MESA-ext.patch" \
"${BASE_PATH}/0002-egl-Fixes-transparency-with-EGL-and-X11.patch" \
"${BASE_PATH}/0003-egl-Puts-RGBA-visuals-in-the-second-config-selection.patch" \
"${BASE_PATH}/0004-egl-Configs-w-o-double-buffering-support-have-no-EGL.patch"
cd "${BASE_PATH}"
updpkgsums