Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio - is there a repeat last command command or shortcut?

This is a lark, as I'm pretty sure not, but just want to throw it out there, otherwise I can just use a macro.

like image 609
Steve Avatar asked Feb 08 '10 23:02

Steve


People also ask

How do you repeat the last command in VS code?

Re-run Last Command in Terminal Quickly repeat the last command in your terminal without leaving the text editor. By default this is bound to ctrl+f7 or cmd+f7 (mac). You can rebind this in the Keyboard Shorcuts Editor looking for the extension.

What does Ctrl d do in Visual Studio?

To solve this issue, we introduced Duplicate Code (Ctrl + D) in Visual Studio 2017 version 15.6 which streamlines the process of duplicating your code while leaving your clipboard untouched. If nothing is selected, Ctrl + D will duplicate the line the cursor is in and insert it right below the line in focus.

What does Ctrl F do in Visual Studio?

Find, Global Find & Find and Replace You've probably already discovered the search shortcut Ctrl-F, but did you know Visual Studio Code has different types of find features built-in? Ctrl + F as mentioned above this shortcut will find whatever you search for in the current file.


2 Answers

I think you might be able to achieve a result similar to what you're looking for by using temporary macros. Here are the steps to create and use a temporary macro...

  1. Press CTRL+SHIFT+R to begin recording a temporary macro.
  2. Perform the command or set of commands you wish to repeat.
  3. Press CTRL+SHIFT+R to stop recording the temporary macro.
  4. Press CTRL+SHIFT+P to execute the temporary macro. Repeat this step as many times as you want to repeat the command(s).
like image 169
carmbrester Avatar answered Sep 20 '22 21:09

carmbrester


No such command -- there are no different working modes in VS as in vi. Your macro will have to run all the time though. And you might get your editor dirty ;-)

like image 30
dirkgently Avatar answered Sep 21 '22 21:09

dirkgently