Sunday, January 5, 2014

Published AttachToAny Extension

Download VS Extension

Fork on GitHub

 

This weekend I started looking at what it would take to get the AttachTo Visual Studio Extension to work with Visual Studio 2013. The AttachTo project hasn’t been updated in some time. I forked the project and pulled down the source. It wasn’t actually that hard to make it work. I just needed to update the manifest file and include 2013 as a supported version. But I had a problem. No matter what I did, I could not build AttachTo. It was created in 2012, not 2013, and I no longer have 2012 installed. Plus I wanted more from the extension. It only supports 3 processes to attach to; IIS, IISExpress, and NUnit. I wanted to be able to configure the extension to support any number of processes. So AttachToAny was born.

Now, there is a limit of 20 items that you can define to attach to. This limit may increase if there is a need. But the limitation is there because I wanted to be able to bind keyboard shortcuts to any of the Attach commands.

By default, there are 3 items defined. These are the 3 that ship with AttachTo. As you can see from the screenshot below, I bound IIS to the keyboard shortcut CTRL+SHIFT+ALT+A. You can also see that I added the ability to attach to the Chrome process.

ata-preview

 

Bringing up the Options Dialog shows you that there are 20 “Attachables”. Click on the “…” button to edit/configure the “Attachables”.

image

This brings up the “AttachDescriptor Collection Editor”.

image

Select an “Unused” slot and enter the name. This will be the menu item text.

image

Next, you can disable any  defined items by setting “Enabled” to “False”.

PrependAttachTo will put “Attach To” in front of the Name when displayed in the menu.

Finally, define the list of processes that should be used to determine what to attach to. You can click the dropdown for “Processes” and enter 1 item per-line, or you can type in each process, separating by a semi-colon.

image

Click “OK” –> “OK” to save the changes you made. Now if you open the “TOOLS” menu you will see the newly added item.

image

 


Release History

  • 1.0.4
    • Added a dialog for selecting which process to attach to. This is off by default.
    • Added option to use "best guess" when attaching, or open the dialog when there are multiple processes that match. "best guess" is the default, it is configurable per Attachable.
    • updated preview to reflect the submenu.
  • 1.0.3
    • fixed the issue with the changes not being persisted to storage.
  • 1.0.2
    • fixed the process name for IIS. It will not affect any of your configurations, it will only fix the incorrectly named "wp3.exe" process to "w3wp.exe".
  • 1.0.1
    • bug fix for items that are removed still showing in the menu
    • cleaner menu system. Items are now a submenu of Tools -> AttachToAny
  • 1.0
    • Initial release.


 

Download VS Extension

Fork on GitHub

Published AttachToAny Extension

Download VS Extension

Fork on GitHub

 

This weekend I started looking at what it would take to get the AttachTo Visual Studio Extension to work with Visual Studio 2013. The AttachTo project hasn’t been updated in some time. I forked the project and pulled down the source. It wasn’t actually that hard to make it work. I just needed to update the manifest file and include 2013 as a supported version. But I had a problem. No matter what I did, I could not build AttachTo. It was created in 2012, not 2013, and I no longer have 2012 installed. Plus I wanted more from the extension. It only supports 3 processes to attach to; IIS, IISExpress, and NUnit. I wanted to be able to configure the extension to support any number of processes. So AttachToAny was born.

Now, there is a limit of 20 items that you can define to attach to. This limit may increase if there is a need. But the limitation is there because I wanted to be able to bind keyboard shortcuts to any of the Attach commands.

By default, there are 3 items defined. These are the 3 that ship with AttachTo. As you can see from the screenshot below, I bound IIS to the keyboard shortcut CTRL+SHIFT+ALT+A. You can also see that I added the ability to attach to the Chrome process.

ata-preview

 

Bringing up the Options Dialog shows you that there are 20 “Attachables”. Click on the “…” button to edit/configure the “Attachables”.

image

This brings up the “AttachDescriptor Collection Editor”.

image

Select an “Unused” slot and enter the name. This will be the menu item text.

image

Next, you can disable any  defined items by setting “Enabled” to “False”.

PrependAttachTo will put “Attach To” in front of the Name when displayed in the menu.

Finally, define the list of processes that should be used to determine what to attach to. You can click the dropdown for “Processes” and enter 1 item per-line, or you can type in each process, separating by a semi-colon.

image

Click “OK” –> “OK” to save the changes you made. Now if you open the “TOOLS” menu you will see the newly added item.

image

 


Release History

  • 1.0.4
    • Added a dialog for selecting which process to attach to. This is off by default.
    • Added option to use "best guess" when attaching, or open the dialog when there are multiple processes that match. "best guess" is the default, it is configurable per Attachable.
    • updated preview to reflect the submenu.
  • 1.0.3
    • fixed the issue with the changes not being persisted to storage.
  • 1.0.2
    • fixed the process name for IIS. It will not affect any of your configurations, it will only fix the incorrectly named "wp3.exe" process to "w3wp.exe".
  • 1.0.1
    • bug fix for items that are removed still showing in the menu
    • cleaner menu system. Items are now a submenu of Tools -> AttachToAny
  • 1.0
    • Initial release.


 

Download VS Extension

Fork on GitHub