Skip to content

Commit

Permalink
feat: typescript conversion on video-intelligence (#375)
Browse files Browse the repository at this point in the history
* Remove .js files and add .ts files

* update package.json, jsdoc.js files
  • Loading branch information
summer-ji-eng committed Mar 9, 2020
1 parent 05252e0 commit 1f69d42
Show file tree
Hide file tree
Showing 70 changed files with 2,111 additions and 8,646 deletions.
5 changes: 3 additions & 2 deletions packages/google-cloud-videointelligence/.gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
**/*.log
**/node_modules
.coverage
coverage
.nyc_output
docs/
out/
build/
system-test/secrets.js
system-test/*key.json
*.lock
.DS_Store
package-lock.json
.vscode
__pycache__
*.code-workspace
8 changes: 6 additions & 2 deletions packages/google-cloud-videointelligence/.jsdoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//
// ** This file is automatically generated by gapic-generator-typescript. **
// ** https://github.com/googleapis/gapic-generator-typescript **
// ** All changes to this file may be overwritten. **

'use strict';

Expand All @@ -31,7 +34,8 @@ module.exports = {
source: {
excludePattern: '(^|\\/|\\\\)[._]',
include: [
'src'
'build/src',
'protos'
],
includePattern: '\\.js$'
},
Expand All @@ -42,7 +46,7 @@ module.exports = {
systemName: '@google-cloud/video-intelligence',
theme: 'lumen',
default: {
"outputSourceFiles": false
outputSourceFiles: false
}
},
markdown: {
Expand Down
48 changes: 29 additions & 19 deletions packages/google-cloud-videointelligence/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,10 @@
"node": ">=8.10.0"
},
"repository": "googleapis/nodejs-video-intelligence",
"main": "src/index.js",
"main": "build/src/index.js",
"files": [
"protos",
"src",
"AUTHORS",
"build/protos",
"build/src",
"LICENSE"
],
"keywords": [
Expand All @@ -30,31 +29,42 @@
],
"scripts": {
"docs": "jsdoc -c .jsdoc.js",
"lint": "eslint '**/*.js'",
"samples-test": "cd samples/ && npm link ../ && npm test && cd ../",
"system-test": "mocha system-test/*.js --timeout 600000",
"test": "c8 mocha",
"lint": "gts fix && eslint --fix samples/*.js",
"samples-test": "cd samples/ && npm link ../ && npm install && npm test && cd ../",
"system-test": "c8 mocha build/system-test --timeout 600000",
"test": "c8 mocha build/test",
"fix": "eslint --fix '**/*.js'",
"docs-test": "linkinator docs",
"predocs-test": "npm run docs",
"prelint": "cd samples; npm link ../; npm i"
"prelint": "cd samples; npm link ../; npm i",
"clean": "gts clean",
"compile": "tsc -p . && cp -r protos build/",
"compile-protos": "compileProtos src",
"prepare": "npm run compile"
},
"dependencies": {
"google-gax": "^1.7.5",
"protobufjs": "^6.8.8"
"google-gax": "^1.14.2"
},
"devDependencies": {
"codecov": "^3.4.0",
"@types/mocha": "^5.2.7",
"@types/node": "^12.12.29",
"c8": "^7.0.0",
"eslint": "^6.0.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-node": "^11.0.0",
"eslint-plugin-prettier": "^3.1.0",
"jsdoc": "^3.6.2",
"jsdoc-fresh": "^1.0.1",
"jsdoc-region-tag": "^1.0.2",
"linkinator": "^2.0.0",
"mocha": "^7.0.0",
"c8": "^7.0.0",
"prettier": "^1.17.1"
"gts": "^1.1.2",
"jsdoc": "^3.6.3",
"jsdoc-fresh": "^1.0.2",
"jsdoc-region-tag": "^1.0.4",
"linkinator": "^2.0.3",
"mocha": "^7.1.0",
"null-loader": "^3.0.0",
"pack-n-play": "^1.0.0-2",
"prettier": "^1.17.1",
"ts-loader": "^6.2.1",
"typescript": "^3.8.3",
"webpack": "^4.42.0",
"webpack-cli": "^3.3.11"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ message AnnotateVideoRequest {
// supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
// A video URI may include wildcards in `object-id`, and thus identify
// multiple videos. Supported wildcards: '*' to match 0 or more characters;
// '?' to match 1 character. If unset, the input video should be embedded
Expand All @@ -85,7 +85,7 @@ message AnnotateVideoRequest {
// URIs are supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
string output_uri = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. Cloud region where annotation should take place. Supported cloud
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ message AnnotateVideoRequest {
// supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For
// more information, see [Request URIs](/storage/docs/reference-uris). A video
// more information, see [Request URIs](https://cloud.google.com/storage/docs/request-endpoints). A video
// URI may include wildcards in `object-id`, and thus identify multiple
// videos. Supported wildcards: '*' to match 0 or more characters;
// '?' to match 1 character. If unset, the input video should be embedded
Expand All @@ -87,7 +87,7 @@ message AnnotateVideoRequest {
// URIs are supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For
// more information, see [Request URIs](/storage/docs/reference-uris).
// more information, see [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
string output_uri = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. Cloud region where annotation should take place. Supported cloud
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ message AnnotateVideoRequest {
// supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
// A video URI may include wildcards in `object-id`, and thus identify
// multiple videos. Supported wildcards: '*' to match 0 or more characters;
// '?' to match 1 character. If unset, the input video should be embedded
Expand All @@ -85,7 +85,7 @@ message AnnotateVideoRequest {
// URIs are supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
string output_uri = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. Cloud region where annotation should take place. Supported cloud
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ message AnnotateVideoRequest {
// supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
// A video URI may include wildcards in `object-id`, and thus identify
// multiple videos. Supported wildcards: '*' to match 0 or more characters;
// '?' to match 1 character. If unset, the input video should be embedded
Expand All @@ -85,7 +85,7 @@ message AnnotateVideoRequest {
// URIs are supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more information, see
// [Request URIs](/storage/docs/reference-uris).
// [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
string output_uri = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. Cloud region where annotation should take place. Supported cloud
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ message AnnotateVideoRequest {
// supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For
// more information, see [Request URIs](/storage/docs/reference-uris). A video
// more information, see [Request URIs](https://cloud.google.com/storage/docs/request-endpoints). A video
// URI may include wildcards in `object-id`, and thus identify multiple
// videos. Supported wildcards: '*' to match 0 or more characters;
// '?' to match 1 character. If unset, the input video should be embedded
Expand All @@ -99,7 +99,7 @@ message AnnotateVideoRequest {
// URIs are supported, which must be specified in the following format:
// `gs://bucket-id/object-id` (other URI formats return
// [google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For
// more information, see [Request URIs](/storage/docs/reference-uris).
// more information, see [Request URIs](https://cloud.google.com/storage/docs/request-endpoints).
string output_uri = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. Cloud region where annotation should take place. Supported cloud
Expand Down
146 changes: 0 additions & 146 deletions packages/google-cloud-videointelligence/src/index.js

This file was deleted.

Loading

0 comments on commit 1f69d42

Please sign in to comment.