Skip to content

Commit 4df5859

Browse files
committed
TEST/MINOR: adding linter for commit messages
commit messages are now checked if they are aligned with our CONTRIBUTING guide (https://github.com/haproxy/haproxy/blob/master/CONTRIBUTING)
1 parent cdb42f0 commit 4df5859

File tree

4 files changed

+20
-6
lines changed

4 files changed

+20
-6
lines changed

.gitlab-ci.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
---
2+
stages:
3+
- lint
24
compare build:
5+
stage: lint
36
image:
47
# I just like pinning things, this version is latest, not special in any way
58
name: alpine:3.10.3
@@ -11,8 +14,8 @@ compare build:
1114
- cd build
1215
- ./build -file ../haproxy-spec.yaml > haproxy_spec_to_compare.yaml
1316
- diff -u haproxy_spec_to_compare.yaml haproxy_spec.yaml
14-
1517
yamllint:
18+
stage: lint
1619
image:
1720
name: cytopia/yamllint:latest
1821
entrypoint: [""]
@@ -23,3 +26,12 @@ yamllint:
2326
- /bin/sh -c "yamllint -f colored ."
2427
- chmod +x ./scripts/single-tag.sh
2528
- /bin/sh -c ./scripts/single-tag.sh
29+
lint-commit-msg:
30+
stage: lint
31+
image:
32+
name: haproxytech/check-commit:latest
33+
entrypoint: [""]
34+
tags:
35+
- go
36+
script:
37+
- go run /check.go

models/configuration.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -741,7 +741,7 @@ bind:
741741
x-dependency:
742742
ssl:
743743
value: true
744-
#ca_file:
744+
# ca_file:
745745
# type: string
746746
# x-dependency:
747747
# ssl:
@@ -782,7 +782,7 @@ bind:
782782
x-dependency:
783783
ssl:
784784
value: true
785-
#crt:
785+
# crt:
786786
# type: string
787787
# x-dependency:
788788
# ssl:

models/service-discovery.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
consul:
23
title: Consul server
34
description: Consul server configuration
@@ -43,7 +44,7 @@ consul:
4344
enum: [linear, exponential]
4445
default: exponential
4546
server_slots_growth_increment:
46-
type: integer
47+
type: integer
4748
description:
4849
type: string
4950
name:
@@ -54,4 +55,4 @@ consul:
5455
enabled: true
5556
address: 127.0.0.1
5657
port: 90
57-
retry_timeout: 10
58+
retry_timeout: 10

paths/service-discovery.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
consul:
23
get:
34
summary: Return an array of all configured Consul servers
@@ -111,4 +112,4 @@ consul_one:
111112
'404':
112113
$ref: '#/responses/NotFound'
113114
'default':
114-
$ref: '#/responses/DefaultError'
115+
$ref: '#/responses/DefaultError'

0 commit comments

Comments
 (0)