20 ms·
.NET on Linux – bye, Windows 10
- silicon123 10y agoif there would be WPF support on linux it sure would be a competitor but if you are stuck with desktop applications I'm afraid, it's still Win
- philliphaydon 10y agohttps://github.com/AvaloniaUI/Avalonia https://github.com/AvaloniaUI/Avalonia Checkout this project for making WPF cross platform.
- zastrowm 10y agoTo clarify, this is a cross-platform UI library in the style of WPF; it does not actually make WPF cross-platform.
- philliphaydon 10y agoYes, was typing on my phone so was trying to keep my message short :)
- shoover 10y agoXamarin.Forms is looking pretty good but still mobile (and Windows 10 UWP) at the moment. Will they extend to OS X and Linux?
- flukus 10y agoI still have to wait for sql server to be ported. But my day job as a c# dev is the only thing keeping me on windows at the moment.
- spetz 10y agoGood point, however, you could always try to run the SQL Server remotely or on VM for the development purposes.
- matthewking 10y agoI've considered a Sql Azure instance for this purpose, for a small dev database its pretty cheap. Not ideal but Sql Server for linux is coming so might be ok as a stop gap.
- flukus 10y agoYeah, I think I'd go the container/VM route so I could also only spin it up when needed (a fraction of the time).
- biehl 10y agohttps://www.microsoft.com/en-us/cloud-platform/sql-server-on-linux https://www.microsoft.com/en-us/cloud-platform/sql-server-on...
- laumars 10y agoThat's what he's referring to. It's not available yet.
- romanovcode 10y agoYou could use MySQL? It has full EF7 support AFAIK.
- ewfffe 10y agoAfter years MySQL still not implemented async for their .NET driver, only slow cheap wrappers. However, PostgreSQL has full async support in their free .NET driver...
- romanovcode 10y agoYeah, however no EF LINQ support, correct? So you'd have to write all the queries manually.
- Grazester 10y agoI have used Mysql with Entity Framework and LINQ just fine edit://oh you were asking in regards to postgre
- bgrainger 10y agoI've developed a fully async, independent, MIT-licensed MySQL ADO.NET provider for .NET and .NET Core: https://github.com/mysql-net/MySqlConnector https://github.com/mysql-net/MySqlConnector
- kierenj 10y agoI've been spending some time putting together a framework for .NET Core API/platform development. The main problem with it currently is the lack of compatible libraries - I've had issues with DI containers, cloud provider libraries, AOP frameworks and more. Not to mention EF Core is still way off in terms of production viability. ASP.NET Core is very tasty as a plus.. and there's always Mono to fill the gap in terms of "full framework" missing functionality.
- taspeotis 10y agoI've discovered Autofac has good support for CoreCLR. Plus it's well designed and powerful.
- alimbada 10y agoI can attest to how well designed Autofac is. I had to decide on which DI framework to use on a small front end WPF application that I worked on at a job last year (the app had a lot of singleton classes that were impossible to unit test hence why I needed to introduce a DI framework). I'd come from a job where larger framework choices had been made years prior by senior developers and their framework of choice at the time was Microsoft's Unity so that was what I had worked with for ~5 years. After a week or so of research and deliberation I decided to go with Autofac and found it to be really easy to set up and use. For me it hit the sweet spot between built in functionality and performance.
- xorxornop 10y agoAnd I, too! After discovering Autofac, I've not looked back. Before, I'd tried various DI frameworks, and always left thinking "I totally do not get what why people like this DI stuff". Then, Autofac. Everything just works. But - it's also powerful enough that if I need to do something really clever and/or complex, I can, and it invariably works. It works just as well in Core. As such, it's usually the first package I install in a new Core project.
- 10y ago
- tychuz 10y agoWell, domain name made me think about this old sketch: https://www.youtube.com/watch?v=GlOoSsfU6cM https://www.youtube.com/watch?v=GlOoSsfU6cM
- aargh_aargh 10y agoCan I have Paint.NET on Linux yet?
- romanovcode 10y agoNo, classic form stuff is not supported. There are only some open-source libraries but they are very new.
- creshal 10y agoDepends on the GUI framework it uses. GDI actually exists for Linux (at least for Mono), but it's not really something you want to use in production. Windows Forms doesn't exist (yet). IIRC that's what paint.net uses, so you're out of luck. Third party toolkits like GTK#, wx.NET or QtSharp will work on both OSes.
- ygra 10y agoI remember that ages ago the Mono team used Paint.NET as a testbed for how complete and usable their System.Windows.Forms and System.Windows.Drawing implementation was. But back then Paint.NET was still open source. By now the source code isn't available anymore and it has grown a lot of things that are implemented in native code for performance (set operations on selection regions) or talking to things that have no equivalent in .NET (DirectWrite). It also uses WPF for a few things, so isn't completely Windows Forms anymore either. As it currently stands, Paint.NET is very much a Windows program, despite being written mostly in C#.
- egeozcan 10y agoOh I didn't know that Paint.NET closed source. I found a blog post about the decision, an interesting read. Here it is: https://blog.getpaint.net/2007/12/04/freeware-authors-beware-of-%E2%80%9Cbackspaceware%E2%80%9D/ https://blog.getpaint.net/2007/12/04/freeware-authors-beware...
- Tharre 10y ago
- UK-AL 10y agoI tried this for a months, but eventually moved back.
- romanovcode 10y agoWas it because .NET was causing problems for you on Linux or because of lack of Visual Studio?
- UK-AL 10y agoBecause the vast majority of the ecosystem isn't .net core ready. So you end quite major libraries not being available.
- matthewking 10y agoI'm on my third of fourth attempt, this time it seems to have stuck, although I'm working from macOS. Every other time there was something crippling with dotnet core but so far so good this go, the only thing I've noticed is omnisharp / vscode error highlighting has started becoming a little laggy / incorrect since my project has grown, hoping I can continue though as VS.NET is the only reason I ever use windows at all.
- pweissbrod 10y ago+1 Assuming you've ported all of your windows tools to linux desktop... Once you start work on a regular cadence I wager you'll find all those windows hassles are traded for bevy of new ones with linux desktop. My current work jumps between .net and linux frequently. I've been lured by the notion of all work on a single OS. It is certainly possible. And I take a shot at it every 6 months or so. So far it still brings more hassle than practical benefit for me. Tools make all the difference in efficiency. And if youre short on time and working on C#/SqlServer/F# then nothing currently gets the job done faster than the older/boring tech (for me that's visualstudio/vsvim/resharper on windows 7). But I agree that SqlServer on linux + project rider may be enough to make practical cross-platform environment for my needs. This is a great conversation and worth checking in on every few months
- rocky1138 10y ago
- jdking 10y agoLooks like a sensible option for .Net Core development. VSCode and the command line tooling look to be pretty decent. I would really miss LINQPad though.
- rat87 10y agoI think Project Rider is probably going to be better then just VSCode.
- egeozcan 10y agoThe amount of time I've invested in LINQPad scripts means I'm going to keep dual-booting Windows in the foreseeable future.
- Rudism 10y agoThe csharp REPL is actually a fairly decent substitute for LinqPad. It can pull in 3rd party libraries, has autocomplete, and is all around quite nice to use. You don't get the automatically generated ORM against your database, but if you mostly use it to test code snippets or as a shell scripting substitute, you might be surprised by how little you miss it. When we migrated all of our .NET development to Linux where I work, I thought I'd have to at least keep a Windows VM around so I could continue using LinqPad, but the csharp REPL has pretty much sufficed for everything I do on a regular basis.
- IshKebab 10y ago> Before I did manage to install a fresh system on my laptop I had to disable UEFI, create valid partitions with special flags etc. it took me a while to figure this out, yet it wasn’t that difficult. Ha, right here is why "the year of the Linux desktop" will never happen. It's basically a kit car. Some people may find it "not that difficult" to weld a chassis together and rebuild an engine, but it's never going to be mainstream.
- creshal 10y agoI wonder what he fucked up to make this necessary. Modern Linux distributions work fine with UEFI and create the necessary EFI System Partition itself.
- jhasse 10y agoUnfortunately not on every UEFI implementation ...
- laumars 10y agoHis UEFI might have "secure boot" locked. I've heard that's an issue with some laptops. Obligatory Wikipedia reference: https://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Interface#Secure_boot_2 https://en.wikipedia.org/wiki/Unified_Extensible_Firmware_In...
- creshal 10y agoAll major distributions ship with shim enabled IIRC, so should work with Secure Boot.
- MertsA 10y agoDoesn't matter. Secure boot just requires that the bootloader is signed with an approved key. Most major distros already have this down as Microsoft will happily sign any bootloader that isn't a glaring hole for a small sum of money.
- yaur 10y agoUEFI support is relatively new for Linux and there are still a bunch of guides floating around that tell you to disable it, more than likely he followed one of those but didn't really need to disable it.
- deleted 10y ago[deleted]
- scandox 10y agoThe real story here is the forced updates. How do people who are planning demos and presentations handle this? It's my worst nightmare.
- wubbfindel 10y agoIf your using Windows 10 Professional or above, you can change the Local Group Policy to prompt you for both downloading and installing updates. For lower versions (like "Home"), there is a way to tell it that your connection is "Metered" and then updated won't be downloaded automatically; but that's not an official method to prevent updates.
- pritambaral 10y agoFor public information: Wired connections cannot be set as "metered". Only wireless ones.
- wubbfindel 10y agoI didn't realise that, thanks.
- verbify 10y agoAlso for public information: There are hacks that allow wired connections to be set as metered: http://www.windowscentral.com/how-set-ethernet-connection-metered-windows-10 http://www.windowscentral.com/how-set-ethernet-connection-me...
- croon 10y agoGroup policy editor. You can configure it to not update while anyone is logged in, only manual, at a set time, etc. It's just not in any of the "usual" settings menues. Likely rationalized by average users not disabling security updates by accident or something.
- geostyx 10y agoI love that group policy! It will still force a restart about every 9 days with that enabled, but it's much better than daily restarts.
- elorant 10y agoWindows 10 is a clusterfuck of an OS. Installed it on my dad’s PC, a simple machine with browsing software and a few arcade games. Didn’t go with the full install, instead did an upgrade from Win7. Everything was honky dory until it downloaded a ginormous 1GB update. The update failed and now every time he shuts down the update tries to install again. It takes north of five minutes to shut down. Install, fail, rollback, then shutdown. Every single time. I even tried to install the update manually but failed again. I don’t have time for this shit. I’ll give them a couple of years to polish .NET on Linux and then I’m off Windows. I love C#, VS and everything Microsoft produces on the developer front but the OS is fucking toxic.
- douche 10y agoTrying to upgrade an operating system is almost always a good way to ensure you're going to have a bad time. Copy any files you care about off, wipe the disk, and install from scratch. This is also usually worth doing with an OEM machine, to get rid of all the crap and weirdly configured partitions they set them up with.
- pwelch 10y agoI agree but I'm mildly surprised when an upgrading OSX or Linux instead of a fresh install always works fine.
- rubber_duck 10y agoThat's not true for Linux - I've had many instances where repo refs broke because they didn't have packages for updated version, or where the new version kernel introduced a bug breaking my WiFi, audio, graphics, or random stuff failing - it's probably worse than doing a Windows upgrade. I've only used macs for a year and only did 10.5 -> 10.6 which went smooth IIRC. Mac approach of owning the hardware and the OS certainly has it's advantage - being able to clone image to an external HDD from my MB pro and then boot a iMac to the exact same image is a magical experience. Setting up a master image on my laptop and then redeploying to an office of 40 something various mac devices using IP broadcast and doing it in an hour - hearing that apple chime 40 times was really cool :D
- draw_down 10y agoI'm not a huge fan of Linux as an everyday desktop OS, but god, Windows is so awful. It's nice to know the .NET ecosystem is so different from what it was like back when I used to work in C#, and was pretty much forced to use Windows for that reason.
- rafaelvasco 10y agoIf it's a pure dev machine than it's already feasible, but not perfect yet. If it's an all purpose machine , ie. gaming, dev, sound vsts etc. Than no. Mainly because of the gaming side unfortunately. I hope Vulkan starts to change that. Btw.: I'm intrigued about the forced updates. Never had them. Computer only updates when i want. Maybe i changed some config when installing the OS.
- V-2 10y agoBack in the Windows XP days, there was a way of halting forced updates by killing a certain process. I had it as a simple batch file on my desktop. Every time it would come up with "your PC gets restarted in 15 minutes", I'd just double click on it and carry on undisturbed.
- jasonkostempski 10y agoWas that really necessary? As far as I remember, XP let you choose to not install updates automatically.
- V-2 10y agoI can't really argue because it was a while ago, but if I recall some of them were considered critical and you could postpone them time and time again, but not really disable them Plus I wasn't really opposed to safety updates as such, and wouldn't want to take the burden of remembering about them upon myself - it's just the arrogant, disruptive manner in which they are delivered that never sat well with me (if with anybody...)
- nikon 10y agoI'm in a similar boat but using Project Rider on OSX. It generally works without issue but is far from ready for general use. How does VSCode deal with things like running unit tests?
- trydis 10y agoI'm sure you can create tasks for running commands like: dotnet test (https://docs.microsoft.com/en-us/dotnet/articles/core/tools/dotnet-test https://docs.microsoft.com/en-us/dotnet/articles/core/tools/...) dotnet watch test (https://github.com/aspnet/DotNetTools/tree/dev/src/Microsoft.DotNet.Watcher.Tools https://github.com/aspnet/DotNetTools/tree/dev/src/Microsoft...)
- jorgeleo 10y ago"Although the application did run correctly, it threw an exception that gdiplus.dll could not be found. It makes sense, that’s a Windows component so it’s not available on Linux. But my point here is that although being the .NET Core application it’d still crash, so imagine what would happen if I’d publish it to some Linux server – everything would seem to work, but actually it wouldn’t. Another point for the .NET Core development on the Linux instead of Windows." I am baffled... so silent crashes and the illusion of working is a plus... really? I hope I am missing something
- tobz 10y agoIt seems like he was happy that he was developing on Linux, because Linux is not the happy case for .NET. By doing so, he discovered a bug he might not have otherwise discovered until he was running his project on a Linux environment.
- dsp1234 10y agoLinux is the default environment for the official .net core docker images. You can see this on Microsoft's official docker page[0]. For non-linux builds, you have to specifically ask for the nanoserver images. ex: microsoft/dotnet:latest is a debian based image[1] microsoft/dotnet:core is a debian based image[2] [0] - https://hub.docker.com/r/microsoft/dotnet/ https://hub.docker.com/r/microsoft/dotnet/ [1] - https://github.com/dotnet/dotnet-docker/blob/master/1.0.0-preview2/debian/Dockerfile https://github.com/dotnet/dotnet-docker/blob/master/1.0.0-pr... [2] - https://github.com/dotnet/dotnet-docker/blob/master/1.0/debian/core/Dockerfile https://github.com/dotnet/dotnet-docker/blob/master/1.0/debi...
- tobz 10y agoSure, for .NET Core, that sounds accurate. If you take the .NET ecosystem as a whole: the CLR, the tooling, the libraries, etc.. Windows is the happiest case. That's at least how I take his specific point.
- Vendan 10y agoI think the point is "develop on the platform you are going to use". You'd get that error when you were developing on linux, so it'd never make it to production. If you developed on windows, you'd never get the error, cause you have gdiplus.dll. Still you should be at least testing on something matching the target platform, but catching this kind of stuff early is a plus!
- oogigogigok 10y agoonly me who find it amusing how windows devs are LOVING bash now, while most linux/mac devs who cares run zsh, fish or anything better than ... bash! cant wait to see the next gen of sloppy shell scripts, yay
- ygra 10y agoWell, you're free to use zsh, fish, or anything better on WSL as well.
- WayneBro 10y agoSo, instead of taking 30 seconds to disable automatic Windows Updates, this person decided to have a hissy fit and throw the baby out with the bath water. The instructions are pretty simple. You have to toggle one setting. Done -http://www.tenforums.com/tutorials/8013-windows-update-automatic-updates-enable-disable-windows-10-a.html#option1 http://www.tenforums.com/tutorials/8013-windows-update-autom...
- runjake 10y agoThis works well for the those rare people with the luxury over control of those settings in their workplace. I actually like the Automatic Update feature. I don't need to remember to run updates myself all the time. That said, I've been bitten by an hour-long unusable computer scenario and it's been a bummer, to say the least.
- WayneBro 10y ago> ...rare people with the luxury over control of those settings in their workplace. Would you kindly provide a citation for that statement? I've been programming on Windows for twenty years in various corporations - never had a problem getting Admin rights on my own machine... I'm now a consultant and I visit many, many, many job sites - and I just don't see it being a problem. Furthermore - Linux wouldn't solve the problem for those rare people who can't control their settings anyway. So, what's your point?
- king_magic 10y agoIt's a huge problem in more restricted environments - e.g., investment banks. Admin access can be very hard to come by.
- WayneBro 10y agoOK whether it's a problem or not is definitely up for debate. The bigger point here is that switching to Linux would not help those people either.
- cozuya 10y agoHere's my anecdata after recently attempting to move permanently from Windows to Linux Mint: * No logitech mouse support = severely disabled experience. I can't use any of the extra mouse buttons in the way I want on my Performance MX. And yes I did spend several hours trying to get it to work but it seems that the button mapping works only for keyboard commands and even that I couldn't make work. And never could make the mouse wheel move at what I consider to be fast enough. Very frustrating. * While it supposedly exists, I could not make f.lux work. This essentially prevents me from using my computer at all at night. * The ridiculous amount of times I have to type in my password (and use sudo) is really user unfriendly. Yes I'm sure there's way to disable this or even use root but the average non developer user is going to be hugely turned off by this. * Node is really, really good on Mint. A full stack MERN/gulp application took 10 seconds(!) to yarn. On windows it would take 2-3 minutes. And chrome just seems much faster for dev. While working on a multiplayer game with 5 windows open (MultiLogin) all of which are connected to livereload, it is about twice as fast for reloads vs windows and a bit faster than macos/macbook pro. Gulp itself takes about 20 seconds to start up on windows the first time is instant here. So in the end there's just no way I'm going to use Mint for every day use i.e. websurfing and of course gaming. I'll switch to it when I want to do serious heads-down dev.. maybe. To be honest the fact that its a bit faster for node probably won't be a good enough incentive to go through the hassle of setting up a dual boot.
- libeclipse 10y agoI use Arch Linux and I haven't faced any of the problems you mention. I don't game so this might be slightly skewed, but there's not a single thing on Windows that would tempt me into using it. Also the sudo point I completely disagree with. It comes down to security or convenience, and it's a damned shame that people pick convenience.
- Skunkleton 10y agoFurther, if you are doing a bunch of administrative tasks from the CLI, sudo will keep you authenticated. If you really want, you could even open up a root shell. I think the real problem is that the Right Way(tm) to do things is completely non obvious to a linux novice. Looking back on my times starting out with linux (ubuntu 6.06), I remember a lot of similar frustrations. Really, there is no middle ground, you are either a novice or an expert, and bridging that gap is super challenging. The only real useful advice I ever received was to 1) learn the CLI, and don't assume that it is antiquated, 2) use linux for real tasks, don't just follow tutorials, and 3) If something isn't working the way you want it to, there is probably a way to change it. Hopefully the author will use his frustrations as a learning experience, rather than a reason to leave the platform. The linux community could use more people like him.
- deleted 10y ago[deleted]
- Koldark 10y agoI have never seen this behavior. It gives me the option to reboot on "off hours"
- tmzt 10y agoSo I've spent some time trying to get an existing asp.net 4.5/4.6 application to work on Windows Containers using docker, running under Linux in a VM. It turns out that System.Web only works under microsoft/windowsservercore based container which will only run on a Server Core, Server 2016, or current Windows 10 Professional. I'm wondering why a Nano Server plus additional libraries could not host a complete asp.net 4.6 runtime, possibly leaving out components that need the GDI.