Skip to content

Commit

Permalink
break up tr commands with temp file
Browse files Browse the repository at this point in the history
  • Loading branch information
carolynzech committed Jan 9, 2025
1 parent 954fa15 commit cdadad2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/std-analysis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,10 @@ for f in $results/*overall.csv; do
fname=$(basename $f)
crate=${fname%_scan_overall.csv}
echo -n "$crate," >> $summary
tr -d [:alpha:]_,; < $f | tr -s '\n' ',' \
>> $summary
temp_file=$(mktemp)
tr -d '[:alpha:]_,;' < "$f" > $temp_file
tr -s '\n' ',' < $temp_file >> "$summary"
rm $temp_file
echo "" >> $summary
done

Expand Down

0 comments on commit cdadad2

Please sign in to comment.