From 5e2b40d48b7ccefa28e808606c66f2928989f1fb Mon Sep 17 00:00:00 2001 From: Aminda Suomalainen Date: Sun, 5 Mar 2023 11:27:59 +0200 Subject: [PATCH] combine.bash: simple script to make a file containing everything --- .gitattributes | 1 + .gitignore | 3 ++- combine.bash | 11 +++++++++++ 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100755 combine.bash diff --git a/.gitattributes b/.gitattributes index 8d35de0..5b4593e 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1 +1,2 @@ * text=auto eol=lf linguist-detectable +combine.bash text eol=lf diff --git a/.gitignore b/.gitignore index 4298e22..664e043 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -.~*# +.~*#* +combined.csv diff --git a/combine.bash b/combine.bash new file mode 100755 index 0000000..e7fc17c --- /dev/null +++ b/combine.bash @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +echo "Account address,Show boosts" > combined.csv + +for csv in *.csv; do + if [ "$csv" == "combined.csv" ]; then + continue; + else + cat combined.csv + cat $csv | grep -v "Account address,Show boosts" | tee -a combined.csv + fi +done