Windows and Linux co-development

Oh right, remove-item alias:iex -Force is in my profile.

I only use msys2 to compile things using mingw-w64. Using pacman to fetch dependencies is super nice too.

MinGW is in Chocolatey.

1 Like

You canā€™t have VirtualBox or an Android Emulator or any other VM anymore thats not from MS when Hyper-V is activated.

I think youā€™re right. Iā€™m not that windows proficient and what I did before was solutions I found after many hours of googlingā€¦ But bash is nice and it both feel better to use than whichever terminal native to windows I tried and elixir seems simpler, just better off in it. Terminals in windows is just not up to par, and do you know that powershell aliases popular programs with itā€™s own functionality? curl is my only example, does not behave the same and to my knowledge you cannot override itā€¦ how could I trust it?
I guess the elixir/erlang-core developers could work around these issues though, seems to be a lot smoother when facing similar things in nodejs on Win.

Hate is of course harsh words, sorryā€¦ I just donā€™t like Hyper-V and itā€™s primarily because of my lack of knowledge about it. Iā€™ve had issues regarding specifically docker usage and then the fact about not being able to use other virtualization software when itā€™s activated. I already spend too much time on things like this to learn it betterā€¦ Docker was fine when it just used VirtualBox which Iā€™ve been using for a long time on Win, Mac and Linux and I personally have multiple Dev env-setups using it

These are just my experiences, not the single truth so if you know windows better than me generally, you might not reach the same conclusions :grin:

As I mentioned quite a few times now (also in this Thread), docker still can use VBox on windows, just use Docker Toolbox instead of Docker for Windows.

I know, Toolbox isnā€™t advertised anymore, but at least they said that they want to update it until an unknown point in time.

2 Likes

Thanks, I have totally missed your posts regarding docker!
Iā€™ll definitly try it out, guess if Iā€™ve even seen Toolbox around lately I might have supposed it being deprecated.

It actually is :wink: But because of the known Hyper-V problems, they promised to update at least the docker running in the virtual box for quite a longer time. The toolbox itself wonā€™t get any updates though. Which I find a bit pitty, I really love the GUI (kitematic), it makes accessing logs so easy.

I canā€™t find the deprecation announcement, nor the promise to update right now. The repository seems to be staled and only bumping versions of docker.

1 Like

Not that, I mean the linux wayland session, it never displays in the hypervisor window, it is just black. Already have the Hyper-V Manager, that is how I set it all up.

It was just an example of the network communication I use. In reality I have a whole set of linux tools that I use for diagnosing, practically none of which actually work because the IP stack is missing capabilities.

Yeah but my tools that Iā€™ve built up over 20 years do not work in it. :wink:

which works fine on Windows here, but then again I have the entire gnu toolset installed in Windows. ^.^

Iā€™ve tried a few, but for a quickstart try KDE Neon. If you can figure it out then Iā€™d love to start showing off KDE here (these are Windows users do remember, want something familiarā€™ish).

Sadly these are Dell managed things and the desktop IT is a different department (I work in server IT here), so not a chanceā€¦

What editor does not auto-detect what line endings a file already uses?! o.O?

NTFS sucks in general.

Chocolatey is awesome for Windows, not as good as a package manager, and Windows needs to reboot a lot (wtf, another NTFS stupidity, I never reboot my desktop, it has uptime measured in months on average and itā€™s reached years a few times).

Uhh, not to me, not even remotelyā€¦ Plus I need to compile stuff to run on a Windows 2008 server that does not have WSL, thus compiling inside WSL I do not think will work well for that. :wink:

That is because your shell did not lock the directory you were in (which I prefer it not locking it). Linux can also throw errors when you move something that is in use, it just has to actually be in use of course (and most shells release their lock as soon as they are done scanning, oh, files when using ls or so). So I do not see what is worse about this. Perhaps that you can have a program reading and one writing a file at the same time, oh wait that is not worse either (take a real-time log output from a web server and also parse it at the same time, Windows is not capable of that unless the web server releases control and re-opens the file constantly or you feed it to some intermediary first). There is nothing about NTFS that is superior to, say, ZFS (which I use). :wink:

That is such a wtf, why would powershell override such a basic command when an existing one exists on the path, like wtfā€¦

Precisely this, I learned that the hard way since I was using virtualbox before hyper-v broke crapā€¦ Hyper-v is really a load of annoyance (KDE Neon GUI worked fine in virtualbox).

Yeah found that out, I have curl installed systemwide, tried using it in powershell and it just kind of puked at me, since it was not curl, like wtfā€¦ No shell should override any existing application with any command unless it does precisely the exact functionality or better (like how most linux shells override [ to work faster but otherwise identically).

One of the big things I experience about Hyper-V is Iā€™ve yet to find a way to have it not eat up all the ram and instead allocate on demand, like virtualbox can be set to doā€¦

All of them, when youā€™re creating a new file.

Ah, I have everything default to \n only then. ^.^
Iā€™d not doubt that there are .gitattribute plugins for things like atom or so that can auto-detect though, or at the very least it would be so easy to make one. That is a useful idea, hmmā€¦

Cross-compilers work within WSL.

You canā€™t expect Microsoft to know about every command that every OSS project has ever written. Two independent groups, neither of which heard of the other, picked the same three-letter command name. It actually happens a lot (Googleā€™s Chromium conflicts with a game called Chromium, Rust the language conflicts with a game called Rust, multiple branches of mathematics want to claim Omega).

OTOH, overriding wget and curl was a horrible, and deliberate, choice of action.

Bash overrides time without providing the whole scope of functionality, so itā€™s not like itā€™s unprecedented. I just wouldā€™ve hoped people would learn better by now.

The problem is that dropping a * -text into your gitattributes file doesnā€™t tell it to use Unix line endings. It tells it to not change them, whatever it may be. If Iā€™m creating a .reg file for Windows, I want my text editor to use Windows line endings, and if Iā€™m creating or editing an HL7 message, I want the lines to be terminated by a lone ā€œ\rā€.

Does mix use cross-compilers?

These are the ones I am referencing, plus iex. They are entirely not functionally equivalent in any form other than the absolute basics. Even the command args are different.

That is for the purpose of getting more accurate timing data, which is what itā€™s purpose is. If you really need the default then just do env time <blah> (Remember that env <cmd> always uses the systems command, not a shell built-in).

.gitattributes can specify those. text=auto means use the system default (when pulling/pushing), which also works fine for an editor default as well. :slight_smile:

PowerShell iex, unlike PowerShell wget and curl, is not an attempted replacement for Elixir iex. PowerShell iex is short for Invoke-Expression. The fact that they share a name is a coincidence.

Then it should be IEX, not iex. :wink:

PowerShell commands are case-insensitive. Also, that would be IEx, with mixed case.

Ah true, it should be IEx.

Itā€™s not case sensitive? Wtf? That is a good reason not to use it right thereā€¦

1 Like

And PowerShell has a built-in called start. I used the .bat suffix to distinguish Invoke-Expression from Interactive Elixir, but this works too:

start iex --werl

Executables are case-insensitive under Windows. Given a choice, Iā€™d rather have the PowerShell builtins also be case insensitive than have exes and builtins disagree.

Also, having executables on your system with names that differ only in case is a serious system configuration smell.

Oooo, useful, Iā€™ll give that a try next time I need. Thanks! :slight_smile:

Not under Windows, but rather under the filesystems it includes by default. A custom filesystem does not need such a limitation as case-insensitivity.

Executables sure, but not commands. Iā€™ve made a LOT of functions and aliases and such in my shell that differ from an executable via just their case so that I can have special functionality without needing to replace the existing functionality. :slight_smile:

This is also why it is a wtf that powershell has case-insensitive ā€˜commandsā€™. o.O?!

False. Case-insensitive semantics are provided by the Win32 subsystem on top of whatever native filesystem youā€™re using. With the right API calls, I can do this:

some file, SOME FILE, and Some File in the same folder

NTFS is capable of a lot. Itā€™s the Win32 subsystem that limits you.