I'm sure there's an elegant awk solution out there but here's my somewhat shitty loop for it. It assumes all files keep the same structure as the ones you've posted.
for f in *_coding.fasta; do new="$(echo $f | tr '=' '_' | cut -d '_' -f 5)"; mv $f $new.fasta; done
ADD COMMENT
• link
updated 4.9 years ago by
Ram
44k
•
written 8.9 years ago by
Jenez
▴
540