-
-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update workflow & build system
This PR: - Removes Babel, `pre-commit` - Replaces with TypeScript and `husky`, respectively - Disables dependabot in lieu of renovate - Ships type definitions - Updates dependencies and commits `package-lock.json` - Update eslint config (and a small bit of linting)
- Loading branch information
Showing
22 changed files
with
16,876 additions
and
275 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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# editorconfig.org | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
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,11 +1,17 @@ | ||
{ | ||
"extends": "@appium/eslint-config-appium", | ||
"extends": "@appium/eslint-config-appium-ts", | ||
"overrides": [ | ||
{ | ||
"files": "test/**/*.js", | ||
"rules": { | ||
"func-names": "off" | ||
} | ||
}, | ||
{ | ||
"files": "scripts/**/*", | ||
"rules": { | ||
"@typescript-eslint/no-var-requires": "off" | ||
} | ||
} | ||
] | ||
} |
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,4 @@ | ||
* text=auto eol=lf | ||
|
||
# Handle as a text file but merge as binary. | ||
package-lock.json merge=binary |
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,5 +1,4 @@ | ||
node_modules | ||
package-lock.json* | ||
build | ||
.idea/ | ||
uiautomator2/ | ||
|
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,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
npm run lint:commit -- --edit ${1} |
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,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
npm run lint:staged |
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,4 +1,5 @@ | ||
module.exports = { | ||
require: ['@babel/register'], | ||
forbidOnly: Boolean(process.env.CI) | ||
require: ['ts-node/register'], | ||
forbidOnly: Boolean(process.env.CI), | ||
color: true, | ||
}; |
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 +1 @@ | ||
package-lock=false | ||
save-exact=true |
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,6 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": ["github>appium/appium//renovate/default"], | ||
"schedule": ["after 10pm and before 5:00am"], | ||
"timezone": "America/Vancouver" | ||
} |
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,42 @@ | ||
'use strict'; | ||
|
||
module.exports = (wallaby) => { | ||
return { | ||
compilers: { | ||
'**/*.js': wallaby.compilers.typeScript({ | ||
allowJs: true, | ||
allowSyntheticDefaultImports: true, | ||
resolveJsonModule: true, | ||
isolatedModules: true, | ||
}), | ||
'**/*.ts?(x)': wallaby.compilers.typeScript(), | ||
}, | ||
debug: true, | ||
env: { | ||
type: 'node', | ||
}, | ||
files: ['package.json', 'lib/**/*'], | ||
testFramework: 'mocha', | ||
tests: ['test/unit/**/*-specs.js'], | ||
workers: { | ||
// restart: true, | ||
}, | ||
setup(wallaby) { | ||
// copied out of `./test/setup.js` | ||
|
||
const chai = require('chai'); | ||
const chaiAsPromised = require('chai-as-promised'); | ||
|
||
// The `chai` global is set if a test needs something special. | ||
// Most tests won't need this. | ||
global.chai = chai.use(chaiAsPromised); | ||
|
||
// `should()` is only necessary when working with some `null` or `undefined` values. | ||
global.should = chai.should(); | ||
|
||
const mocha = wallaby.testFramework; | ||
mocha.timeout(10000); | ||
}, | ||
runMode: 'onsave', | ||
}; | ||
}; |
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,11 @@ | ||
module.exports = { | ||
extends: ['@commitlint/config-conventional'], | ||
rules: { | ||
'body-leading-blank': [0], | ||
'body-max-line-length': [0], | ||
'footer-max-line-length': [0], | ||
'header-max-length': [0], | ||
'subject-case': [0], | ||
'subject-full-stop': [0], | ||
}, | ||
}; |
Oops, something went wrong.