Hi Frazer, On Sat, Jul 4, 2020 at 6:19 PM Frazer Clews <[email protected]> wrote:
> This is a proposal for `bst source show` > > The idea is to show the sources in a BuildStream project > > I think a normal `bst source show` should display the sources, along > with their directories/URLs > > `bst source show` > > ``` > > local: <example/dir> > > git: <git_url> > > https: <https_url> > > ``` > Can you expand the above a bit more? What will `bst source show` actually show? All the sources for all elements? Will we be able to see which source belongs to which element, or should one run `bst source show ELEMENT` for that? > Further goals would be to have certain flags to show only the > directory/URL or the protocols in use > > `bst source show -p|--protocol`? > > ``` > > local > > git > > https > > ``` > This seems very specific. I'm a bit concerned we are catering for a very specific use case, and given that we are dealing with URLs here, for which a wide spectrum of tools is available to parse them, I don't know if this is the best thing to do. That is, I don't really want us to have a --protocol option to maintain. `bst source show -u|--url`? > > ``` > > <example/dir> > > <git_url> > > <https_url> > > ``` > > Or one that only show a certain protocol, for example only git sources > > `bst source show -g|--git` > > ``` > > <git_url> > > ``` > Let's get this into a full proposal? I'd like to see the flags you propose and what this will mean for the UI/UX, so that we can come up with something consistent and intuitive. This should likely look a lot like what we do for artifacts. > Finally and not sure if this should be the default or one with flags, > but one that shows the file names as headings, similar to `git grep > --break --heading` > > `bst source show -f|--file-name`? > > ``` > > hello.bst > > local: <example/dir> > > git: <git_url> > > https: <https_url> > > ``` > I certainly think that having sources be associated with elements is useful. > Open to suggestions/improvements to start work on `bst source show`, > could also use arguements from `bst source fetch` which work well during > testing > Also please take into account https://gitlab.com/BuildStream/buildstream/-/issues/1273 and https://gitlab.com/BuildStream/buildstream/-/issues/1274 as well. HTH. Thanks > > Frazer > Cheers, Sander
