invalid characters

Asked by Narada2XK

when I download some items, they sometimes come with an invalid character (usually a colon ':').
How can I prevent lottanzb from including these characters and is there a command I can use
to remove all possible colons from a bunch of folders or files?

Question information

Language:
English Edit question
Status:
Answered
For:
LottaNZB Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Severin H (severinh) said :
#1

Hi Narada2XK,

as you've pointed out, these characters are currently not being removed automatically be LottaNZB, but this might be fixed in the upcoming LottaNZB 0.6.

In the meantime, you can use the command line to drop colons from all NZB file names in a certain directory (and its subdirectories!):

1. Open a terminal.
2. Use 'cd' to navigate to the directory in question.
3. find . -name "*.nzb" | xargs rename 's/://'

Of course, you can also use this to replace other characters. 's/old/new/' means that all instances of 'old' will be replaced by 'new'. Both may be regular expressions. Please note however that some characters, such as . ( ) [ ] \ { } etc. have a special meaning in regular expressions and should therefore be prepended with a backslash \

Hope this helps!

Regards,
Severin

Revision history for this message
Narada2XK (narada2xk) said :
#2

@Severin Heiniger: Thanks, I'd try it out. I am not sure why LottaNZB is doing this all of a sudden. I never had this problem before. I usually add .nzb files from the content id from newzbins and they sometimes have in ':'. But I guess I could always run the 's/://' to remove them from the folders and files if necessary.

Can you help with this problem?

Provide an answer of your own, or ask Narada2XK for more information if necessary.

To post a message you must log in.