Posted By

onefastsnail on 05/24/12


Tagged


Versions (?)

files and folders


 / Published in: Other
 

  1. #copy folder and contents
  2. cp -rv /home/breo/public_html/admin/* /home/breo/public_html2/admin
  3.  
  4. #rename folder or file
  5. mv admin admin1
  6.  
  7. #ssh in
  8. ssh user@address
  9.  
  10. #sync files
  11. rsync -av /home/xile/public_html/pics/ /home/xile/public_html2/pics_old/
  12.  
  13. #get folder size in mb
  14. du -sm pics_old
  15.  
  16. #symbolic links
  17. ln -s /home/whatever/thesourcefile.html thenewlinkefile.php
  18.  
  19.  
  20. #find and show file line number with highlighitng
  21. grep --color=auto -iRnH 'website sale order' *.php
  22.  
  23.  
  24. cat find.item.comp3.php | grep --color=auto -inH '$path' > output.txt
  25.  
  26. #show file size
  27. du -h filename.txt

Report this snippet  

You need to login to post a comment.