Skip to content

Commit 3354a06

Browse files
authored
Merge branch 'master' into dependabot/go_modules/github.com/Masterminds/goutils-1.1.1
2 parents d5397f3 + 6e2413a commit 3354a06

185 files changed

Lines changed: 3281 additions & 939 deletions

File tree

Some content is hidden

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

.asf.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,13 @@ github:
2828
squash: true
2929
merge: false
3030
rebase: false
31+
dependabot_updates: false
32+
protected_branches:
33+
master:
34+
required_status_checks:
35+
strict: true
36+
contexts:
37+
- Required
38+
required_pull_request_reviews:
39+
dismiss_stale_reviews: true
40+
required_approving_review_count: 1

.github/file-filters.txt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
**/*.go
18+
go.mod
19+
.golangci.yml
20+
.github/**/*

.github/file-filters.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/CI.yaml

Lines changed: 147 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,147 @@
1+
#
2+
# Licensed to the Apache Software Foundation (ASF) under one
3+
# or more contributor license agreements. See the NOTICE file
4+
# distributed with this work for additional information
5+
# regarding copyright ownership. The ASF licenses this file
6+
# to you under the Apache License, Version 2.0 (the
7+
# "License"); you may not use this file except in compliance
8+
# with the License. You may obtain a copy of the License at
9+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
11+
#
12+
# Unless required by applicable law or agreed to in writing,
13+
# software distributed under the License is distributed on an
14+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
# KIND, either express or implied. See the License for the
16+
# specific language governing permissions and limitations
17+
# under the License.
18+
#
19+
name: CI
20+
21+
on:
22+
pull_request:
23+
push:
24+
branches:
25+
- master
26+
schedule:
27+
- cron: "0 18 * * *" # TimeZone: UTC 0
28+
29+
concurrency:
30+
group: skywalking-cli-${{ github.event.pull_request.number || github.ref }}
31+
cancel-in-progress: true
32+
33+
jobs:
34+
check-license:
35+
name: License header
36+
if: github.repository == 'apache/skywalking-cli'
37+
runs-on: ubuntu-latest
38+
steps:
39+
- uses: actions/checkout@v4
40+
41+
- name: Check License Header
42+
uses: apache/skywalking-eyes@5dfa68f93380a5e57259faaf95088b7f133b5778
43+
env:
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
46+
- name: Setup Go
47+
uses: actions/setup-go@v5
48+
with:
49+
go-version: "1.24"
50+
51+
- name: Check Dependencies License
52+
run: make dependency-license
53+
54+
build:
55+
name: Build
56+
runs-on: ubuntu-latest
57+
if: github.repository == 'apache/skywalking-cli'
58+
steps:
59+
- uses: actions/checkout@v4
60+
- name: Set up Go
61+
uses: actions/setup-go@v5
62+
with:
63+
go-version: 1.24
64+
65+
- name: Check code generation
66+
run: make check-codegen
67+
68+
- name: Lint
69+
run: make lint
70+
71+
- uses: actions/upload-artifact@v4
72+
if: failure()
73+
with:
74+
name: check-diff
75+
path: /tmp/swctl/check.diff
76+
77+
- name: Build
78+
run: make build -j3
79+
80+
- name: Build Docker images
81+
run: make docker
82+
83+
84+
command-tests:
85+
name: Command Tests
86+
runs-on: ubuntu-latest
87+
if: github.repository == 'apache/skywalking-cli'
88+
strategy:
89+
matrix:
90+
oap:
91+
- a65a6e0ff2ef9c716131b36172399076307c35f1 # Feb 27th, 2024
92+
steps:
93+
- uses: actions/checkout@v4
94+
- name: Set up Go
95+
uses: actions/setup-go@v5
96+
with:
97+
go-version: 1.24
98+
99+
- name: Install swctl
100+
run: make install DESTDIR=/usr/local/bin
101+
102+
- name: Test commands
103+
uses: apache/skywalking-infra-e2e@cf589b4a0b9f8e6f436f78e9cfd94a1ee5494180
104+
env:
105+
OAP_TAG: ${{ matrix.oap }}
106+
with:
107+
e2e-file: test/cases/basic/test.yaml
108+
109+
110+
unit-tests:
111+
name: Unit Tests
112+
runs-on: ubuntu-latest
113+
if: github.repository == 'apache/skywalking-cli'
114+
steps:
115+
- uses: actions/checkout@v4
116+
- name: setup go
117+
uses: actions/setup-go@v5
118+
with:
119+
go-version: '1.24'
120+
121+
- name: run unit tests and report coverage
122+
working-directory: ./
123+
run: |
124+
make coverage
125+
126+
required:
127+
if: always()
128+
name: Required
129+
needs:
130+
- check-license
131+
- build
132+
- command-tests
133+
- unit-tests
134+
runs-on: ubuntu-latest
135+
timeout-minutes: 10
136+
steps:
137+
- name: Merge Requirement
138+
run: |
139+
checkLicense=${{ needs.check-license.result }}
140+
[[ ${checkLicense} == 'success' ]] || exit 1;
141+
build=${{ needs.build.result }};
142+
commandTests=${{ needs.command-tests.result }};
143+
unitTests=${{ needs.unit-tests.result }};
144+
[[ ${build} == 'success' ]] || [[ ${build} == 'skipped' ]] || exit 3;
145+
[[ ${commandTests} == 'success' ]] || [[ ${commandTests} == 'skipped' ]] || exit 4;
146+
[[ ${unitTests} == 'success' ]] || [[ ${unitTests} == 'skipped' ]] || exit 5;
147+
exit 0;

.github/workflows/command-tests.yml

Lines changed: 0 additions & 55 deletions
This file was deleted.

.github/workflows/go.yml

Lines changed: 0 additions & 58 deletions
This file was deleted.

.github/workflows/golangci-lint.yml

Lines changed: 0 additions & 51 deletions
This file was deleted.

0 commit comments

Comments
 (0)