Can you create an Azure Functions from Visual Studio Mac? - azure

I don't see the option to create an Azure function class library template in new projects under Visual Studio Mac. If I created one manually - what files do I need to include and what framework target should I use for the library? .net core or .net standard or something custom?
Alternatively - if I use a CSX script file instead, how would I debug that on a mac?

Azure Functions support for Visual Studio for Mac is available in the alpha channel, so you need to switch to that in order to use this functionality.
The tooling there is similar to what is available for Visual Studio 2015, supporting CSX based projects (as opposed to pre-compiled, class library projects) and giving you a local run/debug experience.

In Visual Studio Mac 7.2 this feature was moved into an extension. Just open the extension manager - search for "functions" and you can install that feature again.

Related

Is there a way to publish an Azure Function from VS code using publish profile as we do in Visual studio?

I'm trying to publish a Node JS azure function from my VS Code. I have a publish profile file with all the credentials in it. How Can I instruct the VS code to use the publish profile?
I'm able to do it from the Visual studio for .Net function Apps. If its not possible from VS code , Is there a way to publish a node js azure function using publish profile from Visual studio?
This Publish Settings is only applies to Visual Studio IDE but not for VS Mac and VS Code as specified in this MS Doc of Azure Functions Publish Profile.
Visual Studio is mainly designed for .NET Core / Framework Project developments, but non-.NET Language can be compiled and debugged with the help of 3rd Party extensions in Visual Studio.
As it is mentioned in above MS Doc & Image, the Publish Profile for .NET Core/framework applications and can be accessible in Visual Studio IDE.

How to setup a modern js LIBRARY project in Visual Studio

I am looking at how to setup a modern js library project (npm + react + typescript + webpack, etc) with Visual Studios 2019. Note that I don't want this project to be executable (as all of the built-in project types appear to be...). What I want is for the build process to produce bundle(s) which will ultimately be uploaded to Azure Storage and deployed via Azure CDN. Right now I'm just focusing on how to setup the project so that it will produce a bundle(s).
Is there a built-in project type suited to this that I'm missing? Or do I need to use Visual Studio Codes for this type of work? Preferably I'd like to stick with Visual Studio 2019 rather than introduce another IDE if I can help it.
Thanks!

Is it possible to use the ServiceStack templates in Visual Studio 2017 or 2019?

Is it possible to use the ServiceStack templates in Visual Studio 2017 or 2019? I've seen the documentation reference VS Code. I'm able to run the projects in VS 2019. If there is a place ask ServiceStack, I haven't found it yet.
All ServiceStack Project Templates should work in Visual Studio, eventually all .NET Core projects will be upgraded to use .NET Core 3.1 LTS when it's released where you'll need to use VS 2019.
But most of the Single Page App Templates utilizes npm utils to provide web transformations and each SPA Framework has unique formats like Vue's SFC's, React JSX and .svelte templates which are poorly supported in Visual Studio, you'll have a much better development experience using either VS Code or JetBrains Rider with first-class support for these formats and much better Terminal integration to run watched npm utils.
If I needed to use Visual Studio I'd only use it for all back-end C# development whilst using VS Code for all front-end development and running built-in npm utils in its multi terminal window support.
Otherwise for non SPA project templates using Visual Studio should provide a good development experience.
If there is a place ask ServiceStack, I haven't found it yet.
If you're asking if there's a specific place to ask ServiceStack questions, you can use the ServiceStack Customer Forums.

What project type can reference .NET assemblies and can be referenced by an iOS Xamarin app

I'm looking for some help to setup my Visual Studio for Mac project properly. I'm new to Visual Studio Mac and would appreciate a shove down the right road.
I have a large class library, originally developed in visual studio 2017 on Windows.I'd like to use much of that code to develop an iOS application. This class library requires references to:
System
System.Runtime.Serialization
System.ServiceModel
System.ServiceModel.Web
System.Web.
I have tried porting that code to a Portable Class Library in Visual Studio for Mac. However PCLs don't allow you to reference the above assemblies (unless I'm missing something).
So I then ported it to .NET Library project (Other -> .NET -> Library) project. However, my iOS app won't allow references to that project type because VS for Mac says it has an "Incompatible Target Framework: .NETFramework, Version-v4.6.1).
What project type should I be using for this class library so that it can reference the needed .NET assemblies and it can be referenced from my iOS application?
Possible options:
Use a different Portable Class Library (PCL) profile.
Use a .NET Standard project.
Use a shared project.
For everything apart from System.Web, there are PCL profiles that have the assemblies you are looking for. You can see which assemblies are available on the Mac by looking in the PCL directory:
/Library/Frameworks/Mono.framework/Versions/Current/lib/mono/xbuild-frameworks/.NETPortable
If you open a terminal window there you can run a search, find . -name "System.ServiceModel.Web.dll", or browse the folders using Finder to find a PCL profile that has the assemblies you need.
Another possibility would be to use a .NET Standard 2.0 project which has a lot of assemblies that can be used and supports being referenced by a Xamarin.iOS project. You may need to install some other System.* NuGet packages to provide the required assemblies.
The namespaces available in .NET Standard 2.0 are documented:
https://learn.microsoft.com/en-us/dotnet/api/?view=netstandard-2.0
Another option is using a shared project. This does not have assembly references itself but is basically shared code that is compiled into all projects that reference it. Here you can use #ifdefs for any code that is iOS or Android specific.

Create a setup file in Visual Studio 2012

I have a windows form project and I want to create an installation package for this project. How can I create a setup file in Visual Studio 2012 ? My project is without data base.
How to create a Setup package using Visual Studio 2012.NET?
Microsoft released the Visual Studio Installer Project extension in April of this year, the catch is it's for VS2013, not VS2012.
http://blogs.msdn.com/b/visualstudio/archive/2014/04/17/visual-studio-installer-projects-extension.aspx
The 'lite' InstallShield option remains in VS if you need something with more flexibility.
Advanced Installer also has a free version that includes an extension for VS. This is a commercial tool but the extension is included in the free edition as I said, for more advanced features you need to purchase a Professional or higher licenses and edit the project direct from Advanced Installer GUI, not from VS. (but you can still use the project in the VS solution, so you get the MSI built at the end of your build process)
Visual Studio setup projects (vdproj) are not supplied with VS 2012
There are several solutions for you:
You could use InstallShield instead.
If you don't want or
can't use InstallShield for any reason, you could try WiX. This
toolset builds Windows installation packages from XML source code.
If you only use Windows Presentation Foundation (.xbap), Windows Forms (.exe), console application (.exe), or Office solution (.dll) you could look at ClickOnce. To use this you should right click on the project file in the solution explorer and select "Publish" from the pop-up menu.
Alternatively you can use previous version of Visual Studio (2010).

Resources