- insert lines behind a certain line:
- sed -i '/Ini_N/ a\
- eee
- /Ini_N/ a\
- sss
- ' "Config_DPCM.ini~"
- replacing a line including 'foo':
- sed -i 's/^.*foo.*$/another string/' myfile.txt
- replacing a line:
- sed -i "s/Ini_T=5./Ini_T=2./g" `find ./ -name Config_DPCM.ini`
- Remove empty lines with sed
- find string in a certain type of files using grep
-
- find . -name "*.txt" -print
- grep -r --include=*.m "versions" ./
name only:
- Compare two directories
- diff -r --exclude="*.yuv" ML-My-Planck MMSE-My-Planck
|
No comments:
Post a Comment