How do I remove a folder from version control (but not delete it) using Intellij IDEA?

As this is a unusual use case, there is no direct way to do this. This is assuming the directory in question has indeed been committed and not just added. An added but not yet committed directory can be reverted/rollbacked.

A way you can do this within IDEA is as follows:

  1. Delete the directory
  2. Commit to VC
  3. In the Project view (or the Navigation Bar), open the context menu on the parent directory of the directory you just deleted and select Local History > Show History
  4. In the local history dialog, select the "Deleting" action (should be the top one) and click the Revert button.
  5. If you get an "Add files to {VCS Name}" dialog, just hit cancel
  6. Close the local history dialog.

Your directory has now been removed from VC but is back on your file system.

Edit:

If this is a common occurrence for you, you can record this in a macro (Edit > Macros). Use the left arrow to move to the parent directory for step 3. You can then map the macro to a shortcut in Settings > Keymap


If you only added the directory to SVN(without commit), just Revert it and it will be unversioned.

If you already committed the directory into SVN, in Intellij:

VCS > Browse VCS Repository > Browse Subversion Repository....

It will open the repo browser, then:

right click on folder you want to delete > Delete... > Commit