Skip to content

Commit 826f6c8

Browse files
committed
merge release/v1.4.0 into master
2 parents 2445f06 + 870d586 commit 826f6c8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+594
-171
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
115
# This is a basic workflow to help you get started with Actions
216

317
name: CI
@@ -34,6 +48,10 @@ jobs:
3448
- run: git checkout HEAD^2
3549
if: ${{ github.event_name == 'pull_request' }}
3650

51+
# Check license header
52+
- name: Check License Header
53+
uses: apache/skywalking-eyes@main
54+
3755
# Build
3856
- name: Build
3957
shell: bash

.gitignore

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
115
.svn
216
.tmp
317
.download
@@ -10,3 +24,5 @@ profile.out
1024
coverage.txt
1125
.idea/*
1226
.vscode/*
27+
bfe
28+
dist/*

.goreleaser.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,21 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
115
project_name: bfe
216

317
builds:
4-
- binary: bfe
18+
- binary: bin/bfe
519
main: ./bfe.go
620
ldflags:
721
- -X main.version={{.Version}} -X main.commit={{.Commit}}
@@ -31,7 +45,7 @@ archives:
3145
- LICENSE
3246
- README.md
3347
- CHANGELOG.md
34-
- conf/**/*
48+
- conf/*
3549

3650
checksum:
3751
name_template: "{{ .ProjectName }}_{{ .Version }}_checksums.txt"

.licenserc.yaml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Copyright (c) 2021 The BFE Authors.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
header:
16+
license:
17+
spdx-id: Apache-2.0
18+
copyright-owner: The BFE Authors
19+
20+
paths-ignore:
21+
- 'conf'
22+
- 'docs/material'
23+
- 'docs/images'
24+
- '**/go.mod'
25+
- '**/go.sum'
26+
- '**/*.md'
27+
- '**/testdata/*'
28+
- '**/test_data/*/**'
29+
- '**/*/testdata/*/**'
30+
- 'LICENSE'
31+
- 'NOTICE'
32+
- 'VERSION'
33+
- 'staticcheck.conf'
34+
- 'bfe_basic/condition/parser/y.go'
35+
36+
comment: on-failure
37+
38+
dependency:
39+
files:
40+
- go.mod

.pre-commit-config.yaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
15+
repos:
116
- repo: git://github.com/dnephin/pre-commit-golang
2-
rev: master
17+
rev: v0.4.0
318
hooks:
419
- id: go-fmt
520
- id: go-vet

.travis.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
115
language: go
216

317
go:

CHANGELOG.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,19 @@ All notable changes to this project will be documented in this file.
1010
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
1111
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
1212

13+
## [v1.4.0] - 2021-12-10
14+
15+
### Added
16+
17+
- Documents optimization
18+
19+
### Changed
20+
21+
- Upgrade golang version from 1.13 to 1.17
22+
- mod_markdown: upgrade bluemonday version to 1.0.16
23+
- Optimize mutex
24+
- Improve Makefile and pre-commit
25+
1326
## [v1.3.0] - 2021-09-16
1427

1528
### Added
@@ -262,6 +275,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
262275
- Flexible plugin framework to extend functionality. Based on the framework, developer can add new features rapidly
263276
- Detailed built-in metrics available for service status monitor
264277

278+
<<<<<<< HEAD
279+
=======
280+
[v1.4.0]: https://github.com/bfenetworks/bfe/compare/v1.3.0...v1.4.0
281+
>>>>>>> release/v1.4.0
265282
[v1.3.0]: https://github.com/bfenetworks/bfe/compare/v1.2.0...v1.3.0
266283
[v1.2.0]: https://github.com/bfenetworks/bfe/compare/v1.1.0...v1.2.0
267284
[v1.1.0]: https://github.com/bfenetworks/bfe/compare/v1.0.0...v1.1.0

CONTRIBUTING.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
# Contribute Code
22

3-
You are welcome to contribute to project BFE. To contribute to BFE, you have to agree with the
4-
[Contributor License Agreement](https://cla-assistant.io/bfenetworks/bfe).
5-
6-
We sincerely appreciate your contribution. This document explains our workflow and work style.
3+
You are welcome to contribute to project BFE. This document explains our workflow and work style.
74

85
## Workflow
96

@@ -44,8 +41,15 @@ BFE uses this [Git branching model](http://nvie.com/posts/a-successful-git-branc
4441
Once installed, `pre-commit` checks the style of code and documentation in every commit:
4542

4643
```
47-
$ git commit
44+
$ git commit -s
45+
```
46+
47+
NOTE: You should add a line to every git commit message, e.g.
48+
```
49+
Signed-off-by: Sijie Yang <iyangsj@gmail.com>
4850
```
51+
Please use your real name (sorry, no pseudonyms or anonymous contributions). The signoff line at the end of the commit message certifies that you wrote it
52+
or otherwise have the right to pass it on as an open-source patch. The rules are pretty simple: if you can certify the [Developer Certificate of Origin](https://developercertificate.org/).
4953

5054
NOTE: The `yapf` installed by `pip install pre-commit` and `conda install -c conda-forge pre-commit` is slightly different. BFE developers use `pip install pre-commit`.
5155

Dockerfile

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2021 The BFE Authors
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
115
FROM golang:1.13.11-alpine AS build
216

317
WORKDIR /bfe

Makefile

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ GOGEN := $(GO) generate
3030
GOCLEAN := $(GO) clean
3131
GOFLAGS := -race
3232
STATICCHECK := staticcheck
33+
LICENSEEYE := license-eye
3334

3435
# init arch
3536
ARCH := $(shell getconf LONG_BIT)
@@ -48,6 +49,9 @@ BFE_PKGS := $(shell go list ./...)
4849
# make, make all
4950
all: prepare compile package
5051

52+
# make, make strip
53+
strip: prepare compile-strip package
54+
5155
# make prepare, download dependencies
5256
prepare: prepare-dep prepare-gen
5357
prepare-dep:
@@ -60,6 +64,11 @@ compile: test build
6064
build:
6165
$(GOBUILD) -ldflags "-X main.version=$(BFE_VERSION) -X main.commit=$(GIT_COMMIT) -extldflags=-static"
6266

67+
# make compile-strip, go build without symbols and DWARFs
68+
compile-strip: test build-strip
69+
build-strip:
70+
$(GOBUILD) -ldflags "-X main.version=$(BFE_VERSION) -X main.commit=$(GIT_COMMIT) -extldflags=-static -s -w"
71+
6372
# make test, test your code
6473
test: test-case vet-case
6574
test-case:
@@ -83,6 +92,11 @@ check:
8392
$(GO) get honnef.co/go/tools/cmd/staticcheck
8493
$(STATICCHECK) ./...
8594

95+
# make license-check, check code file's license declearation
96+
license-check:
97+
$(GO) install github.com/apache/skywalking-eyes/cmd/license-eye@latest
98+
$(LICENSEEYE) header check
99+
86100
# make docker
87101
docker:
88102
docker build \

0 commit comments

Comments
 (0)