-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Update to `tubo-gulp`: add support for typed lint rules, continuous deployment and simpler configuration. - Update dependencies - Update Typescript Closes #54
- Loading branch information
Showing
63 changed files
with
7,676 additions
and
3,530 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
# http://editorconfig.org | ||
|
||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 2 | ||
# This does break VS it causes BOM to be added to files: | ||
# https://developercommunity.visualstudio.com/content/problem/21744/vs2017-rc-breaks-the-encoding-of-my-files.html | ||
# charset = utf-8 | ||
trim_trailing_whitespace = true | ||
end_of_line = lf | ||
indent_brace_style = K&R | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
trim_trailing_whitespace = true | ||
max_line_length = 100 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
language: node_js | ||
|
||
notifications: | ||
email: | ||
on_success: never | ||
on_failure: change | ||
|
||
node_js: | ||
- stable | ||
|
||
before_install: | ||
- npm install -g typings gulp-cli npm typedoc | ||
before_script: | ||
- npm run prepare | ||
- npm install -g gulp-cli | ||
|
||
script: | ||
- npm test | ||
- ./travis-ci/deploy-gh-pages.sh | ||
- if [[ -n "${NPM_TOKEN}" ]]; then echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc && ./tools/continuous-deployment.travis.sh; fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
import * as buildTools from "turbo-gulp"; | ||
|
||
import * as gulp from "gulp"; | ||
import * as minimist from "minimist"; | ||
import { ParsedArgs } from "minimist"; | ||
|
||
interface Options { | ||
devDist?: string; | ||
} | ||
|
||
const options: Options & ParsedArgs = minimist(process.argv.slice(2), { | ||
string: ["devDist"], | ||
default: {devDist: undefined}, | ||
alias: {devDist: "dev-dist"}, | ||
}); | ||
|
||
const project: buildTools.Project = { | ||
root: __dirname, | ||
packageJson: "package.json", | ||
buildDir: "build", | ||
distDir: "dist", | ||
srcDir: "src", | ||
tslint: { | ||
configuration: { | ||
rules: { | ||
"number-literal-format": false, | ||
}, | ||
}, | ||
}, | ||
}; | ||
|
||
const lib: buildTools.LibTarget = { | ||
project, | ||
name: "lib", | ||
srcDir: "src/lib", | ||
scripts: ["**/*.ts"], | ||
mainModule: "index", | ||
dist: { | ||
packageJsonMap: (old: buildTools.PackageJson): buildTools.PackageJson => { | ||
const version: string = options.devDist !== undefined ? `${old.version}-build.${options.devDist}` : old.version; | ||
return <any> {...old, version, scripts: undefined, private: false}; | ||
}, | ||
npmPublish: { | ||
tag: options.devDist !== undefined ? "next" : "latest", | ||
}, | ||
}, | ||
customTypingsDir: "src/custom-typings", | ||
tscOptions: { | ||
skipLibCheck: true, | ||
}, | ||
typedoc: { | ||
dir: "typedoc", | ||
name: "Incident", | ||
deploy: { | ||
repository: "git@github.com:demurgos/incident.git", | ||
branch: "gh-pages", | ||
}, | ||
}, | ||
clean: { | ||
dirs: ["build/lib", "dist/lib"], | ||
}, | ||
}; | ||
|
||
const example: buildTools.NodeTarget = { | ||
project, | ||
name: "example", | ||
srcDir: "src", | ||
scripts: ["example/**/*.ts", "lib/**/*.ts"], | ||
tsconfigJson: "src/example/tsconfig.json", | ||
mainModule: "example/main", | ||
customTypingsDir: "src/custom-typings", | ||
tscOptions: { | ||
skipLibCheck: true, | ||
}, | ||
clean: { | ||
dirs: ["build/example", "dist/example"], | ||
}, | ||
}; | ||
|
||
const test: buildTools.MochaTarget = { | ||
project, | ||
name: "test", | ||
srcDir: "src", | ||
scripts: ["test/**/*.ts", "lib/**/*.ts"], | ||
customTypingsDir: "src/custom-typings", | ||
tsconfigJson: "src/test/tsconfig.json", | ||
tscOptions: { | ||
skipLibCheck: true, | ||
}, | ||
copy: [{files: ["test/test-resources/**/*"]}], | ||
clean: { | ||
dirs: ["build/test"], | ||
}, | ||
}; | ||
|
||
const libTasks: any = buildTools.registerLibTasks(gulp, lib); | ||
buildTools.registerMochaTasks(gulp, test); | ||
buildTools.registerNodeTasks(gulp, example); | ||
buildTools.projectTasks.registerAll(gulp, project); | ||
|
||
gulp.task("all:tsconfig.json", gulp.parallel("lib:tsconfig.json", "test:tsconfig.json", "example:tsconfig.json")); | ||
gulp.task("dist", libTasks.dist); |
Oops, something went wrong.