mirror of
https://github.com/prymitive/karma
synced 2026-08-17 11:27:01 +00:00
feat(ci): lint commit messages on Travis
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
module.exports = {
|
||||
rules: {
|
||||
"body-leading-blank": [1, "always"],
|
||||
"footer-leading-blank": [1, "always"],
|
||||
"header-max-length": [2, "always", 72],
|
||||
"scope-case": [2, "always", "lower-case"],
|
||||
"subject-case": [
|
||||
2,
|
||||
"never",
|
||||
["sentence-case", "start-case", "pascal-case", "upper-case"]
|
||||
],
|
||||
"subject-empty": [2, "never"],
|
||||
"subject-full-stop": [2, "never", "."],
|
||||
"type-case": [2, "always", "lower-case"],
|
||||
"type-empty": [2, "never"],
|
||||
"type-enum": [
|
||||
2,
|
||||
"always",
|
||||
[
|
||||
"build",
|
||||
"chore",
|
||||
"ci",
|
||||
"docs",
|
||||
"feat",
|
||||
"fix",
|
||||
"perf",
|
||||
"refactor",
|
||||
"revert",
|
||||
"style",
|
||||
"test"
|
||||
]
|
||||
]
|
||||
}
|
||||
};
|
||||
@@ -15,6 +15,10 @@ defaults_js: &DEFAULTS_JS
|
||||
|
||||
jobs:
|
||||
include:
|
||||
- stage: Lint git commits
|
||||
<<: *DEFAULTS_JS
|
||||
script: make lint-git-ci
|
||||
|
||||
- stage: Test Go code
|
||||
<<: *DEFAULTS_GO
|
||||
before_script:
|
||||
|
||||
@@ -103,6 +103,10 @@ run-docker: docker-image
|
||||
-p $(PORT):$(PORT) \
|
||||
$(NAME):$(VERSION)
|
||||
|
||||
.PHONY: lint-git-ci
|
||||
lint-git-ci: .build/deps-build-node.ok
|
||||
ui/node_modules/.bin/commitlint-travis
|
||||
|
||||
.PHONY: lint-go
|
||||
lint-go: .build/deps-lint-go.ok
|
||||
golangci-lint run
|
||||
|
||||
Generated
+942
File diff suppressed because it is too large
Load Diff
@@ -52,6 +52,7 @@
|
||||
"build-css": "node_modules/.bin/node-sass --recursive src/ -o src/"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@commitlint/travis-cli": "7.1.2",
|
||||
"diffable-html": "3.0.0",
|
||||
"enzyme": "3.6.0",
|
||||
"enzyme-adapter-react-16": "1.5.0",
|
||||
|
||||
Reference in New Issue
Block a user