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

[Update Request]: OCaml.opam including Git.Git in PackageDependencies #170902

Open
dra27 opened this issue Aug 31, 2024 · 2 comments
Open

[Update Request]: OCaml.opam including Git.Git in PackageDependencies #170902

dra27 opened this issue Aug 31, 2024 · 2 comments
Labels
Help-Wanted This is a good candidate work item from the community. Package-Metadata

Comments

@dra27
Copy link
Contributor

dra27 commented Aug 31, 2024

What type of update are you requesting?

A change to the package metadata

Current Package Identifier

OCaml.opam

Package Version

2.2.1

Please describe the changes you would like to see

The OCaml.opam package installs OCaml's package manager, opam.

The first command which must be run to use opam is opam init which will strongly recommend that the user installs Git for Windows and recommends winget install Git.Git as a way to do this. It will recommend this even if an alternate Git implementation (such as Cygwin's) is found and the official advice on the OCaml website recommends install the Git.Git winget package (cf. update in ocaml/ocaml.org#2658).

Would it be acceptable for Git.Git to be added to the experimental PackageDependencies field, so that winget install OCaml.opam automatically installs Git-for-Windows, rather than continuing to guide users to have to enter winget install Git.Git OCaml.opam?

@dra27 dra27 added Help-Wanted This is a good candidate work item from the community. Package-Update This package needs to be updated labels Aug 31, 2024
@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Triage This work item needs to be triaged by a member of the core team. Package-Metadata and removed Package-Update This package needs to be updated labels Aug 31, 2024
@mdanish-kh
Copy link
Contributor

mdanish-kh commented Aug 31, 2024

If that's the official advice for the best possible experience for a user installing the app, then i am inclined to say yes.

I'm a little worried about the semantics because PackageDependencies say to me - "these are the set of packages that must be present prior to package installation, otherwise the package installation will fail or package won't function correctly". This case sounds more - "it would be really helpful to have this package, but it isn't mandatory for installation or using the package". It would help if we could understand more the relation of the package with Git.Git, is a major feature not going to be available if they don't have Git? @denelon What would be your thoughts?

An alternate could be to use InstallationNotes in the manifest for guiding users for next steps post-installation. I see we already have it in the latest opam manifest, we could add a line "The publisher strongly recommends that you install Git-for-Windows. If you don't have it installed, use 'winget install Git.Git'"

experimental PackageDependencies field

Side note: They aren't experimental anymore, must be a case of outdated docs somewhere. Could you point to where you read about it? :D

@microsoft-github-policy-service microsoft-github-policy-service bot removed the Needs-Triage This work item needs to be triaged by a member of the core team. label Aug 31, 2024
@dra27
Copy link
Contributor Author

dra27 commented Aug 31, 2024

I agree that PackageDependencies isn't the ideal fit - Debian, for example, put it in Recommends (cf. https://packages.debian.org/trixie/opam).

opam init will proceed without forcing the installation of Git for Windows, although it will subsequently install either Cygwin or MSYS2's build of Git (which may then cause subsequent problems, e.g. for users accessing Git remotes using domain certs, etc. as that build of Git uses openssl rather than schannel).

It's definitely not "the package won't function correctly without Git.Git" but more "some users may encounter issues they wouldn't otherwise have done had they installed Git.Git". Expert users are able to configure opam to use whichever git binary they wish (and, indeed, expert users can probably use the PowerShell installation script from opam's GitHub repo too!)

experimental PackageDependencies field

Side note: They aren't experimental anymore, must be a case of outdated docs somewhere. Could you point to where you read about it? :D

Dependencies: # *Experimental* list of dependencies required by the package
- ExternalDependencies: # *Not implemented* list of external dependencies
PackageDependencies: # *Experimental* list of package dependencies
WindowsFeatures: # *Not implemented* list of Windows feature dependencies
WindowsLibraries: # *Not implemented* list of Windows library dependencies

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Help-Wanted This is a good candidate work item from the community. Package-Metadata
Projects
None yet
Development

No branches or pull requests

2 participants