Publishing Just Your JavaScript Folder With Visual Studio

image.png

Who would have guessed.  With Visual Studio you can right click on any folder in your web project and say publish.  You can see me doing that right here below. For years, I’ve struggled with how to just get certain files to an IIS web site.  The things that I have used (that all have issues) are: Robocopy (only works if you can have a vpn network drive) rsync (causes permissions problems and various other nasties) ftp (has trouble syncing and the root folder is never where you want it Now, I can skip all that assuming I’m using visual studio (which I usually am). I get the nice success window quickly as follows And that is all there is to it. … Continue Reading

Name Collisions with Asp.Net Webapi and How to Avoid

I love the simplicity of using ASP.NET WebAPI for building simple web rest services.  No special calls to create JSON, simple REST conventions implemented with the methods GET,POST,PUT and DELETE and very straight forward interfaces. The thing that annoys me is the naming convention.  In my case, I’ve create a folder /rest on my web server and I put all my WebAPI controllers there.  An example of a controller looks as follows: [crayon-55c0129d45323824778571/]   The problems comes up when you decide you want to have a different FAQ controller for different parts of the web site.  The obvious solution is to drop the REST services into sub directories.  Unfortunately, since the class name above does not … Continue Reading

Visual Studio 2015 Nasty Scroll Problem

It just happened to me again.  I accidentally moved a file in my Visual Studio solution that I had not intention of moving.  I think I’ve narrowed down what my user error is that causes this but still, I know this happens to a lot of people besides me so I thought I’d file a connect bug with the hopes that Microsoft fixes it. Here is the URL of the connect bug.  Please go and vote for it! https://connect.microsoft.com/VisualStudio/feedback/details/1110209 Here is what I actually posted: I'm labeling this as a bug because it happens so often and often with large consequences.  Today, I finally spend some time and nailed down what actually causes it. Here is the scenario: 1.  Go to scroll bar of Solution … Continue Reading

Tuples In C#, A Useful Example

Background Last year I worked consulted with a company that had an engineer that used tuples in C# and tried to explain to me how they were useful.  To be honest, I never quite saw the value proposition (until today).  I remember he kept saying they were kind of like key value pairs but could go beyond that.  I remember those words but never internalized that. The Example My example is a simple one.  I’m currently working on providing data to an external application that will provide business intelligence (help with session selection) to the Silicon Valley Code Camp web site.  The data I’m providing is every mark of interest and plan to attend for every session ever given at code camp (that’s 220,000 … Continue Reading

Follow

Get every new post delivered to your Inbox

Join other followers: