在 mac 上学习 C#?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/431648/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-04 03:08:00  来源:igfitidea点击:

Learn C# on mac?

c#macos

提问by kal

Is mono the only route , any specific visual studio like editors that you recommend?

单声道是唯一的途径吗,您推荐的任何特定的视觉工作室,如编辑器?

采纳答案by Christopher Edwards

Without meaning to state the obvious and miss the point, if you mean a Mac computer rather than a Mac OS, you could install bootcampor use parallelsto run windows on the Mac and then use Visual Studio (there are also free versions of Visual Studio)

无意陈述明显和错过重点,如果您指的是 Mac 计算机而不是 Mac OS,您可以安装bootcamp或使用parallels在 Mac 上运行 Windows,然后使用 Visual Studio(也有免费版本的Visual Studio)

回答by James B

Mono is pretty much your only route right now, though there are incessant rumours (I wouldn't give much thought to them, though) that Microsoft is planning to port C# to Mac in the future. I'd be very surprised if that happened, though.

Mono 几乎是你现在唯一的途径,尽管有不断的谣言(不过我不会考虑太多)微软计划在未来将 C# 移植到 Mac。不过,如果发生这种情况,我会感到非常惊讶。

As for IDEs, I can't help there... If I want C#, I stick to Visual Studio (run it through Parallels or BootCamp, if you really want to use VS).

至于IDE,我无能为力......如果我想要C#,我坚持使用Visual Studio(如果你真的想使用VS,可以通过Parallels或BootCamp运行它)。

Edit:As Graham points out, there is Cocoa#, but I'd caution that simply because the project has stalled, and there's unlikely to be much future for it. :(

编辑:正如 Graham 所指出的,有 Cocoa#,但我会警告说,仅仅因为该项目已经停滞,并且它的未来不太可能。:(

回答by BobbyShaftoe

Yeah, mono is really your only option, unless some undergrad somewhere has developed some very experimental thing I don't know about. As for an IDE, well I believe the only thing half way stable that will work right now on Mac OS X is Monodevelop:

是的,单声道确实是您唯一的选择,除非某个地方的某个本科生开发了一些我不知道的非常实验性的东西。至于 IDE,我相信现在唯一能在 Mac OS X 上运行稳定的东西是 Monodevelop:

http://tirania.org/blog/archive/2008/Feb-07-2.html

http://tirania.org/blog/archive/2008/Feb-07-2.html

I mean, you could run Parallels and develop your code on a Windows VM with Visual Studio and as long as you follow certain guidelines about portability, you could use VS to develop your mono apps. Although, you probably might as well get familiar with Monodevelop. It would be interesting to see if SharpDevelop ever gets ported.

我的意思是,您可以使用 Visual Studio 在 Windows VM 上运行 Parallels 并开发您的代码,只要您遵循有关可移植性的某些准则,您就可以使用 VS 来开发您的单声道应用程序。虽然,您可能还不如熟悉 Monodevelop。看看 SharpDevelop 是否被移植过会很有趣。

回答by Tamas Czinege

Well, you could also try Silverlight...

好吧,你也可以试试Silverlight...

Pro:

亲:

  • It is an official Microsoft implementation, so it is more likely to work
  • Its support for recent stuff like C# 3.0 is much better
  • 它是微软的官方实现,所以它更有可能工作
  • 它对 C# 3.0 等最近的东西的支持要好得多

Con:

骗局:

  • It is browser-only, Silverlight apps do not run standalone
  • You won't get the whole .NET Class Library, only a subset, so it is somewhat limited
  • You won't get Visual Studio on a Mac
  • 它仅限浏览器,Silverlight 应用程序不能独立运行
  • 你不会得到整个 .NET 类库,只有一个子集,所以它有点有限
  • 你不会在 Mac 上获得 Visual Studio

For IDE, I suggest Eclipse Tools for Microsoft Silverlight(apparently it is Windows-only at the moment) you should use MonoDevelop or SharpDevelop or something like that.

对于 IDE,我建议使用Eclipse Tools for Microsoft Silverlight(显然目前仅适用于 Windows),您应该使用 MonoDevelop 或 SharpDevelop 或类似的工具。

回答by Marc Charbonneau

I would go the virtualization route, either Parallels or VMware Fusion. Both will run Windows XP and Visual Studio very well on a modern Mac. Windows has the best tools for .NET and C# development and it only makes to use them, especially when you're just starting out.

我会走虚拟化路线,Parallels 或 VMware Fusion。两者都可以在现代 Mac 上很好地运行 Windows XP 和 Visual Studio。Windows 拥有用于 .NET 和 C# 开发的最佳工具,它只会使用它们,尤其是当您刚刚开始时。

回答by jonathan

Virtual Box is my new favorite and open source (means free) VM software. Don't pay for Parallels. Also, with BootCamp, you have to reboot the machine to switch between Windows and OS X, so Virtual Box is the way to go.

Virtual Box 是我最喜欢的开源(意味着免费)VM 软件。不要为 Parallels 付费。此外,使用 BootCamp,您必须重新启动机器才能在 Windows 和 OS X 之间切换,因此 Virtual Box 是可行的方法。

回答by exitcode

Use Xamarin Studio IDE. https://xamarin.com/mac

使用 Xamarin Studio IDE。 https://xamarin.com/mac

Uses Mono and C#. It has any features you might expect from a modern IDE and combines with XCode for GUI.

使用 Mono 和 C#。它具有您可能期望从现代 IDE 中获得的任何功能,并与用于 GUI 的 XCode 相结合。