I use this code to replace some text in an HTML file:
sed -i 's/tttt/new-word/g' /home/zjm1126/*.html
This is not a search for files in subfolders. How to apply this command to subfolders?
find /home/zjm1126/ -name '*.html' -print0 | xargs -0 sed -i 's/tttt/new-word/g'
Can you try something like
for z in `find /home/zjm1126/ -type f -name "*.html"`; do sed -e 's/tttt/new-word/g' $z>temp; done
Source: https://habr.com/ru/post/888204/More articles:How to programmatically display the mail setup page on an iPhone? - emailTreeview hide [+] [-] buttons - c #Removing a schema and all its contents in DB2 8.x - sqlTreeView + Icon - c #How to get mp4 / mov / m4v video for YouTube video? - phpWhy doesn't the automatically generated subclass NSManagedObject have a βrightβ header? - objective-cCurrency analysis String in java - javaUpdating Model Attributes - ruby-on-railsHow to analyze Google search results using Nokogiri? - htmlPython NaN and validation - pythonAll Articles