script
unknown
sh
a year ago
497 B
20
Indexable
#!/bin/bash
output_file="results.txt"
header="sim, grid, Tcells, DCs, obstacles, seed, number of contacts"
if [ "$#" -eq 1 ]; then
output_file="$1"
add_header=false
else
output_file="$output_file"
add_header=true
fi
if [ "$add_header" = true ]; then
echo "$header" > "$output_file"
else
touch "$output_file"
fi
for file in *; do
if [ -f "$file" ] && [ "$file" != "$output_file" ]; then
tail -n +2 "$file" >> "$output_file"
fi
doneEditor is loading...
Leave a Comment