Tuesday, February 10, 2015

Mercurial HG. How to delete files with orig extension

While you work with hg and do rebase, merge, hg saves original files. Some day your project will contain lots of rubbish files. Here is some multiplatform solution.
  1. Enable purge extension in mercurial.
    1. Open ~/.hgrc (Linux, Windows) or mercurial.ini  on Windows system.
    2. Add to extensions section purge plugin:
      [extensions] purge =
  2. In terminal select project folder and run next command:
    hg purge -I **/*.orig --all To test command without deleting files, add --print flag.

Eclipse. How to convert upper case text to lower case and vice versa

There are shortcuts to convert selected text to upper or lower case in Eclipse.
  • Upper case: CTRL + SHIFT + X
  • Lower case: CTRL + SHIFT + Y