Skip to content

Instantly share code, notes, and snippets.

@poeli
Last active February 20, 2020 00:14
Show Gist options
  • Save poeli/6e71e22fc5e2e50776e263a52dd72bc4 to your computer and use it in GitHub Desktop.
Save poeli/6e71e22fc5e2e50776e263a52dd72bc4 to your computer and use it in GitHub Desktop.
Split multiFASTA to singleFASTA and use seq id as filenames
awk -F ' ' '{ if(/^>/){F=sprintf("%s.fasta", substr($1,2)); print > F;next;} else {print >> F}}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment