-
Notifications
You must be signed in to change notification settings - Fork 698
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
Support subdirectories with remote tarball deps in cabal.project #7821
Comments
Out of curiosity, why not simply point at the forked repo instead? |
✨ This is an old work account. Please reference @brandonchinn178 for all future communication ✨ Because after the PR is merged, the author is free to delete the forked repo. I know for myself, I always delete the forked repo after my PR is merged |
You can say |
✨ This is an old work account. Please reference @brandonchinn178 for all future communication ✨ Would that do the equivalent of |
URL packages are not local packages, so e.g. |
✨ This is an old work account. Please reference @brandonchinn178 for all future communication ✨ makes sense. so conceptually speaking, why add a And there's still no way to specify a subdirectory within a tarball using this |
Yes, that would make sense (though wiring things might be painful with current project file handling code).
No. Nobody needed it. (For example I |
✨ This is an old work account. Please reference @brandonchinn178 for all future communication ✨ Ok, so I did confirm this works, unless I need to access a subdirectory, so I'll update the issue to be specifically about supporting subdirs for remote tarballs. |
✨ This is an old work account. Please reference @brandonchinn178 for all future communication ✨
Ah so this doesn't quite work with GitHub's archiving then. It would be nice if there could be some way of doing:
|
Sounds sensible. Any volunteers for any part? |
This would be useful to workaround full cloning large repos like Amazonka that don't yet have a hackage release such as this stack user did. |
Related to: #2189
Currently, one can add
to use a git repo to download a project to use as a dependency. I would like to explicitly specify a URL to a tarball that can be unzipped and used.
This is useful because when making a PR from a forked repo, GitHub adds the commit to the original repo's set of commits. For example, if I fork
user1/my-repo
touser2/my-repo
, add commit A to theuser2/my-repo
fork, and make a PR, GitHub allows downloading the commit fromhttps://github.com/user1/my-repo/archive/A.tar.gz
. However, cloning the originaluser1/my-repo
repo and doinggit checkout A
does not work.One could workaround this with
which works in most use-cases, but doesn't work if the Cabal project is within a subdirectory of the archive (e.g. a monorepo)
This is already supported in Stack: https://docs.haskellstack.org/en/stable/yaml_configuration/#extra-deps
The text was updated successfully, but these errors were encountered: