Set up TypeScript compilation, and make a small start on converting the CLI

Change-Type: patch
This commit is contained in:
Tim Perry 2017-11-23 12:53:28 +01:00
parent 93d1e3a4a1
commit eb68bb1a1a
4 changed files with 20 additions and 2 deletions

1
.gitignore vendored
View File

@ -25,6 +25,7 @@ build/Release
node_modules
npm-shrinkwrap.json
package-lock.json
.resinconf
resinrc.yml

View File

@ -18,7 +18,7 @@
"resin": "./bin/resin"
},
"scripts": {
"build": "gulp coffee && npm run doc",
"build": "gulp coffee && tsc && npm run doc",
"ci": "npm run build && catch-uncommitted",
"doc": "mkdir -p doc/ && coffee extras/capitanodoc/index.coffee > doc/cli.markdown",
"watch": "gulp watch",
@ -42,7 +42,8 @@
"gulp-coffee": "^2.2.0",
"gulp-coffeelint": "^0.6.0",
"gulp-shell": "^0.5.2",
"require-npm4-to-publish": "^1.0.0"
"require-npm4-to-publish": "^1.0.0",
"typescript": "^2.5.3"
},
"dependencies": {
"@resin.io/valid-email": "^0.1.0",

16
tsconfig.json Normal file
View File

@ -0,0 +1,16 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"outDir": "build",
"strict": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"preserveConstEnums": true,
"removeComments": true,
"sourceMap": true
},
"include": [
"./lib/**/*.ts"
]
}