Skip to content

Instantly share code, notes, and snippets.

@mbriggs
Created September 11, 2012 17:45
Show Gist options
  • Select an option

  • Save mbriggs/3700193 to your computer and use it in GitHub Desktop.

Select an option

Save mbriggs/3700193 to your computer and use it in GitHub Desktop.
# given this code
def foo
a = 1
b = 2
unless false
a = 2
b = 3
end
end
# if the cursor is inside the method but outside of the unless
# when I invoke the command, the whole method body gets selected
def foo
# a = 1
# b = 2
#
# unless false
# a = 2
# b = 3
# end
end
# if the cursor is inside the unless
# when I invoke the command, only the inside of the unless is selected
def foo
a = 1
b = 2
if false
# a = 2
# b = 3
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment