Coping with Linux

From Intelligent Materials and Systems Lab

Revision as of 22:44, 2 March 2013 by Siims (talk | contribs) (Created page with "Useful commands: <ul> <li>Remove a file: $ rm</li> <li>Remove a directory: $ rm -r</li> <li>Find files and delete them: $ find / -iname file/name/with/regexp -exec rm -f {} \;...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Useful commands:

  • Remove a file: $ rm
  • Remove a directory: $ rm -r
  • Find files and delete them: $ find / -iname file/name/with/regexp -exec rm -f {} \;
  • Find directories and delete them: $ find / -name file/name/with/regexp -exec rm -r -f {} \;
  • To find some folder/file names: locate somename
  • When using many terminal windows and when changing some database info, it is useful to "import" changes to other windows: $ sudo updatedb
  • Change file privileges: $ chmod 644 (other nr can be looked up from wiki)