r/programming • • May 19 '20

Microsoft announces the Windows Package Manager Preview

https://devblogs.microsoft.com/commandline/windows-package-manager-preview/?WT.mc_id=ITOPSTALK-reddit-abartolo
4.6k Upvotes

640 comments sorted by

1.7k

u/Wireless_Life May 19 '20

Just about every developer has wanted a native package manager in Windows. That day is finally here. You are going to be able to winget install your way to bliss. One of the best parts is that it is open source. I had to pinch myself when I was able to winget install terminal, and then winget install powershell, and then winget install powertoys.

720

u/L3tum May 19 '20

Chocolatey just died haha

998

u/tehdog May 19 '20 edited May 19 '20

... this thing literally just downloads .exe files and then executes them. There's no dependency management.

Look at the firefox "package": https://github.com/microsoft/winget-pkgs/blob/master/manifests/Mozilla/Firefox/75.0.yaml

There isn't even any uninstall functionality. (Edit: or update functionality)

This is a package manager as much as a piece of cardboard is a swiss army knife.

141

u/jugalator May 19 '20 edited May 19 '20

Hopefully this is just the package description format that allows that sort of thing for a transition period until more "native" winget packages with dependencies happen. Otherwise I don't really understand this. The purpose of one to me is to manage dependencies and know how to install and uninstall things yourself without installers and do complete uninstalls without breaking other things.

So many essential features coming for V1.0 that I guess I'll just wait for that one instead. But good to hear this glaring hole in the Windows ecosystem is going to be fixed in an official fashion. Combined with .NET 6 and true cross-platform UI development also targetted for late 2021, interesting times ahead and especially in that timeframe.

24

u/irqlnotdispatchlevel May 19 '20

I don't really get into dependency problems with native Windows programs. You rarely get something like "x depends on y, and y depends on z-3, but you already have z-4".

62

u/erasmause May 20 '20

I suspect part of that is just that, lacking first class dependency management since the dawn of time, most windows software just includes all it's dependencies either statically, or as dlls installed by dedicated installers. This works, obviously, but it's not efficient, especially since dlls are sometimes installed locally to multiple application folders (to avoid conflicts).

→ More replies (12)
→ More replies (6)

0

u/[deleted] May 19 '20

[deleted] — view deleted comment

133

u/sally1620 May 19 '20

It is neither better or worse than chocolatey. Chocolaty also runs executables. Most of the time it actually runs the online installer that downloads more stuff

51

u/Jestar342 May 19 '20 edited May 19 '20

Checkout scoop.sh

→ More replies (9)

26

u/jarfil May 19 '20 edited May 12 '21

CENSORED

44

u/bitcrazed May 20 '20

Hi. PM on Windows here.

The team that owns winget also owns MSI, MSIX, Windows app installation infrastructure, etc. So I am v. confident that they'll eventually create a pretty cohesive app installation strategy built atop and alongside winget.

Oh, and note that one of the strengths of MSI that many enterprise admins like is the fact that it's a comprehensive database of information about how an app and all its settings, files, resouces, langpacks, etc. should be installed. Enterprise admins can decompose an MSI, alter it, and then re-package into a new MSI that fits their corporate needs, standards, etc.

MSIX takes this notion and makes installation much more declarative, removing many of the needs for custom script with a comprehensive suite of predictable actions that are growing frequently as new scenarios are understood and adopted.

→ More replies (6)
→ More replies (5)

413

u/Suirtimed May 19 '20

Remember this is a preview :) We are doing this in the open. If you have feedback or suggestions, please create Issues: https://github.com/microsoft/winget-cli/issues. The decision was to be open source rather than try to show up with a fully baked product that didn't do what you wanted.

275

u/tehdog May 19 '20 edited May 19 '20

Yeah, but my point is that if you start with executing installer binaries built by whoever, you're never going to get to the point where you have clean packages, because the installer can do anything and there's no way to revert or adjust what it does.

The only way to fix this while still allowing arbitrary executables would be to basically "build" the package by installing it in a clean room VM, and then packaging the file system delta + registry changes into a declarative package. But I doubt that's a goal of this project, so the best it can really do in the future is specify an uninstaller binary that may or may not remove hopefully most of the crap that the installer put on the system.

Or create actual build scripts for everything like normal package managers do, but that's not going to work for most proprietary software.

53

u/shooshx May 19 '20

and then packaging the file system delta + registry changes into a declarative package

I worked for a startup that tried to do exactly that in a generic way. We worked on that a long long time and eventually failed miserably.

An msi can basically do whatever it wants. It can generate config files that contains stuff about the specific network configuration of your machine, it can add registry values with paths to other stuff that is already there, it can choose to do or not do various things depending on hardware configuration, windows version, what you already have or don't have installed and the type of user that is running the installer. This is an endless and impossible problem that can't even be remotely solved generically.

Also, when you're just running windows idle for any amount of time, files and registry keys are changed all the time by various services. Just filtering this noise out and getting only what the installer "did" is an extremely non-trivial task.

→ More replies (2)

171

u/lillgreen May 19 '20

[...] so the best it can really do is specify an uninstaller binary that may or may not remove hopefully most of the crap that the installer put on the system.

Ayyyy, I always wanted to return to the days of Windows 9x!

"I install WeatherBug, I uninstall WeatherBug... Why is this purple monkey still on my screen?"

→ More replies (13)
→ More replies (41)
→ More replies (20)

39

u/[deleted] May 19 '20

The manifest spec clearly supports "well-known" installer technologies like MSI, MSIX, inno, Nullsoft, etc. That's a bit better than just downloading arbitrary EXEs.

With that in mind, it's not too hard to imagine that the v0.1 spec is eventually revised to include uninstall information. It'd be bonkers to not offer uninstall functionality. That's why you would specifically include MSI, Nullsoft, etc. because those have well-known uninstall switches etc. Yeah, you have to trust the installer and uninstaller are doing what they say they do, but that's no different than the case on desktop outside of winget

14

u/Herbstein May 19 '20

Yeah, this does exactly what every other, very useful, package manager for Windows does. I've gotten tons of mileage out of using Scoop for most of my package management needs. Sure, it "just" runs executables. But it also supports managing persistent data in a central location. For example, NPM packages are persisted in a folder in the scoop folder structure separate from the binary files that changes with releases. And it's setup automatically.

7

u/jogai-san May 19 '20

Scoop doesnt run executables. Most of their buckets are limited to portable stuff, so they just unpack it in the right locations.

→ More replies (1)

19

u/EMCoupling May 19 '20

Hey, if you were alone in the snowy tundra, you'd be thankful for that piece of cardboard!

→ More replies (3)
→ More replies (28)

18

u/luxtabula May 19 '20

I use Chocolatey rather often. Is there anything Winget brings to the table to make me switch from using Choco? It seems to do the job so far, but maybe I'm missing something in my myopic use-case.

27

u/L3tum May 19 '20

A few things actually, although none of them are hard upsides.

  • Sponsored and maintained by Microsoft. There's an official registry and the possibility of third party registries. You can also add and even offline use your own manifests. The possibility for the community to grow is much bigger than with choco.
  • Likely better integration into Windows. It remains to be seen what they do with this, but there's definitely the possibility that they enable some things or do some things differently because of this.
  • Better integration in general. I'm not sure about choco, but I've already seen some WSL distros on winget.
  • Better CLI. You can search the repository for example (something I've always found cumbersome in choco).

One thing I'm a bit hesitant about is the security. I'm not sure how much vetting they're doing and how secure an existing package is. Who can update it? Is there signatures? Maybe they go the approach of most language package managers like NPM, where they just don't care and the user is supposed to know whether something is secure or not.

30

u/Vawqer May 19 '20

This is what the article says regarding security:

We looked at several other package managers. There were several reasons leading us to create a new solution. One critical concern we had was how to build a repository of trusted applications. We are automatically checking each manifest. We leverage SmartScreen, static analysis, SHA256 hash validation and a few other processes to reduce the likelihood of malicious software making its way into the repository and onto your machine. Another key challenge was all the changes required to be able to deliver the client program as a native Windows application.

As well, it appears that all updates have to go through a PR, so I think Microsoft is aiming for a decent level of security here.

→ More replies (2)

2

u/[deleted] May 20 '20

for me, chocolatey died when i found scoop. https://scoop.sh/

about 1000% better than chocolatey, imo, as a package manager.

→ More replies (1)
→ More replies (28)

9

u/agumonkey May 19 '20

This is gonna make the life of a million users a lot easier too

18

u/fast4shoot May 19 '20

This is not a package manager. There is nothing resembling packages in here. It's a glorified installer runner.

9

u/panties_in_my_ass May 20 '20

Windows is not linux. It has totally different development conventions, and so the ideal package manager will look different under the hood. Specifically, windows apps have always shipped with their own dependencies. So why should a package manager deal with a complex dependency graph when it doesn’t have to?

An electric car is still a car, even though it doesn’t have a gas tank. Should Tesla start outfitting their cars with gas tanks to make them more familiar to users and mechanics? No, obviously not. And similarly, microsoft need not fit their package manager with a dependency resolution technology. It doesn’t need it.

To a user, a package manager is just a cli for package installation and management. This fits the bill.

3

u/fast4shoot May 20 '20

I didn't mention dependencies, did I?

And yes, traditionally Windows apps have shipped with all their dependencies. Why? Because they didn't have a sensible package manager that would resolve those dependencies.

Package management doesn't mean just dependencies, it's about installation/updates/uninstallation, being aware of what packages should be installed, being able to verify the integrity of those installed packages, providing conflict resolution, etc.

To me, as a user, a package manager that doesn't do any of this is not a package manager.

→ More replies (2)
→ More replies (1)

2

u/MishMiassh May 20 '20

If it's a package manager, can it REMOVE Windows apps, and services, so I don't have to do it manually at each install?

1

u/grumpysysadmin May 20 '20

Looking forward to have Ansible support winget for packaging. It already supports Chocolatey and I suspect winget support would be a huge win.

→ More replies (54)

16

u/Wireless_Life May 19 '20 edited May 19 '20

Windows Package Manager Preview is available for download here

10

u/TankorSmash May 19 '20

If this is through the MS Store, does that mean it autoupdates and obfuscates the install dir like it does with games?

228

u/[deleted] May 19 '20

c:\ > runas Administrator winget install update

17

u/SolarFlareWebDesign May 19 '20

Powershell SetExecutionPolicy.bat

481

u/RecursiveAstronaut May 19 '20

Hell just froze.

113

u/Borkz May 19 '20 edited May 19 '20

you can winget iTunes?

edit: The reference, from apple.com circa 2003

15

u/haby001 May 19 '20

Back when iTunes was actually good

14

u/g-money-cheats May 20 '20

Back when iTunes actually existed.

→ More replies (2)

5

u/bestsrsfaceever May 20 '20

iTunes was never good

8

u/duckvimes_ May 20 '20

The best Windows app ever.

I'm amazed that someone was able to keep a straight face while they proposed this slogan.

6

u/varesa May 19 '20

At least it looks like you can winget Ubuntu (well, not very surprising with WSL)

4

u/[deleted] May 20 '20

So now we (literally) can use winget to get ubuntu to get apt to get node to get npm to get bower.

→ More replies (1)

74

u/ginger_beer_m May 19 '20

I like the new Microsoft. They're embracing open source a lot lately

→ More replies (35)

3

u/dabenu May 19 '20

I almost forgot what a hassle it used to be to install software on windows. Can't believe that lasted until today...

242

u/Nefari0uss May 19 '20

Fucking finally. Really looking forward to this and migrating away from Chocolatey, Scoop, and the like.

346

u/VegetableMonthToGo May 19 '20 edited May 19 '20

Not so fast.

I'm a Linux distribution package maintainer so I looked a bit into this, and my first feeling is: messy.

Take for example Bitwarden. Simple electron app which is GPL 3 licensed. What does Winget do? Download the executable and silently run. This means that there is no form of data encapsulation, sandboxing, partial updating, or automated updating all. From a Linux p.o.v. this is very unoptimised.

Compare this with scoop. Scoop installs everything in user-space, it does versioning and it supports all kind of advanced configuration. Mostly just CLI tools, but then again, this is a tool for developers.

What you want from an advanced packaging system, especially aimed at developers, is some more control over versions and configuration. With the Bitwarden example, it's anyone's guess if it keeps old versions available or if you're stuck using the latest version with a single set of configurations.

Contract this with Deb er Flatpak. Vastly more powerful and many times more optimised. Flatpak especially, which uses a 'git on steroids' to update packages based on individual files and version hashes, while having a strong sandbox model and multiple configuration options.

For now, if you work on Microsoft, stick with Scoop

103

u/Suirtimed May 19 '20

We're on version 0.1.0 doing this in the open. We'd love your suggestions and feedback: https://github.com/microsoft/winget-cli/issues/new/choose

20

u/kalmoc May 19 '20

What exactly is the expected value proposition compared to the windows store?

34

u/[deleted] May 19 '20

What exactly is the expected value proposition compared to the windows store?

Turn the answer around:

What is the value of a GUI package manager on Linux compared to simple command line tool on Linux ...

Normal non technical users like to use a GUI. Technical users like to use command line ( and maybe make batch scripts with auto install software etc ).

Maybe in the future the winget will include more advanced features like sandboxing / versioning / ... and other options that will confuse the normal users that use the Windows store. Aka, the Windows store = the simple and easy installer. The Winget = the advanced installer.

→ More replies (6)
→ More replies (5)
→ More replies (27)

103

u/LMGN May 19 '20

This means that there is no form of data encapsulation, sandboxing,

I mean, if you are malicious, most package managers have a feature where packages can just say, hey can you run this script when installing please, it's super important

55

u/VegetableMonthToGo May 19 '20 edited May 19 '20

True, I can technically do anything in an installation with admin rights: Steal your bank details, copy your SSH keys, change your homepage to the Lady Gaga fansite.

But normally, packages, especially those using newer techniques like Flatpak, have some restrictions defined by the home system. I could still change your homepage, but your SSH keys are out of my reach.

→ More replies (4)

31

u/Nefari0uss May 19 '20

I'm a Linux distribution package maintainer

Oh cool. What do you maintain?

This means that there is no form of data encapsulation, sandboxing, partial updating, or automated updating all.

Well that's disappointing. One of the things I was looking forward to was not having to manually update stuff.

Also, what do you mean by data encapsulation and sandboxing? How is that implemented for package installation? Can't they theoretically write to anywhere? How does this work on something like Pacman or apt or the snap packages?

82

u/VegetableMonthToGo May 19 '20

Oh cool. What do you maintain?

I'll decline to answer because this is also my Reddit account that I use to like and share porn.

Also, what do you mean by data encapsulation and sandboxing? How is that implemented for package installation? Can't they theoretically write to anywhere? How does this work on something like Pacman or apt or the snap packages?

By default if you use Apt or dnf, programs are added into your base system. This is optional though, and you can create new containers where you can install specific versions of certain tools. Best example of Fedora's Toolbox, which allows you to easily install multiple version of Linux, and their respective tools, side by side. Want to compile something using clang 1.2 with some proprietary extension? Add it to a Toolbox.

Flatpak goes a step further (refresh, I extended a bit on that in my post) and it actually makes a docker+git-like system of the entire application. Super robust and easy to upgrade, and you can always tell Flatpak to use a specific version.

Snap, I prefer to stay away from. It's a vendor-locked technology solely supported by Canonical.

→ More replies (2)

7

u/Vawqer May 19 '20

Well that's disappointing. One of the things I was looking forward to was not having to manually update stuff.

This is just a v0.1, it appears that by v1.0 Microsoft wants to at least have a command that updates all apps at once.

→ More replies (1)

13

u/notrealtedtotwitter May 19 '20

Exactly, this package manager needs to do a lot of things to come close to how good scoop is. But we atleast have something Microsoft sponsored, and honestly anything is better than chocolatey.

5

u/[deleted] May 19 '20

scoop extra has a ton (1000?) popular gui applications that it can install in ~/scoop too. It's very nice.

https://github.com/lukesampson/scoop-extras

2

u/schlenk May 19 '20

Scoop is nice for installing but some of the wrappers/shims it installs are PITA. e.g. its vim package lacks quite a few nice integrations thats offered by the official vim installer (no context menu integration), blocks the console instead of working like start etc. Mixed blessing. Its okay for installing the odd linux commandline tool.

→ More replies (2)

2

u/psychicsword May 20 '20

It is a preview... Give it time

→ More replies (1)
→ More replies (2)

7

u/TryingT0Wr1t3 May 19 '20

I think with this package manager you can't specify versions (like chocolatey) and it doesn't have libraries (like ... The dlls I shove in repos because vcpkg also doesn't allows me to specify versions?)....

3

u/wavefunctionp May 19 '20 edited May 19 '20

You specify which apps you want installed, and it does the work of finding the latest version (or the exact one you specified) and installing it on your machine.

Literally in the first paragraph.

40

u/asegura May 19 '20 edited May 19 '20

Very nice indeed! but:

  • I see an "install" command, but no "uninstall". Should we uninstall from Add/remove programs? no scriptable way?
  • There is no "upgrade" either. I guess install will upgrade if a new version is available.
  • I just installed a couple programs and it did not request Elevation (the typical screen that pops up to accept installing something). Is that OK? I don 't mind, my account has administrative rights, just curious.
  • I didn't see anything like package dependencies (did not dig too much). For example, some git GUI might need git installed first. Is there anything like that or plans to?

17

u/DarknessKinG May 19 '20

6

u/asegura May 19 '20

Interesting. (update, uninstall, dependencies, etc.)

Still over one year for v1.0, though.

10

u/anonveggy May 19 '20

Same as terminal and while this forces us to have this discussion - in the end it was worth it. The community had tons of feedback and we've got a stable battle tested open source app released to the general public as a result.

33

u/Nowaker May 20 '20

Issue #223 is hilarious and brutally true.

Not a package manager

The description claims this thing to be a package manager but in reality it has nothing to do either with packages or management. All it does is downloading installers (which are not packages) and executing them (which is not management).

2

u/TantalusComputes2 May 20 '20

Well “installation executor” is my job title so I’m glad they called it that /s

1

u/bemlikanz May 20 '20

this made my day

79

u/amroamroamro May 19 '20

I don't see this as a proper "package manager" (neither Chocolatey, scoop, .. for that matters), all they do is automate downloading existing installers (exe, msi, zip, ...) and taking care of running the installers, unpacking the archive, etc.

For it to be a package manager they need to design a well-defined packaging format, and everyone else releasing their apps packaged using that format (I'm thinking MSIX).

Hence this will still suffer from the same shortcomings as all the other solutions that already exist.

18

u/jogai-san May 19 '20

Scoop is different, and therefore limited to portable packages. But at least its a lot closer to a real package manager.

→ More replies (2)

3

u/MighMoS May 19 '20

I'm reading through and thinking "this is great" but the more I read the more I'm thinking "This is a shittier version of Google Play Store".

15

u/adrianmonk May 20 '20

Actually, the Google Play Store has a well defined packaging format, and the operating system and the Play Store together do the installation. There are no installation scripts or anything like that. The application has to go where the system puts it, and the system tracks what is installed, and can completely remove the installed files.

It doesn't do dependency management, though. Because it doesn't allow dependencies. Every app has to be standalone. (You can do inter-process communication, but you can't have the store retrieve a dependency and link to it.)

→ More replies (1)

74

u/[deleted] May 19 '20

As someone that never used the other 3rd party windows package managers -- but read about them and was recently considering getting familiar -- is this a replacement for the normal application manager ala "Add/Remove Programs"?

What is uninstalling and upgrading like with this? I hate the cruft that is left behind in the registry, and ApplicationData and other locations throughout Windows, so I would love for this to be a major shift in how this is handled.

80

u/Nefari0uss May 19 '20

Replacement? No. End users would never touch Windows again. For developers? As much as I can, yes.

For uninstalling and stuff, isn't that usually the application's job to do it properly? Guessing it might be the same here.

23

u/bipbopboomed May 19 '20

What makes it better than just installing something from an exe or w/e?

75

u/[deleted] May 19 '20

One central source, you don't have to go to several websites.

It's scriptable

It's easy to find new versions of software or "pin" to a specific version

18

u/elebrin May 19 '20

This is my big one, ESPECIALLY if you are able to have your own package repo.

My first task at my first IT job was to re-install Windows and a pile of software on 12 laptops. It kept me seriously busy for an entire workday (this was circa 2006 and we did NOT have automated tools set up to help). Something like this is a quick way to get software up quick, with the versions that you want, any extra or special packages that you want (like your organization's custom apps), at the speed of your wired, onsite network IF the repo is hosted onsite.

5

u/bipbopboomed May 19 '20

Makes sense, especially the versioning.

→ More replies (3)

26

u/sihat May 19 '20

Easier & faster.

Instead of finding it online, downloading it, waiting for that and installing it. Especially for multiple things.

One command line to find, download and install.

And in the darkness bind them.

→ More replies (1)

4

u/Nefari0uss May 19 '20

I like the fact that it can easily update my software with a simple command. Furthermore, it's easy to get setup on a new machine or reinstall. Just run a script that tells it to install a giant package list and in good to go after a bit. I also use the terminal quite heavily so it fits nicely with my work flow.

Example: I needed some stuff for work so I just typed brew install packageName (MacBook for work) and had it install what I needed rather than downloading and running the installer. No clicking of next and stuff; just let it run quietly.

→ More replies (2)

6

u/ivosaurus May 19 '20 edited May 20 '20

Do you enjoy having to manually find the update button for every application you use, it being a different process for every application, gets activated at different times, maybe pops up an annoying toast every week, maybe you just have to visit the website once every two months randomly to see if there's a new version, download an installer, click through the install process yet again for the 14th time, maybe it does its own dialogue you have to click through...

...no?

How about navigating through an installer with different options for every application when really defaults are just fine or you can adjust options later, and always find where the freaking adware addon needs to be opted-out of in a different place in a different way...

...no?

Have you ever just wanted to "get the latest version of all of your current apps" but without having to click through 17 different installers in one night?

...yes?

Linux users have been enjoying not doing all that for decades now.

6

u/bipbopboomed May 19 '20

In 2020 it feels like half the shit is already "update me now, or fuck u"

I get it, I think I'm just more of a visual person. A tiny learning curve I haven't gotten over. Thanks for the info though.

6

u/chunes May 19 '20

Maybe it's different with pacman but with apt many of the programs I want to run are years out of date or absent altogether, so I have to resort to installing them manually just like I do on Windows.

→ More replies (4)
→ More replies (1)
→ More replies (1)
→ More replies (2)

8

u/Carighan May 19 '20

Well that's unrelated, tbh. There's no reason a GUI installer couldn't clean up properly, and there's no reason for a CLI based one to clean up if it wants to be messy.

9

u/[deleted] May 19 '20

linux packages leave behind their useless dotfiles. The registry could be configured to be a fancy .config folder

5

u/Ruben_NL May 19 '20

so, leaving data in the registery? please not...

better a separate file in the home folder, that i can easily remove.

26

u/weirdasianfaces May 19 '20

useless dotfiles

Maybe I'm crazy, but I personally find dotfiles in my $XDG_CONFIG_HOME easy to use and not useless. Half the time I have a hard time figuring out where the hell the application's registry path is.

25

u/[deleted] May 19 '20

I'm talking about dotfiles for programs that have been uninstalled.

7

u/SvenMA May 19 '20

Purge? I thought every packagemanager has the option to purge

→ More replies (2)
→ More replies (7)

7

u/thoomfish May 19 '20

https://wiki.archlinux.org/index.php/XDG_Base_Directory

Seems like support for $XDG_CONFIG_HOME is kind of mishmash (and it's not on by default, so I've got 50+ dotfiles in my $HOME on my Linux box).

5

u/[deleted] May 19 '20

Applications should default themselves to $HOME/.config if $XDG_CONFIG_HOME is not defined, though. Dotfiles in the home directory get annoying really quickly.

→ More replies (2)

50

u/duyaw May 19 '20

Pretty awesome. I hope they have good powershell cmdlets, choco always annoys me when I have to check for exit codes.

Also a Windows equivalent of sudo would be nice.

2

u/[deleted] May 19 '20

Scoop has a good sudo package.

1

u/Skruzzls May 19 '20

I always use Cmder as Terminal which has lots of Unix-Shell commands like ls and cat. There is also a sudo-Command (csudo) and it looks much nicer than normal cmd/powershell. Supports both and WSL as well.

→ More replies (1)

1

u/nascentt May 19 '20

1618. Literally had to overload choco install because it's useless

0

u/[deleted] May 19 '20

[deleted] — view deleted comment

40

u/jcotton42 May 19 '20

runas can't elevate, which is what most people are talking about when they say sudo

→ More replies (14)
→ More replies (1)

19

u/krystalgamer May 19 '20

rip chocolatey

16

u/Caninomancy May 19 '20

choco uninstall yourself

→ More replies (1)

29

u/jeeeeefff May 19 '20

Huh. The name is literally "wing it". Years and years of jokes inbound

13

u/Paddy-R May 19 '20

That's exactly what I read the command as,

WingIt install something

Then just hope for the best.

8

u/CatchGerardDobby May 19 '20

Will this support shared dependencies?

As I understand it in Linux, if multiple programs reference, say, the same version of ffmpeg, they will all use the same binaries for that dependency. Will this be the case here?

5

u/schlenk May 19 '20

Shared dependencies are dying on Linux thanks to docker, flatpack & co. But Windows can do the same if needed (e.g. the Global Assembly Cache is one way) and even the old MSI installer infrastructure did it.

→ More replies (1)

1

u/MighMoS May 19 '20

Word on the street is no. I'd be so happy to be wrong.

8

u/[deleted] May 19 '20

MFW windows changes its name to WINDos and says it stands for”WINDos Is Not Dos”

32

u/DarknessKinG May 19 '20

Did any of you that are complaining read the Roadmap ?

They are going to add (uninstall, update, dependency support etc.. )

10

u/fast4shoot May 19 '20

Well, the question is how they're going to do that? Because right now it's just simply not a package manager. It has no clue what files from which packages are installed on the system, so it would have to rely on the applications to provide the update and uninstallation process.

They're either going to have to redesign how the entire thing works (i.e. they'd have to make it a package manager first) or it will just be another awful hackjob just like the installation is right now.

5

u/Hacnar May 20 '20

What redesign/hackjob are you talking about? They have a roadmap, planned features, a pretty good idea how to move forward. All they did is that they opened the repo the moment they got the first feature working, instead of after having several features written. They did it to collect feedback very early in the process, and let the community influence the development from the earliest stages.

Well, the question is how they're going to do that?

Probably better, thanks to the community input, than if they had done it behind the closed doors.

5

u/aquaticpolarbear May 20 '20

If they have a good idea of how to move forward they're not showing us. A good start is to look at how other package managers work, they generally have a custom format that contains files to install and list of where to install them. This package manager doesn't come with that kind of format. It just downloads and runs exes. So without them revamping how it currently does the core functionality of installing, the package manager doesn't actually know what's going on, it doesn't know where files are going and hence how to delete them.

→ More replies (1)

26

u/moopet May 19 '20

Let's all put our hands together and welcome Microsoft to 1997.

1

u/skunkwaffle May 20 '20

They should get Meredith Brooks or Chumbawumba or someone else who was big back then to play for the release party.

17

u/no_nick May 19 '20

Microsoft should just rewrite windows as a DM for Linux and port office and its other stuff to Linux as well at this point

6

u/broknbottle May 19 '20

Systemd/Windows, a lennart can dream

5

u/jogai-san May 19 '20

One can dream...

0

u/[deleted] May 20 '20

[deleted] — view deleted comment

2

u/no_nick May 20 '20

OTOH, we might have ended up with an AT&T situation

12

u/KallDrexx May 19 '20

God please let this not be piggy backing off the terrible Microsoft store infrastructure. I don't understand how the Microsoft store has gone for so long as the most buggy download system known to man.

1

u/drogas_masni May 20 '20

This has nothing to do with the store, don't worry

134

u/Parachuteee May 19 '20

Ubuntu: Noooo you can't just keep copying Linux features

Microsoft: haha developer user base goes brrr

2

u/Miiiidas May 20 '20

Don't think anybody using linux really cares, I'm happy that my fellow devs who still run Windows get some of that goodness. But there's no chance in hell I'll ever develop on a Windows machine again.

4

u/nakilon May 20 '20

/r/programming audience is so lame they think it's a "ubuntu feature"

6

u/SuspiciousScript May 20 '20

I mean, embracing proprietary software is not something we should really be cheering for as devs

4

u/OMGItsCheezWTF May 20 '20

I mean if it's released with an open source license is it proprietary? Microsoft have released this with the MIT license.

→ More replies (1)

6

u/teiman May 19 '20

Honestly: when I install something on mac, I try brew first. is just too smooth compared to the app store. I also forget my passwords often :(

35

u/thanasis2028 May 19 '20

And only like 25 years late!

28

u/nuunien May 19 '20

This looks really stupid. Just a yaml file to tell where to download outdated software from, then silently execute it. No way to specify dependencies, uninstall, or update something.

This is NOT a package manager, you should not have released this under the guise of "wanted to make it OSS". This is shit, and you should be ashamed.

Then you have the gall to ask us to contribute to your piece of shit software. Perhaps get actual software engineers involved with such a much-needed critical software, and not the first rando interns you had available.

2

u/MUST_RAGE_QUIT May 20 '20

I agree, this is obviously some sort of joke.

21

u/amazingmrbrock May 19 '20

Yes the linuxifocation of Windows is coming along nicely. I'm predicting full kernel switchover by 2025

14

u/[deleted] May 19 '20

RemindMe! 5 years

4

u/RemindMeBot May 19 '20 edited May 21 '20

I will be messaging you in 4 years on 2025-05-19 18:44:02 UTC to remind you of this link

7 OTHERS CLICKED THIS LINK to send a PM to also be reminded and to reduce spam.

Parent commenter can delete this message to hide from others.


InfoCustomYour RemindersFeedback

1

u/ClassicPart May 19 '20

I wouldn't be at all surprised if we saw a Linux Subsystem for Windows at one point but 2025 is far too short of a timeframe, especially for a full kernel switchover.

→ More replies (1)

11

u/Splanky222 May 19 '20

How does this compare with vcpkg?

30

u/jesseschalken May 19 '20

vcpkg is for C++ libraries. winget is for system and user applications.

Compare npm, composer, pip, cargo etc with apt-get, pacman, yum etc on Linux.

→ More replies (8)

23

u/anonveggy May 19 '20

Completely different use case. Vcpkg manages libraries and tooling. Winget is a chocolatey/aptget/brew comparable thing. You install steam or windows terminal over winget.

→ More replies (4)

8

u/mishugashu May 19 '20

Wow, Microsoft stepping into the 21st century finally. Welcome, Windows users.

8

u/-Defkon1- May 19 '20

Redmond: Becoming Linux

13

u/letemeatpvc May 19 '20

Windows turns into a modern OS? lol

4

u/[deleted] May 19 '20

I really hope we would have the ability to create our own custom repositories. Imagine how useful this will be for businesses to keep software updated on client machines. They could have their own repository as the only repository with all the apps that they approve of and a scheduled task that can update and upgrade all the software on their client machines.

2

u/schlenk May 19 '20

You can already do that with Active Directory and MSIs...

9

u/dood1337 May 19 '20

Is this a dream?

3

u/AttackOfTheThumbs May 19 '20

Can we control updates / schedule? I don't want stuff to update unless I say yes.

1

u/drogas_masni May 20 '20

No updates through this yet, it's on the roadmap, and it's gonna be a manual command

4

u/Pixa May 19 '20

Huh... Everyone's probably going to be like "finally catching up to Linux", except this is nothing like that, it's just a worse version of chocolatey...

At least chocolatey packages contain the installer. What happens if your software vendor updates their website and changes the download URL?

Any Windows package manager that doesn't put its foot down and insist on a real software package format like MSI or MSIX isn't a package manager, it's cruft that gets in the way.

I don't get what the use case for something like this is anyway. I don't re-image my PCs regularly enough to warrant automating the installation process, and if I did, there will always a few pieces of software where the vendor doesn't upload packages or manifests and the guy who was uploading them in his spare time stopped 4 years ago after he graduated and got a full time job. If I wanted to deploy software across a fleet of PCs I'd either use Active directory, or just script the exe I wanted to use in the first place! After all, that's all this tool is doing.

1

u/no-name-here Jun 15 '20 edited Jun 15 '20

I'm a big fan of Chocolatey, but...

At least chocolatey packages contain the installer. What happens if your software vendor updates their website and changes the download URL?

Chocolatey packages don't contain the installer. The most popular Chocolatey package is Acrobat. You can see its source at https://github.com/itigoag/chocolatey.adobe-acrobat-reader-dc/tree/master/package/tools From the code, you can see that it references the download URL (as opposed to containing the installer).

Any Windows package manager that doesn't put its foot down and insist on a real software package format like MSI or MSIX isn't a package manager, it's cruft that gets in the way.

Are there any Windows package managers that do that? For example, Chocolatey supports a variety of things.

there will always a few pieces of software where the vendor doesn't upload packages or manifests and the guy who was uploading them in his spare time stopped 4 years ago after he graduated and got a full time job. If I wanted to deploy software across a fleet of PCs I'd either use Active directory, or just script the exe I wanted to use in the first place! After all, that's all this tool is doing.

If you used Active Directory or "just script the exe", wouldn't you largely be re-implementing the same things these tools are doing as you said, but without the benefit of leveraging whatever updated software packages these tools already do have? Wouldn't the better alternative to re-implementing it all from scratch be just to provide (updated, if needed) packages for these tools for the particular apps you wanted where it isn't already there?

5

u/antenore May 19 '20

We want a package manager!

20 years later…

Now we want custom repositories and user contributed packages!

…

2

u/ftgander May 20 '20

Lmk when it does all the things scoop does

2

u/Corvokillsalot May 20 '20

another attack surface

2

u/[deleted] May 20 '20

This looks a lot like Homebrew Cask (or at least it will when they add all the functionalities such as uninstallation and upgrade).

On macOS though, many apps are just .app folders and the OS can keep track of the files installed by a .pkg installer, so the whole uninstallation process is managed quite decently (although it's still very ugly compared to a real Linux package manager).

I'm not sure how this would be feasible on Windows, where 90% of the software uses .exe installers that can do whatever they want (or at least this was my understanding).

Nowadays Scoop follows the best approach IMHO, using portable installation every time it's possible and putting everything in a single place managed by Scoop itself, but I don't think that Microsoft is going to follow the same path here..

2

u/panorambo May 20 '20 edited May 21 '20

I have to admit I don't understand why most of you think Windows was lacking a package manager.

Not very long time ago I had to learn how to distribute a good old desktop application I wrote for Windows. Now, before we start classifying Windows software, you have to understand that by good old desktop application I mean one that basically relies on the venerable Win32 API. Win32 is the largest set of functionality Windows provides, by far, so just about anything that can be written and has been written to run on Windows uses Win32, directly or not. I am including things like COM and DirectX there.

Anyway, I had to pick a packaging technology. I've always majorly disliked the idea of distributing an installation as an .exe file, for several reasons I consider good ones. For one, .exe files can't be easily introspected for what is actually being installed (application files, configuration, auxilary services, drivers, etc) where and what options one has for customizing the installation. Unless the vendor has gone out of their way documenting command line options to said .exe file, which they normally don't. Second, .exe files have been, still are and will always be a great malware vector -- tempting to hide a bootstrapping worm or other malicious piece of code in that PE file, with all the granularity it provides. Third, .exe files are subject to all kinds of restrictions, being how they're native program images. There are other reasons, but these three are enough for me to not ever consider distributing Windows application installations (or packages) as .exe files.

A ZIP/similar archival format is also not optimal -- it's just short of a package format (unless it's self-extractable which makes it an .exe again, with most of the latter's shortcomings in this context), as such only suited for purely portable distributions -- no file type registrations (before first launch) or application registration (in the program list, for one) of other kinds. All you have is ability to unpack a bunch of files and folders somewhere. An installation often requires a good bit more than that.

Anyway, with any novel package file format or technology, there always is the "boostrapping" problem -- you need to obtain the actual package manager before you can use it to install and manage your software. It's a barrier to entry for every such product that isn't part of Windows already.

Now, Microsoft has been shipping Windows Installer for many years now, and given how they're in a unique position to bundle anything they want with their operating system (we'll ignore antitrust issues here), that's what I'd call the homefield advantage. Anyway, Windows Installer has been there for 30 years and if you have ever had to deal with .msi files one way or another, well that is it.

Some good things about .msi files are that they're declarative, essentially self-contained, extensible relational databases consisting of installation components, features, files, registry values and other kind of elements (COM classes come to mind, which I think is an awesome technology). There are other redeemable features, too -- Windows Installer, specifically its command line agent msiexec.exe can install and uninstall packages by URLs. And here you already have the markings of the repository concept -- since a person installing a product implicitly has to trust the vendor of the product, they will trust the vendors Internet domain name. It makes all kinds of sense then to be able to install the product using an URL with the vendors domain name as host name -- directly from the vendor. But if the user would, for some reason, prefer another mirror or be forced to use one, you can still host a bunch of .msi files with a HTTP proxy or mirror.

.msi files can be signed. They can track versions of the components they package, too. Installations are transactional by nature, and can be extended through custom actions -- for things that don't lend to the kind of declarations built into Windows Installer (files, registry values, COM classes, and some others). Windows Installer transparently supports installation of the same package through unattended/command-line/GUI installation method, with minimal provision from package author -- the same package can be installed with a GUI or without it, unattended if desired.

The picture I am trying to paint is that perhaps we could instead invest time and energy into solutions that have been "hiding in plain sight", instead of acting like the new shiny is much better anyhow. In Windows, things either collect dust on the shelf or are replaced so rapidly you aren't sure you missed it. How is Winget going to be better than what's already there?

For me, a package manager is a way to conveniently manage installed software, and thinking about it, I don't miss all that much from Windows Installer save for market penetration. I think Microsoft were a bit shy about it, for one reason or another, and it had its market share eaten by the likes of InstallShield (ugh, I have banged my head against that wall), NSIS, WYSE, and InnoSetup to name some, all in a critical period of time when it was in its infancy and needed to make it. It was ironically much loved in organisations where wieldly package management across entire organisational domain was critical.

With MSI, you can install software with:

msiexec /i https://example.com/foobar.msi

If the vendor updates the msi file served with above URL, the same command can intelligently (the package can have a say in it) update the software. Uninstallation is done with /x instead of /i.

How isn't that at least decent form of package management? And if you can't be arsed with remembering URLs for your favourite software, then use a proxy and a mirror with as short URLs as you can have without name collision.

We could also at least have an MSI-compatible package manager on top of msiexec, if it's too low-level or insufficient. That way Microsoft could perhaps get back into Windows Installer game -- the latter hasn't seen an update in 10 years or so. It has dust on it, but the engine is good, I think.

11

u/Smaktat May 19 '20 edited May 19 '20

Looking for some why from the perspective of someone who's excited about this.

e: Yo if you downvote legit questions, others may not see it and it'll collapse the comment node automatically. Please have some respect for asking questions and don't create an environment where we can't ask them.

28

u/[deleted] May 19 '20

Windows application installation has been a serial train-wreck for over 30 years. I've written and/or maintained my share of installers. They suck.

Over the decades Microsoft has swung between complete neglect of the issue (leading to terrible programs by third parties, like InstallShield) and clueless authoritarianism ("modern" apps). In the middle ground have been the Setup APIs (lots of howlers in there, it'll make you shake your head in wonder) and the crufty horror that is the INF file format (leave your sanity at the door).

Package management is not something you want to leave to chance or to political infighting, or to "feature chicken". It needs to be part of the system as a whole, and Microsoft never really got this right. There are teams at Microsoft who write really good installers . . . but why the hell should this even be a thing that individual teams need to spend significant engineering effort on?

6

u/frnxt May 19 '20

That triggered me so much. We have a crappy VS Setup installer at work that never seems to do the right thing, in addition to using a setup definition format that is completely unversionable...

7

u/Rossco1337 May 19 '20

Windows has always needed proper package management. Even if you're a desktop user who likes clicking "Next", you've probably fallen for an "optional" trick or two. Microsoft did it in their own installers! (www.techruzz.com/images/How_to_Download_and_Install_DirectX_12_on_Windows_7.jpg). Where do I even begin?

  • Currently, everyone is writing their own "thin app" executable downloads to download and install the real apps.
  • Most Windows programs write their own auto-update mechanisms which run on boot which look and act like malware to AI. Not to mention running on startup and slowing down boot times.
  • All of the testing and UX goes into the installation process rather than the uninstallation process, leading to the classic Windows cruft problem for desktop users.
  • Almost all installation wizards on Windows use a GUI, which makes app deployment difficult and expensive. Most orgs end up paying for something like Ninite Pro.

I could probably think of plenty more reasons. Like with antimalware, the only surprising part is that Microsoft is only getting around to fixing this deficiency in Windows now, after an entire industry of third party deployment and management tools has begun to thrive.

8

u/analoguewavefront May 19 '20

Allows for easy & quick set up of a Windows PC. When I have a new person start at work there’s a bunch of stuff they need to install and set up. I try to automate this as much as possible and this allows me to write a script to run which installs all the programs they will need.

Similarly, I try a lot of software on one of my PCs and it gets full and I wipe it and start again. This allows me to double click a script and install all the basic programs I need. No visiting websites and downloading of latest versions needed.

Admittedly you could already do a lot of this with other package managers, but they had flaws that people are hoping this MS version doesn’t.

→ More replies (1)

0

u/[deleted] May 19 '20

[deleted] — view deleted comment

5

u/Smaktat May 19 '20

I literally don't know so I thought I'd asked. Surprise, asking questions just gets downvotes. Got forbid I legitimately don't know.

12

u/Himekaidou May 19 '20

My best guess is that people might have thought your question was a troll, since package managers are pretty useful and well-regarded in basically every other OS/setting.

As for the why, having a consistent, scriptable, and reliable way to install/upgrade as much as possible on the system is very useful for a variety of situations.

→ More replies (8)

3

u/SoInsightful May 19 '20

Non-engineering answer: It's such an incredibly nice thought to be able to hop onto any machine and simply type winget install some-program, instead of the whole dance of "open your browser → search for the most reputable and correct-looking installation website → wait for the file to download → unzip the file → run the horrible installer → go through all the steps and options → opt out from the included adware/bloatware → hope that everything installs correctly and that you don't have to restart your computer too many times".

→ More replies (1)

3

u/bmw_fan1986 May 20 '20

ITT: People pissed off at a very early initial v1.0 release of software.

Honestly, it’s a huge step in the right direction. If MS starts including feature function everyone has complained about in this thread, it won’t be that bad. They probably open sourced it to start getting more developers to commit ideas and code, make it better, and design and develop it the way the community wants.

1

u/istarian May 20 '20

They probably open sourced it to start getting more developers to commit ideas and code, make it better, and design and develop it the way the community wants.

None of that requires open sourcing anything. And unless it can be used with some other system or edited and recompiled to be the way someone else wants it, then it would just be posturing in the end.

2

u/[deleted] May 19 '20

Oh sweet baby Jesus, yes!

2

u/Where_Do_I_Fit_In May 19 '20

Fucking finally. If they continue to adopt Linux features. Windows might become at least a usable (less frustrating) piece of software down the line. I almost feel like it is too late though with all the legacy third-party installers that have to be accommodated. Idk at the very least it's another move in the right direction.

1

u/chutiyabehenchod May 19 '20

who actually uses windows over linux for development?

7

u/schlenk May 19 '20

Game developers?

6

u/enbacode May 19 '20

Reverse Engineers, Game Developers, people who like to play games but don't want to struggle with dual boot, people who rely on Adobe/MS Office software, people who develop for win-specific software (think SAP or similar), people who write .net, people who are used to and/or like windows

There's more than just web dev

→ More replies (4)

7

u/emperor000 May 20 '20

A lot of people...? What a snide pretentious comment.

3

u/broknbottle May 19 '20

Janice my secretary, I can’t wait to see her bust out emacs and modify a perl script to scrape our competitors facebook

1

u/Bjartensen May 19 '20

This really is the one killer feature that I think Linux had over Windows. I cringe thinking about when I used to uncritically google my way to a website to download an .exe file. I have seen many times people end up on weird unofficial websites to get the file.

1

u/[deleted] May 19 '20

Will this help Sys Admins?

1

u/SurelyNotAnOctopus May 19 '20

Does that mean standardized / preinstalled libraries? Oh boy

1

u/[deleted] May 20 '20

A terminal that actually works and a package manager? It's taking them a while, but they're slowly dragging Windows out of the dark ages and making it useful for developers.

1

u/[deleted] May 20 '20

Didn't Windows Store update software ?

1

u/Lucarai May 20 '20

WSL2 going public/main update branch this month too, SICK

1

u/bombastica May 20 '20

Nice. I love homebrew on macOS. This is a big feature win for Windows.

1

u/EarLil May 20 '20

would really wish that microsoft store worked without login in... maybe installing this app will be enough to overcome that restriction

1

u/[deleted] May 20 '20

So more stuff that Linux has enjoyed for years finally comes to Windows.

1

u/bowmanpete123 May 20 '20

It's a weird hunch windows is becoming more and more like the tech company version of that boomer uncle that's like "Hey kids, I can shizzle with you groovy young ones."

1

u/[deleted] May 20 '20

Thanks to Linux again and again (30 years later)

1

u/schlenk May 20 '20

you have a time machine obviously, Linux is only 29 years old...

→ More replies (1)

1

u/germandiago May 20 '20

Finally! apt in Linux! Very handy.

1

u/sephirothbahamut May 20 '20

How long would it take to simply let traditional programs in the app store so third parties can simply make their installers available there, and later give the store package manager capabilities (shifting updates to the store rather than individual programs etcc)?

1

u/JJakk10 May 20 '20

Why would you need that when you can just use WSL

1

u/emdeka87 May 20 '20

Chocolately worked just fine. No need to fucking reinvent the wheel

1

u/bundt_chi May 20 '20

I'm glad they're finally doing this but I recently discovered scoop.sh and I really like it a lot. One of the biggest things that turned me on to it over chocolatey is how transparent the repository maintenance and configuration is (managed as json files in "buckets" in a github repo).

I often work in an environment that's pretty locked down and the ability to quickly setup a custom software repo (bucket) that's all allowed SW and their versions was one of the biggest features.

I hope MS allows for locally hosted package repos and an as transparent and easy to use system...

1

u/not_perfect_yet May 20 '20

Why not contribute to another open source package manager?

We looked at several other package managers. There were several reasons leading us to create a new solution. One critical concern we had was how to build a repository of trusted applications. We are automatically checking each manifest. We leverage SmartScreen, static analysis, SHA256 hash validation and a few other processes to reduce the likelihood of malicious software making its way into the repository and onto your machine. Another key challenge was all the changes required to be able to deliver the client program as a native Windows application.

I really hate how software companies get away with lies like this.

They didn't want to. Simple as that.

Linux package managers are secure. If Microsoft wants features like static analysis to be included in the package somehow, I'm sure there is way to integrate that into existing system.

It's ok to not want to directly build for your competition. Just admit it. Even if it's just "We did a cost benefit analysis and interacting with the community to collaborate on this didn't meet our requirements".

But I am so tired of the bullshitting. "hurr durr durr, can't be done" "we love open source".

Probably big news though, even if I don't like the way it's presented.

1

u/tgejesse May 20 '20

Long overdue

1

u/tgejesse May 20 '20

I wonder when this will be native

1

u/shawntco May 20 '20

Reading the comments, it makes me think they simply announced this too soon. Surely they knew devs would rip them a new one for its incomplete nature. I can excuse them a little since it's called a Preview, but saying "You can start using it today!" is disingenuous.

1

u/panorambo May 20 '20

Anyone knows if this package manager can use the AppX package format, or MSI, or both, or neither?

1

u/hoppi_ May 27 '20

This is not as awesome and super great as people seem to think. There is something interesting in the sysadmin sub about the implications and consequences. More here: https://www.reddit.com/r/sysadmin/comments/gmrwxi/windows_package_manager_wingetexe/fr6b7wi/

1

u/TheRexedS May 19 '20

Can anyone explain to me what advantages does this have over downloading an app from the Microsoft Store (Microsoft Store takes care of automatic downloads as well).

2

u/stronghup May 19 '20

The benefits are not for the person doing the downloading. They are more for the software publisher. MS Store is for commercial applications while WPM seems to be more targeted at open-source publishers. You can sell your apps on MS Store, but I assume there is no payments functionality in the WPM.

Well you could say the benefit for the down-loader is that now you can (safely) download and install Windows Open Sources apps which are not in the MS Store.

2

u/broknbottle May 19 '20

You don’t have to be exposed to advertisements for Minecraft when you already own it?

1

u/badpotato May 19 '20 edited May 20 '20

Now if they could just provide an up-to-date version of Windows for Vagrant without license so we can install a Windows VM from our Linux OS, so people don't need to reload a snapshot every so often when the license is out-to-date, just to run their corporate Windows-only app to get their token for authentication, etc. That would be nice.

1

u/galtthedestroyer May 20 '20

That's rough that you don't have a phone app or a hard token.

1

u/port53 May 20 '20

Just in time for everyone else to move away from managed packages and on to big blobs of self-contained code and data that can be deployed rapidly on any platform, regardless of base os or even architecture.

1

u/sucuk May 20 '20

Please Microsoft, we're so tired of winning