about summary refs log tree commit diff
path: root/third_party/git/t/t4213-log-tabexpand.sh
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-09-21T10·03+0300
committerVincent Ambo <mail@tazj.in>2021-09-21T11·29+0300
commit43b1791ec601732ac31195df96781a848360a9ac (patch)
treedaae8d638343295d2f1f7da955e556ef4c958864 /third_party/git/t/t4213-log-tabexpand.sh
parent2d8e7dc9d9c38127ec4ebd13aee8e8f586a43318 (diff)
chore(3p/git): Unvendor git and track patches instead r/2903
This was vendored a long time ago under the expectation that keeping
it in sync with cgit would be easier this way, but it has proven not
to be a big issue.

On the other hand, a vendored copy of git is an annoying maintenance
burden. It is much easier to rebase the single (dottime) patch that we
have.

This removes the vendored copy of git and instead passes the git
source code to cgit via `pkgs.srcOnly`, which includes the applied
patch so that cgit can continue rendering dottime.

Change-Id: If31f62dea7ce688fd1b9050204e9378019775f2b
Diffstat (limited to 'third_party/git/t/t4213-log-tabexpand.sh')
-rwxr-xr-xthird_party/git/t/t4213-log-tabexpand.sh105
1 files changed, 0 insertions, 105 deletions
diff --git a/third_party/git/t/t4213-log-tabexpand.sh b/third_party/git/t/t4213-log-tabexpand.sh
deleted file mode 100755
index 53a4af324495..000000000000
--- a/third_party/git/t/t4213-log-tabexpand.sh
+++ /dev/null
@@ -1,105 +0,0 @@
-#!/bin/sh
-
-test_description='log/show --expand-tabs'
-
-. ./test-lib.sh
-
-HT="	"
-title='tab indent at the beginning of the title line'
-body='tab indent on a line in the body'
-
-# usage: count_expand $indent $numSP $numHT @format_args
-count_expand ()
-{
-	expect=
-	count=$(( $1 + $2 )) ;# expected spaces
-	while test $count -gt 0
-	do
-		expect="$expect "
-		count=$(( $count - 1 ))
-	done
-	shift 2
-	count=$1 ;# expected tabs
-	while test $count -gt 0
-	do
-		expect="$expect$HT"
-		count=$(( $count - 1 ))
-	done
-	shift
-
-	# The remainder of the command line is "git show -s" options
-	case " $* " in
-	*' --pretty=short '*)
-		line=$title ;;
-	*)
-		line=$body ;;
-	esac
-
-	# Prefix the output with the command line arguments, and
-	# replace SP with a dot both in the expected and actual output
-	# so that test_cmp would show the difference together with the
-	# breakage in a way easier to consume by the debugging user.
-	{
-		echo "git show -s $*"
-		echo "$expect$line"
-	} | sed -e 's/ /./g' >expect
-
-	{
-		echo "git show -s $*"
-		git show -s "$@" |
-		sed -n -e "/$line\$/p"
-	} | sed -e 's/ /./g' >actual
-
-	test_cmp expect actual
-}
-
-test_expand ()
-{
-	fmt=$1
-	case "$fmt" in
-	*=raw | *=short | *=email)
-		default="0 1" ;;
-	*)
-		default="8 0" ;;
-	esac
-	case "$fmt" in
-	*=email)
-		in=0 ;;
-	*)
-		in=4 ;;
-	esac
-	test_expect_success "expand/no-expand${fmt:+ for $fmt}" '
-		count_expand $in $default $fmt &&
-		count_expand $in 8 0 $fmt --expand-tabs &&
-		count_expand $in 8 0 --expand-tabs $fmt &&
-		count_expand $in 8 0 $fmt --expand-tabs=8 &&
-		count_expand $in 8 0 --expand-tabs=8 $fmt &&
-		count_expand $in 0 1 $fmt --no-expand-tabs &&
-		count_expand $in 0 1 --no-expand-tabs $fmt &&
-		count_expand $in 0 1 $fmt --expand-tabs=0 &&
-		count_expand $in 0 1 --expand-tabs=0 $fmt &&
-		count_expand $in 4 0 $fmt --expand-tabs=4 &&
-		count_expand $in 4 0 --expand-tabs=4 $fmt
-	'
-}
-
-test_expect_success 'setup' '
-	test_tick &&
-	sed -e "s/Q/$HT/g" <<-EOF >msg &&
-	Q$title
-
-	Q$body
-	EOF
-	git commit --allow-empty -F msg
-'
-
-test_expand ""
-test_expand --pretty
-test_expand --pretty=short
-test_expand --pretty=medium
-test_expand --pretty=full
-test_expand --pretty=fuller
-test_expand --pretty=raw
-test_expand --pretty=email
-
-test_done