shell command to remove some XML tag is needed

Hi all,
I have a file which i have to remove some line from it,
the lines that i have to remove from my file is as below:

</new_name></w"s" langue="Fr-fr" version="1.0" encoding="UTF-8" ?> <New_name>

and it is finding at the middle of my file,
is there any command line in linux to do it or do i have to do by a script
if so how to do it, i am not a shell/perl/bash developer

Thank you for your helps in advance
Regards
Arash

Maybe something like

sed '/<[^>]*langue=[^>]*version=[^>]*encoding=[^>]*>/d' inputfile >outputfile

Up to you to see if the pattern could be shorten, depending on the content of your input file

dear,
thank you for your reply

but i want to remove the whole line, do i have to youse the same commande?
thank you

---------- Post updated at 07:35 AM ---------- Previous update was at 07:21 AM ----------

merci bcp mais ca n a pas marcher,
ca me creer des fichier vide

Maybe your xml file is made of one very long line...

what do you get when entering the following command :

wc -l <yourfile

?

i run that command and i got 0 raportone.xml

you mean your file has 0 line ????

no the tailt of my file is 114.257 KB
and when i see the contant, i have a big XML file

If your file doesn't have an empty size and contains xml data in it, you should at least have 1 line in it.

So:

wc -l <yourfile

should return a value that differs from 0.

no my xml file in deed exist and i can check it from FTP it has 114257 KB
but the new one that i creat by the commande line is empty

Could you please upload the file you are trying to parse?
So people will then be able to provide a more accurate help to you

---------- Post updated at 11:47 AM ---------- Previous update was at 11:44 AM ----------

first of all if you want to parse a file, you have to make sure that the file is not emplty, if it is empty, you will have nothing to parse :slight_smile:
So please first make sure that you have properly downloaded or FTP the file (and that the one you get is not empty and contains the expected data you want to parse).

how can i upload it?
thank you