I still wouldn't adivse this because that doesn't catch all the potential special characters. You've got to deal with ampersands, pipe symbols, colons, and all sorts of other things. (Which is why I didn't bother extending).
If you know your sequence headers very well, then you might be OK!
What does
cat *.fasta | grep -e '>' | head -n 10give you? It would be helpful to see the structure of the sequence headers, in order to provide a proper solution.> AAA64362/A/Japan/305+/1957
> AAA64363/A/RI/5-/1957
> AAA64364/A/Japan/305-/1957
...and so on
Ok, so how do you want the files named according to these headers?
The full header name as the filename with underscore as separator will be ideal.
There are no underscores in the header, do you want the slash (/) to be replaced with the underscores?
I agree, using forward slash in filenames is not the best idea