3350, 3480, 3600 classes
Lab-2a - Cleanup vim swap files on Odin server


1. Log on to your Odin account


2. Search for your vim swap files that can be deleted.

   find -name '.*.swp' 2>/dev/null


3. Delete the files listed that are not currently in use.

   If you are not currently editing a file with vi or vim,
   then none are in use.
   
   rm filename
   rm filename
   rm filename
   rm filename






------------------------ For advanced users only. ------------------------ 1. Use the find command to locate your swap files. find -name '.*.swp' 2. Now add a delete function to your find command... find -name '.*.swp' -execdir rm {} \; Your found files will be deleted. 3. Continue this strategy to find all swap files. find -name '.*.swo' find -name '.*.swn' find -name '.*.swm' find -name '.*.swl' find -name '.*.swk' find -name '.*.swj' find -name '.*.swi' find -name '.*.swh' find -name '.*.swg' find -name '.*.swf' find -name '.*.swe' find -name '.*.swd' find -name '.*.swc' find -name '.*.swb' find -name '.*.swa' find -name '.*.svz' find -name '.*.svy' find -name '.*.svx' find -name '.*.svw' find -name '.*.svv' find -name '.*.svu' ... Note: One of my students has made it all the way to .svw in swap files. This is from using vim incorrectly over and over again.