Skip to content

Commit

Permalink
Easy script to update closure and typescript typings (#5026)
Browse files Browse the repository at this point in the history
  • Loading branch information
dfreedm authored Jan 9, 2018
1 parent 883bb05 commit 60e7121
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ before_script:
- npm install -g bower gulp-cli@1
- bower install
- gulp lint-eslint
- gulp generate-externs
- gulp generate-typescript
- gulp update-types
- git diff --exit-code
script:
- xvfb-run wct -l chrome
Expand Down
4 changes: 4 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,10 @@ gulp.task('lint', (done) => {
runseq('lint-eslint', 'lint-closure', done);
});

gulp.task('update-types', (done) => {
runseq('generate-externs', 'generate-typescript', done);
});

gulp.task('generate-externs', ['clean'], async () => {
let genClosure = require('@polymer/gen-closure-declarations').generateDeclarations;
const declarations = await genClosure();
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@
"build": "gulp",
"test": "npm run lint && wct",
"lint": "gulp lint",
"version": "gulp update-version && git add lib/utils/boot.html"
"version": "gulp update-version && git add lib/utils/boot.html",
"update-types": "gulp update-types"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit 60e7121

Please sign in to comment.