@google-cloud/storage
Advanced tools
Comparing version 7.11.3 to 7.12.0
@@ -21,2 +21,3 @@ /*! | ||
concurrencyLimit?: number; | ||
customDestinationBuilder?(path: string, options: UploadManyFilesOptions): string; | ||
skipIfExists?: boolean; | ||
@@ -86,2 +87,4 @@ prefix?: string; | ||
* to use when uploading the files. | ||
* @property {Function} [customDestinationBuilder] A fuction that will take the current path of a local file | ||
* and return a string representing a custom path to be used to upload the file to GCS. | ||
* @property {boolean} [skipIfExists] Do not upload the file if it already exists in | ||
@@ -88,0 +91,0 @@ * the bucket. This will set the precondition ifGenerationMatch = 0. |
@@ -319,2 +319,4 @@ "use strict"; | ||
* to use when uploading the files. | ||
* @property {Function} [customDestinationBuilder] A fuction that will take the current path of a local file | ||
* and return a string representing a custom path to be used to upload the file to GCS. | ||
* @property {boolean} [skipIfExists] Do not upload the file if it already exists in | ||
@@ -389,5 +391,5 @@ * the bucket. This will set the precondition ifGenerationMatch = 0. | ||
}; | ||
passThroughOptionsCopy.destination = filePath | ||
.split(path.sep) | ||
.join(path.posix.sep); | ||
passThroughOptionsCopy.destination = options.customDestinationBuilder | ||
? options.customDestinationBuilder(filePath, options) | ||
: filePath.split(path.sep).join(path.posix.sep); | ||
if (options.prefix) { | ||
@@ -394,0 +396,0 @@ passThroughOptionsCopy.destination = path.posix.join(...options.prefix.split(path.sep), passThroughOptionsCopy.destination); |
@@ -21,2 +21,3 @@ /*! | ||
concurrencyLimit?: number; | ||
customDestinationBuilder?(path: string, options: UploadManyFilesOptions): string; | ||
skipIfExists?: boolean; | ||
@@ -86,2 +87,4 @@ prefix?: string; | ||
* to use when uploading the files. | ||
* @property {Function} [customDestinationBuilder] A fuction that will take the current path of a local file | ||
* and return a string representing a custom path to be used to upload the file to GCS. | ||
* @property {boolean} [skipIfExists] Do not upload the file if it already exists in | ||
@@ -88,0 +91,0 @@ * the bucket. This will set the precondition ifGenerationMatch = 0. |
@@ -289,2 +289,4 @@ /*! | ||
* to use when uploading the files. | ||
* @property {Function} [customDestinationBuilder] A fuction that will take the current path of a local file | ||
* and return a string representing a custom path to be used to upload the file to GCS. | ||
* @property {boolean} [skipIfExists] Do not upload the file if it already exists in | ||
@@ -359,5 +361,5 @@ * the bucket. This will set the precondition ifGenerationMatch = 0. | ||
}; | ||
passThroughOptionsCopy.destination = filePath | ||
.split(path.sep) | ||
.join(path.posix.sep); | ||
passThroughOptionsCopy.destination = options.customDestinationBuilder | ||
? options.customDestinationBuilder(filePath, options) | ||
: filePath.split(path.sep).join(path.posix.sep); | ||
if (options.prefix) { | ||
@@ -364,0 +366,0 @@ passThroughOptionsCopy.destination = path.posix.join(...options.prefix.split(path.sep), passThroughOptionsCopy.destination); |
{ | ||
"name": "@google-cloud/storage", | ||
"description": "Cloud Storage Client Library for Node.js", | ||
"version": "7.11.3", | ||
"version": "7.12.0", | ||
"license": "Apache-2.0", | ||
@@ -6,0 +6,0 @@ "author": "Google Inc.", |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1669456
36651