How to exclude wwwroot\lib in ASPNET Core using Visual Studio 2017 - tfs

Using VSTS (not git) and use Visual Studio 2017 libman to manage client-side libraries. These libraries are put in wwwroot\lib. I don't want to add these to source code control.
I've tried putting a .tfignore in my project folder with:
wwwroot\lib
I also tried:
\wwwroot\lib
Regardless of what I do, all the wwwroot\lib files are put in source code control when I add a new client-side library via libman.
How can I ignore the lib files since they are managed/restored by Visual Studio libman feature?

Based on the comment above from Seabizkit, **/wwwroot/lib worked for me.

Related

Removing Visual Basic project Templates from Visual Studio 2019?

Is there a way to remove the Visual Studio project templates from showing up in Visual Studio 2019? I'm never going to use them and I've had multiple occurences where I accidentially created a new Visual Basic project instead of a C# project.
I've tried removing the physical files from Common7\IDE\ProjectTemplates and clearing the cache but the project templates keep showing up in the dialog.
to remove a template from Visual Studio you may use:
dotnet new --uninstall NAMEOFTEMPLATE.Template
to uninstall some project types (Visual Basic maybe) try Change Visual Studio Tool from Setup...

VS 2017 Community support for custom CodeTemplates

I've been trying to get custom CodeTemplates working in VS2017 Community edition without much luck. I've copied the %Program Files%\Microsoft Visual Studio\2017\Community\Common7\IDE\Extensions\Microsoft\Web\Mvc\Scaffolding
files to CodeTemplates/ in my proj, tweaked the templates but I don't see any changes. I've customized the templates in prior vers of VS. Is it not supported in VS2017 Community Edition?
It works well in Visual Studio 2017. And yes that's the right folder you are looking at. You must copy the files as you did already and make sure to delete all the .vb.t4 if you are using c# as language from the CodeTemplates folder and vice-versa.
One more suggestion is to check and tweak the right template, since it has got withContext, withAction, Empty, etc...
EDIT :
Also when scaffolding, try to add -Verbose to the command, it'll tell you from where the templates are picked.
you can find it here:
C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\Extensions\Microsoft\Web\Mvc\Scaffolding\Templates\MvcView

Shared Project Reference not available for MVC Projects in Visual Studio 2015

I have just upgraded from Visual Studio 2013 to Visual Studio 2015 and I now cant add a shared project reference to a MVC project. I can add them to Console and Class Library projects and upgraded projects that use them still have the working references, but you can see to link to Shared project, using the Visual Studio 2015 UI (right click on reference).
I suppose I could manually add the reference I need in the .csproj file, but I am concerned that there is a wider reason that these project types do not seem to support shared project types.
Is there a specific reason for this omission or is it an oversight?

Can I create a Visual Studio project file from files on a server?

I have access to a working ASP.NET MVC 4 website through FTP but do not have the Visual Studio project file. Using these files can I create a Visual Studio project file?
If you have access to all the class files, views etc but are just missing the solution/project file then technically you can wrap them up in an empty project but it would still be a different project.
If you only have access to the published output (the views and JavaScript) then in short the answer is no, not without trying to reverse engineer the dll which I have heard is possible but have never tried myself.

How to make a project work both in VS 2010 and VS 2013?

There is an ongoing project that is based on ASP NET MVC 1 and used Visual studio 2010 IDE.
I'm newly joined this project. I want to use Visual studio 2013 IDE for this prject while other developers use 2010 IDE. According to my research to achieve this goal I made some modification on csproj file. Initial and changed lines are the following:
original line:
<ProjectTypeGuids>{F85E285D-A4E0-4152-9332-AB1D724D3325};{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
modified line
<ProjectTypeGuids>{E53F8FEA-EAE0-44A6-8774-FFD645390401};{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
According to above changes I successfully run it on VS2013. After I checked in new csproj file on TFS, other developers couldn't open project in their IDE VS2010 as expectedly. So in a correct manner, how can I change csproj to use both VS2010 and VS2013 IDEs?
As far as I know, this is not possible.
The only way would be to refrain from checking in the project file, but then it could become tricky if you have "legitimate" modifications to check in.
The general rule is to have a standardized development platform for developers on the same project. Otherwise you end up with this kind of problem.
So basically, either upgrade everyone to VS2013 or stick to VS2010.

Resources