Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Is this the Zsh way for doing this?



On Mar 28, 10:07pm, DervishD wrote:
}
}     Thanks a lot for your answer :)

No problem; you're welcome.

} >     # At this point you might also want to clean wildcards and slashes
} >     # out of $track_name, but that's up to you.  Your original doesn't.
} 
}     No, it doesn't because I didn't thought of it :( Thanks for
} pointing. Could it be solved using the (q) flag or should I use ${//}
} and substitute every dangerous character for a safe version?

The substituion is necessary for slashes, because you can't even create a
file with slashes in the name.

The (q) flag is _not_ necessary for other metacharacters when creating
the file (the argument to "mv" is already double-quoted); the problem
would be with manipulating the names later.  So doing either nothing or
the substitution is appropriate in that case.



Messages sorted by: Reverse Date, Date, Thread, Author