File tree Expand file tree Collapse file tree 1 file changed +1
-23
lines changed
Expand file tree Collapse file tree 1 file changed +1
-23
lines changed Original file line number Diff line number Diff line change @@ -327,29 +327,7 @@ impl BuildRecall for ApiClient {
327327 . context ( "Failed to pull the artifact from S3" ) ?;
328328
329329 let mut a = tar:: Archive :: new ( resp) ;
330-
331- for entry in a
332- . entries ( )
333- . context ( "Failed to list entries of tar archive" ) ?
334- {
335- let mut file = entry. context ( "Can't process an entry of tar archive" ) ?;
336-
337- let mut buf = Vec :: new ( ) ;
338- file. read_to_end ( & mut buf) ?;
339-
340- let path = file
341- . header ( )
342- . path ( )
343- . context ( "Failed to parse path of archived file" ) ?
344- . clone ( ) ;
345-
346- if let Some ( parent) = path. parent ( ) {
347- fs:: create_dir_all ( parent)
348- . context ( format ! ( "Failed to create directory {:?}" , parent) ) ?;
349- }
350- fs:: write ( path. clone ( ) , buf)
351- . context ( format ! ( "Failed to write to file at {:?}" , path) ) ?;
352- }
330+ a. unpack ( "." ) ?;
353331
354332 Ok ( true )
355333 } )
You can’t perform that action at this time.
0 commit comments