Re: [BuildStream] Proposal: Allowing download-only sources to work on local files
- From: tristan maat codethink co uk (Tristan Daniël Maat)
- To: tom mewett codethink co uk
- Cc: buildstream-list gnome org
- Subject: Re: [BuildStream] Proposal: Allowing download-only sources to work on local files
- Date: Fri, 06 Dec 2019 11:18:26 +0000
Hi,
Being picky, I would personally try to avoid having two
mutually-exclusive keys for the same thing; perhaps the proposed single
'url' key could be named something less confusing (I'd choose
'location' but that's already taken; 'from' ?) and there could be a
'local:' scheme for use with local files. That might be an uglier
change, however.
- kind: zip
from: local:files/some-archive.zip
My main problem with this is that it will cause a fair bit of churn on
the project end; I realize we're definitely not backwards compatible,
and hence this is less important of a point, but I don't think we'd need
to change the key. Sticking with `url` is probably fine, it's still a
resource locator.
My second point is that this is a non-standard extension of URI. I
wanted to deliberately avoid that, because it's not a particularly nice
thing to do; especially because URIs are by definition expected to point
to an absolute location.
If we do use this proposal, I'd prefer a `bst-project:` scheme - but I'd
be happier with my own proposal from whenever ago [1], which is to
introduce a %{project} variable that would allow users to use:
- kind: zip
url: file://%{project}/files/some-archive.zip
This is a little less succinct, but it doesn't bend URI standards and
feels a bit less magic.
Regards,
Tristan
[1]: https://gitlab.com/BuildStream/buildstream/issues/388
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]