Fetch missing blobs on demand

Background

Another follow up to #832 (closed) (closed) as brought up here, in cases where we haven't fetched the file blobs for objects, we want to ensure they are fetched or present the user with the option to fetch them when running commands like shell and checkout. I think it makes sense to have a --pull option to artifact checkout and shell, as the source checkout command does with --fetch, and ensure that this also fetches file blobs when only directory trees are local. If this isn't specified and file blobs aren't present an appropriate warning should be given to the user.

Similar to #1043 (closed) this should also work for source checkout and directory trees there.

Task description

  • Add fetch option to bst artifact checkout command
  • Change Element._pull to fetch file blobs for a directory tree.
  • Change Element._fetch and Source._fetch similarly.

Acceptance Criteria

Additional tests for fetching file blobs for a artifact checkout and shell commands.


Edited by Raoul Hidalgo Charman