-
Notifications
You must be signed in to change notification settings - Fork 993
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
[feature] Ability to specify a profile to match during conan upload
#6647
Comments
Hi @LBHawk There is a problem with this proposal. The problem with a profile is that it is used to fully expand the dependency graph. It needs a "consumer" root package to be able to build the dependency graph, which might not be the one that is being created. The way to go for this feature is to try to simplify the package ID return from the |
Thanks for the explanation @memsharded. I actually forgot about the json output when I created this issue. Is this the recommended approach? Parsing output files to pass along to other commands generally scares me, in case of some change to the output in the future :). Can we expect output files like these to follow the non-breaking policy? |
Yes, we have tried hard to not break them. I also understand the concerns of parsing json on the command line, if using any other language (python, groovy/java), it is very straightforward, for command line, maybe something like https://stedolan.github.io/jq/ (but yes, more scary), but yes, I think this will be the recommended approach right now. Also this seems that it will be what we will try to improve, to simplify access. Another idea that we considered in the past is to make the @czoido I think this issue can be considered for the new command line design, together with the ideas of #5744 |
For the problem of conan create app --format=json > graph.json
conan list --graph=graph.json --format=json > pkglist.json
conan upload --list=pkglist.json -r=default This will be way more effective than trying to use profiles as inputs (that won't work, because it is not possible to map from profiles -> package_ids without a full evaluation of a dependency graph), so closing this ticket as resolved. Don't hesitate to create new tickets for any further question, thanks! |
You can currently use
--query QUERY
during aconan upload
to only upload packages matching the specified settings. This is quite useful, but it would be nice to expand on this functionality to allow you to specify a profile to match, rather than having to write out a query.We have run into a couple of cases where it would be helpful to be able to structure package creation and upload as
While this is possible by instead specifying the package ID in the upload, this is not so straightforward in an automated build. This is also possible with the existing
--query
flag but this is not so nice to use when needing to write out every setting in a given profile.The text was updated successfully, but these errors were encountered: