Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
I want to remove a line which begins with <Field name="LastDate" in a xml file.
<Field name="LastDate"
The space seems to be creating issues here sed -i /^<Field name="LastDate"/d test.xml. How do I go about this?
sed -i /^<Field name="LastDate"/d test.xml
スクリプトを引用する必要があります(テキストにはすでに二重引用符が含まれているため、一重引用符):
$ sed -i '/^<Field name="LastDate"/d' test.xml