Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide a standardized method of installation on Windows. #4291

Open
RokeJulianLockhart opened this issue Jan 22, 2023 · 17 comments
Open

Provide a standardized method of installation on Windows. #4291

RokeJulianLockhart opened this issue Jan 22, 2023 · 17 comments

Comments

@RokeJulianLockhart
Copy link

RokeJulianLockhart commented Jan 22, 2023

Providing an installer (ideally with a basic updater) would significantly lessen the burden of evaluating new releases. Currently, .deb releases are provided, so these tools are certainly ready for installation.

The .msix, .appx, .msi, and mere .exe formats (.msix being the most desirable) are viable alternatives to the current .zip packaging. However, if maintenance of such an installer is undesirable, perhaps submitting the zip files (since this microsoft/winget-cli#140 is complete) to the official Windows Package Manager, (winget's) repository (per https://github.com/microsoft/winget-pkgs/blob/4c9bd7f275225fa97db5300e86c2b22d2be9c720/README.md#submitting-a-package) is superior?

@YDX-2147483647
Copy link
Contributor

YDX-2147483647 commented Jan 22, 2023

Note: Before winget, we can use scoop as mentioned in the documentation.

@RokeJulianLockhart
Copy link
Author

@YDX-2147483647, indeed! Apologies. I suppose that I should refile this as separate issues requesting submission to winget and MSIX support.

Is either proposition something that the development team is willing to tackle? I solely ask so that I don't waste time submitting a proposition that is of no interest.

Thanks!

@tertsdiepraam
Copy link
Member

tertsdiepraam commented Jan 22, 2023

I like both suggestions. Maybe we could have some publish CI that pushes a release to the winget repo. However, this requires some thought about how much we want to take on. Most uutils packages for the package managers in the documentation are managed by third-parties, so we don't really have to maintain them ourselves.

MSIX sounds good as long as we can automate it.

mere .exe formats

Note that the .zip is just .exe + README.md + LICENSE. So providing the exe separately does not provide much benefit.

Edit: I'm also not on Windows so I can't do most of this, but I'd be happy to accept PRs.

@tertsdiepraam
Copy link
Member

This is also related to #2758

@RokeJulianLockhart
Copy link
Author

@tertsdiepraam, it's definitely relevant, since uploading a package to the Microsoft Store would also allow users to use winget to install this via the commandline, via the msstore repository that it exposes.

@YDX-2147483647
Copy link
Contributor

YDX-2147483647 commented Nov 15, 2023

I research it today. More work is needed, but let's do it step by step.

  • ZIP is fine

    Installer File Manifest Schema v1.5.0 accepts arbitrary archive format, and YamlCreate.ps1 can generate manifests by asking a few questions.

    It's not necessary to submit MSIX.

  • Publish CI is needed

    It looks like that winget can't automatically update manifests like scoop. It's our reponsibility to push/submit new versions. (More research needed)

Questions

  • Name of this project?

    coreutils (as the repo name), uutils coreutils (as in the website and the scoop app), or rust coreutils (as in releases)?

    Both an ID (e.g. WindowsTerminal, case sensitive) and a full name (e.g. Windows Terminal) is needed.

  • Publisher name?

    Is the following OK?

    • Publisher ID: uutils
    • Full publisher name: The uutils project
    • Author: The uutils project contributors
    • Copyright: Copyright (c) Jordi Boggiano and many others (as in LICENSE)
  • Locale?

    Microsoft specifies many locales IDs, should we choose en-US, en-GB, or Australia, Canada, etc.?

Current work (others can start here)

The following files should be put under https://github.com/microsoft/winget-pkgs/tree/master/manifests/u/ uutils/coreutils/0.0.23/.

uutils.coreutils.yaml
# Created with YamlCreate.ps1 v2.2.10 $debug=MDSU.CRLF.7-3-9.Win32NT
# yaml-language-server: $schema=https://aka.ms/winget-manifest.version.1.5.0.schema.json

PackageIdentifier: uutils.coreutils
PackageVersion: 0.0.23
DefaultLocale: en-US
ManifestType: version
ManifestVersion: 1.5.0
uutils.coreutils.installer.yaml
# Created with YamlCreate.ps1 v2.2.10 $debug=MDSU.CRLF.7-3-9.Win32NT
# yaml-language-server: $schema=https://aka.ms/winget-manifest.installer.1.5.0.schema.json

PackageIdentifier: uutils.coreutils
PackageVersion: 0.0.23
InstallerLocale: en-US
InstallerType: zip
InstallModes:
- silent
Installers:
- Architecture: x64
  NestedInstallerType: portable
  NestedInstallerFiles:
  - RelativeFilePath: coreutils-0.0.23-x86_64-pc-windows-msvc\coreutils.exe
  InstallerUrl: https://github.com/uutils/coreutils/releases/download/0.0.23/coreutils-0.0.23-x86_64-pc-windows-msvc.zip
  InstallerSha256: 6A09488F926F1462E6D80070473580B194534C3DD7E38E15DC6C4733DA46252E
ManifestType: installer
ManifestVersion: 1.5.0
uutils.coreutils.locale.en-US.yaml
# Created with YamlCreate.ps1 v2.2.10 $debug=MDSU.CRLF.7-3-9.Win32NT
# yaml-language-server: $schema=https://aka.ms/winget-manifest.defaultLocale.1.5.0.schema.json

PackageIdentifier: uutils.coreutils
PackageVersion: 0.0.23
PackageLocale: en-US
Publisher: The uutils project
PublisherUrl: https://uutils.github.io
PublisherSupportUrl: https://github.com/uutils/coreutils/issues
# PrivacyUrl:
Author: The uutils project contributors
PackageName: uutils coreutils
PackageUrl: https://uutils.github.io/coreutils/
License: MIT
LicenseUrl: https://github.com/uutils/coreutils/blob/main/LICENSE
Copyright: Copyright (c) Jordi Boggiano and many others
CopyrightUrl: https://github.com/uutils/coreutils/blob/main/LICENSE
ShortDescription: Cross-platform Rust rewrite of the GNU coreutils
Description: |
  uutils coreutils is a cross-platform reimplementation of the GNU coreutils in Rust. While all programs have been implemented, some options might be missing or different behavior might be experienced.

  uutils aims to be a drop-in replacement for the GNU utils. Differences with GNU are treated as bugs.

  uutils aims to work on as many platforms as possible, to be able to use the same utils on Linux, Mac, Windows and other platforms. This ensures, for example, that scripts can be easily transferred between platforms.

  Please see https://uutils.github.io/coreutils/book/ for user manual
Moniker: coreutils
Tags:
- busybox
- command-line-tool
- coreutils
- cross-platform
- gnu-coreutils
- rust
# ReleaseNotes:
ReleaseNotesUrl: https://github.com/uutils/coreutils/releases/tag/0.0.23
# PurchaseUrl:
# InstallationNotes:
Documentations:
- DocumentLabel: User Manual
  DocumentUrl: https://uutils.github.io/coreutils/book/
ManifestType: defaultLocale
ManifestVersion: 1.5.0

Next step: Submitting a Package / Author a manifest / Validation.

> gh repo clone microsoft/winget-pkgs && gh fork
> .\Tools\YamlCreate.ps1 -PackageIdentifier uutils.coreutils -PackageVersion 0.0.23 -Mode 3 # 3 = Edit metadata
# Just press Enter and Enter and Enter…
# The script will validate manifests at the end.

@sylvestre
Copy link
Sponsor Contributor

please call the project uutils-coreutils or rust-coreutils like the other projects:
https://github.com/uutils/coreutils/blob/main/docs/src/installation.md

@sylvestre
Copy link
Sponsor Contributor

locale is currently en-us

@sylvestre
Copy link
Sponsor Contributor

Copyright: should be
Copyright (c) uutils developers

@YDX-2147483647
Copy link
Contributor

Yes we can submit once the maintainer agrees on the manifests.

And we should set up a CI if we don't want to calculate SHA256 and submit manually in the future…

@RokeJulianLockhart

This comment was marked as outdated.

@RokeJulianLockhart
Copy link
Author

RokeJulianLockhart commented Nov 15, 2023

#4291 (comment)

I've filed microsoft/winget-pkgs#126833 (comment). Please provide feedback over there.

@tertsdiepraam
Copy link
Member

please call the project uutils-coreutils or rust-coreutils like the other projects:

By the way, I prefer uutils-coreutils since I think that's a bit more specific, but yeah, both are fine.

@RokeJulianLockhart

This comment was marked as duplicate.

@Dragon1573
Copy link

📢 Notes

This package is submitted to microsoft/winget-pkgs and available in winget.exe, users can easily install this package with winget install uutils.coreutils.

@tertsdiepraam
Copy link
Member

I've just put up a PR to document that: #5648

I still think there's something we could do for this issue: use cargo-dist. That should be able to make an msi for us. And in the future it might even do more, taking away some of the maintenance work people are doing for us in all the various repositories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants