Quote:
Originally Posted by Grue
lol who uses a mouse to code
though there's always that feeling in the back of my mind like "there's some super super useful shortcuts/commands that I don't know that would make my workflow 1000x better but fml if I can find them".
I learned a pycharm thing after like 2 years of using it that blew my mind, and now I use it almost every day. You can search for something, and then click a button (or hit a hotkey) and start typing keystrokes. Those keystrokes will happen to *every matched block* simultaneously.
This is similar to, but not the same as, search and replace, because I can search for, for example
= "foo"
and then go to the beginning of a line and insert foo_
This would do the following:
a = "foo" ==> foo_a = "foo"
b = "foo" ==> foo_b = "foo"
and so forth. You often have to be *very* careful about what you search for and how you insert the keystrokes that you want applied, but it's doable.
You can do stuff like "search for this word and then for each match delete the line after it" (or insert a line or a word, or whatever)