Visual Studio - Adding New Project Types

Posted on 2013-10-24
Medium Priority
Last Modified: 2013-10-31
If this has been asked elsewhere, please direct me.  When I search for solutions I get nothing but questions on automating Visual Studio builds or tasks with batch scripts.

I'm using VS2010 Pro and moving to VS2012 Pro.

We manage our web sites as VS Projects or web site.
We manage our batch VB code with VS Projects - but mostly just include items pertaining to the EXE and its execution.  We do not include the corresponding batch scripts to run the EXE since these are often shared with other EXEs.

We have a \Runtime suite of folders to manage our batch scripts and other control files.  We currently use a varity of editors including VS and even Notepad at times.  This is not as automated as we want because TFS points to our local drive and the Runtime code is not easy to code, test, deploy locally so it must be copied to server to test adequately.  What occurs is version issues because people get lazy and edit server version directly and TFS is not always updated.

Is there a way to add a new project type that I can point to Runtime and have it expect file types of CMD, SQL, TXT, VBS to automatically include and manage?

Ideally when we say "build" we would like all modified files to be copied to similar folder structure on our development server for real execution and testing.

This would facilitate our easily checking files in and out, maintain current code both locally and where it is actually tested properly on server.

I have built an External Tool batch script to copy files one by one as I edit & save them, but it is not quite as robust.

We cannot be the only ones wanting this capability.  I'm thinking I just haven't found the right search string.

Oh, adding color coding to batch files would just be a great bonus.  Most tools I've used manage it with a specially named file containg lists of reserved words, comment identifiers and color choices to use.
Question by:dsmrtn
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
LVL 96

Expert Comment

by:Bob Learned
ID: 39600211
Are you asking how to create a project template from an existing project?

How to: Create Project Templates

or, do you want an extension (VSIX) template?

Creating Extensions By Using the VSIX Project Template

Author Comment

ID: 39600965
You ask a good question.  I've given both links a look.  Each seems to suggest you either have an existing project to extend, or want to create a new project template starting with an existing templatev to export and edit.

I want a completely new Project Template - like Batch Scripts or Other Runtime Files.

I think I want the latter.  I want a project type that has nothing to do with VS languages - just flat files in support of VS EXEs - namely CMD, TXT, SQL. VBS for starters.  More often than not, changes to these files tend to be project agnostic - a global change for instance.

I just want to manage them outside of a VB Console project but using the features of VS like check in/out from TFS, making edits, and have this build process copy files from local folders to the expected target on development server.

I will try this out.  Thank you.
LVL 96

Expert Comment

by:Bob Learned
ID: 39601076
If you have TFS, there are the TFS Power Tools that add an extension to Windows Explorer, so that you can do TFS functions from Windows Explorer.  The Power Tools versions are specific to the Visual Studio IDE version.  Take a look at Windows Shell Extensions.

This is the installation for Visual Studio.NET 2012:

Microsoft Visual Studio Team Foundation Server 2012 Power Tools
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 22

Expert Comment

ID: 39601509
What exactly do you mean by "Manage?" I cant think of anything but to treat them as resources - since you are not going to write any DSL or language.

It looks like an awfully complex endeavor for a simple task of enforcing proper source code control. How would a new project type be any better at solving versioning than just a bunch of files checked into TFS?

Also, copying files to all deployments, should you really want an automated way for that, is also best handled by tools specifically designed for it.

I would suggest to look into using Nuget and Octopus deploy or TeamViewer for your tasks.

Maybe setup a Nuget repository server and push Nuget packages to it - using batch files - of course. Then you can either directly pull from Nuget repo or just have a specialized tool like Octopus deploy to push it to all deployments.


Author Comment

ID: 39601675
I just want to manage (TSF checkout/checkin, use of IDE to make changes, and when I click "build" - which is really a way of saying "do something with this extension/file type" - which means to build programs in a language that need to be compiled.  For CMD, TXT, SQL, VBS, that same "build" button should be able to do what it is told to do, that might be perform a syntax check, or copy to output destination, or run a batch script I might have written) the same way we manage everything else that is vanilla out of the box with VS.  Managing these types of files shouldn't be any different than say Web Sites, or C++ projects.  Files are Files - just out of the box VS doesn't support them as easily.

Just because some components are traditional "source code" to be managed doesn't make non source code any less important to be managed in a similar way.  The files I'm talking about, excepting TXT, are code - just not .Net code.

Sure I want these components to have the same, minimal controls our sourse code has, what is wrong with that?  It should be doable.  Heck they added F# as a project type.  And I could manually add the files by using the Add Exisiting Item feature, and I could add a post build script to do my copy to server deployments.  This might be the easiest way to go, but I was hoping for a more elegant, VS way, to do it.

Why isn't VS the best tool to do what I want?  I just want these flat file types to exist in their own project so they can be managed together because I have figured out that about 50% of the time a global or near global edit is involved - just exactly like we manage our various .Net code projects.
LVL 22

Accepted Solution

ambience earned 2000 total points
ID: 39601835
VS is not stopping you from writing a new project system, you can even write a powerfull Isolated Shell Application (IDE and your own Project Type).

However, that is a lot of work and must be justified.

If you really must: http://msdn.microsoft.com/en-us/library/cc512961.aspx

Isolated Shell: http://msdn.microsoft.com/en-us/library/vstudio/bb685514.aspx - More elegant ;)

Author Closing Comment

ID: 39615550
Hahaha.  Well, you warned.  Yes, this will do.  I will try doing more searches to see if these results were found and I skipped over them as not being what I'm looking for.

Hope I don't have to come back here and ask, okay, works on my machine, how do I deploy to myt teammates to erasily add to their VS.


Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
How many times a day do you open, acknowledge, or close an IT incident? What’s your process? Do you have a process depending on the incident, systems involved, and other factors? New Relic Alerts gives you options for how you interact with notifica…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question