File tree Expand file tree Collapse file tree 1 file changed +14
-7
lines changed Expand file tree Collapse file tree 1 file changed +14
-7
lines changed Original file line number Diff line number Diff line change @@ -53,17 +53,24 @@ export async function backupExistingFolders() {
53
53
}
54
54
55
55
export async function downloadExistingDocsToLocal ( ) {
56
- // For parallel downloads
57
- return await Promise . all ( [
58
- /* executeS3Sync({
59
- from: `${apiDocsBucketUrl}/json-docs`,
60
- to: 'tmp/json-docs',
61
- }), */
56
+ const promises = [
62
57
executeS3Sync ( {
63
58
from : `${ apiDocsBucketUrl } /rev-index` ,
64
59
to : 'tmp/rev-index' ,
65
60
} ) ,
66
- ] )
61
+ ]
62
+
63
+ if ( process . env . AWS_SHOULD_PUBLISH === 'yes' ) {
64
+ promises . push (
65
+ executeS3Sync ( {
66
+ from : `${ apiDocsBucketUrl } /json-docs` ,
67
+ to : 'tmp/json-docs' ,
68
+ } )
69
+ )
70
+ }
71
+
72
+ // For parallel downloads
73
+ return await Promise . all ( promises )
67
74
}
68
75
69
76
export async function uploadDocsToS3 ( ) {
You can’t perform that action at this time.
0 commit comments