NBISweden / sda-cli

User command line interface for the SDA
GNU Affero General Public License v3.0
5 stars 1 forks source link

[list] returns filepaths and dataset size of a dataset #433

Closed aaperis closed 2 months ago

aaperis commented 3 months ago

As a user I want to list the files in a dataset for which I have access to and the files therein and their sizes using the cli tool so that I can plan how to proceed with downloading files.

Description:

Finish the A/C from #388 that were not implemented in #415, i.e. filepaths should be returned instead of filenames so that they can used with ./sda-cli download and dataset size should be returned so that the user knows what to expect if the whole dataset is to be downloaded.

A/C;

Example output

$ sda-cli list [...]
<some metadata>
FileID          Size     Path
ieNgoothoo6e    261kb    dirA/fileA.bam
Vuh8Oochepah    220mb    dirA/fileB.bam
ol5Ir7aeKaiC     64kb    dirA/fileC.bam
en9Voo7Uuch5    230mb    dirA/fileD.bam
Gohxah4yuqu3     46gb    dirA/dirB/fileE.bam
johg4aiGiu0i    362kb    dirA/dirB/fileF.bam
iej1Hoh3eDai    171mb    dirA/dirC/fileG.bam
ahch5iechohT    171mb    dirA/dirC/fileI.bam
eeFooSoh2doo     24gb    dirA/dirC/fileJ.bam
vui9Ahdah5Ru    378tb    dirA/dirC/fileK.bam