From 4d9759073ffb5f916eb4ae00c6c1ed78be9eb372 Mon Sep 17 00:00:00 2001 From: kaotisk Date: Thu, 12 Dec 2024 19:21:08 +0200 Subject: Fixing weird bug from tail program on FreeBSD --- lib/_ak_fs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/_ak_fs b/lib/_ak_fs index fb493c3..10f4f17 100755 --- a/lib/_ak_fs +++ b/lib/_ak_fs @@ -42,7 +42,7 @@ function _ak_fs_create_dir_for_hash(){ function _ak_fs_appendLastIfNotEven(){ if [ "$(( $(wc -l "$1" | awk '{ print $1 }') % 2))" -ne 0 ] then - tail -n 1 "$1" >> "$1" + head -n 1 "$1" >> "$1" fi } -- cgit v1.2.3