diff options
-rwxr-xr-x | .profile | 7 | ||||
-rw-r--r-- | .quiltrc | 26 |
2 files changed, 20 insertions, 13 deletions
@@ -33,6 +33,13 @@ if command -v nproc >/dev/null; then MAKEFLAGS="-j$((2 * $(nproc)))"; export MAKEFLAGS fi +QUILT_NO_DIFF_INDEX=t; export QUILT_NO_DIFF_INDEX +QUILT_NO_DIFF_TIMESTAMPS=t; export QUILT_NO_DIFF_TIMESTAMPS +QUILT_DIFF_ARGS="-p ab --color=auto"; export QUILT_DIFF_ARGS +QUILT_REFRESH_ARGS="-p ab"; export QUILT_REFRESH_ARGS +QUILT_PUSH_ARGS=--color=auto; export QUILT_PUSH_ARGS +QUILT_DIFF_OPTS=-p; export QUILT_DIFF_OPTS + MAILDIR="$HOME/.fmail"; export MAILDIR BROWSER=firefox; export BROWSER TERMCMD=xfce4-terminal; export TERMCMD @@ -1,16 +1,16 @@ -# all from: -# https://raphaelhertzog.com/2012/08/08/how-to-use-quilt-to-manage-patches-in-debian-packages/ +# -*- sh -*- -# detect Debian quilt patches -for where in ./ ../ ../../ ../../../ ../../../../ ../../../../../; do - if [ -e ${where}debian/rules -a -d ${where}debian/patches ]; then - export QUILT_PATCHES=debian/patches - break +# Use debian/patches unless it is dominated by a patches/ with a series file. +file="$PWD" +while true; do + if [ ! \( -O "$file" -o -G "$file" \) -o "$file" = / -o -e \ + "$file/${QUILT_PATCHES:-patches}/${QUILT_SERIES:-series}" ]; then + break + elif [ -e "$file/debian/rules" -a -d "$file/debian/patches" ]; then + QUILT_PATCHES=debian/patches + break + else + file="$(dirname "$file")" fi done - -# generate nicer patches & use colour -QUILT_PUSH_ARGS="--color=auto" -QUILT_DIFF_ARGS="--no-timestamps --no-index -p ab --color=auto" -QUILT_REFRESH_ARGS="--no-timestamps --no-index -p ab" -QUILT_DIFF_OPTS='-p' +unset file |