How do I skip a match when using Ctrl+D for multiple selections in Sublime Text 2?

Just_Mad picture Just_Mad · Jul 18, 2012 · Viewed 43.1k times · Source

I have some code like:

testVar = { a: 1 };
testVariable1 = 2;
var c = testVar.a + testVariable2;
var d = testVar;

I want to rename "testVar" variable. When I set multiple cursors with Ctrl+D and edit variable, "testVariable" is also selected and edited.

Is there a way to skip some selections while setting multiple cursors with Ctrl+D?

Answer

Romain picture Romain · Jul 18, 2012

Just use Ctrl+K, Ctrl+D.

(for OS X: Cmd+K, Cmd+D)

Needs a bit of practice, but gets the job done!