Skip to content

Commit 68f99c8

Browse files
committed
bazel: enable and apply formatting
1 parent 0f300c0 commit 68f99c8

File tree

25 files changed

+1987
-368
lines changed

25 files changed

+1987
-368
lines changed

.github/ISSUE_TEMPLATE/1-bugfix.yml

Lines changed: 64 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -16,67 +16,67 @@ description: Issue to track a bug
1616
title: "Bug: Your bugfix title"
1717
labels: ["codeowner_review"]
1818
body:
19-
- type: markdown
20-
attributes:
21-
value: "## <ins>Bug Ticket creation</ins>"
22-
- type: textarea
23-
attributes:
24-
label: Description
25-
description: Short Description of the Bug
26-
validations:
27-
required: true
28-
- type: dropdown
29-
attributes:
30-
label: Error Occurrence Rate
31-
options:
32-
- Single Event
33-
- Sporadic
34-
- Highly Intermittent
35-
- Reproducible
36-
- type: textarea
37-
attributes:
38-
label: How to reproduce
39-
description: How to reproduce?
40-
- type: textarea
41-
attributes:
42-
label: Supporting Information
43-
description: |
44-
During which operational state did the issue occur
45-
Observations / Screenshots / Traces
46-
validations:
47-
required: false
48-
- type: dropdown
49-
attributes:
50-
label: Classification
51-
options:
52-
- minor
53-
- major
54-
- critical
55-
- blocker
56-
default: 0
57-
validations:
58-
required: true
59-
- type: dropdown
60-
attributes:
61-
label: Affected Version
62-
options:
63-
- 0.5
64-
- 1.0
65-
default: 0
66-
validations:
67-
required: true
68-
- type: dropdown
69-
attributes:
70-
label: Expected Closure Version
71-
options:
72-
- 0.5
73-
- 1.0
74-
default: 0
75-
validations:
76-
required: false
77-
- type: checkboxes
78-
attributes:
79-
label: Category
80-
options:
81-
- label: Safety Related
82-
- label: Security Related
19+
- type: markdown
20+
attributes:
21+
value: "## <ins>Bug Ticket creation</ins>"
22+
- type: textarea
23+
attributes:
24+
label: Description
25+
description: Short Description of the Bug
26+
validations:
27+
required: true
28+
- type: dropdown
29+
attributes:
30+
label: Error Occurrence Rate
31+
options:
32+
- Single Event
33+
- Sporadic
34+
- Highly Intermittent
35+
- Reproducible
36+
- type: textarea
37+
attributes:
38+
label: How to reproduce
39+
description: How to reproduce?
40+
- type: textarea
41+
attributes:
42+
label: Supporting Information
43+
description: |
44+
During which operational state did the issue occur
45+
Observations / Screenshots / Traces
46+
validations:
47+
required: false
48+
- type: dropdown
49+
attributes:
50+
label: Classification
51+
options:
52+
- minor
53+
- major
54+
- critical
55+
- blocker
56+
default: 0
57+
validations:
58+
required: true
59+
- type: dropdown
60+
attributes:
61+
label: Affected Version
62+
options:
63+
- 0.5
64+
- 1.0
65+
default: 0
66+
validations:
67+
required: true
68+
- type: dropdown
69+
attributes:
70+
label: Expected Closure Version
71+
options:
72+
- 0.5
73+
- 1.0
74+
default: 0
75+
validations:
76+
required: false
77+
- type: checkboxes
78+
attributes:
79+
label: Category
80+
options:
81+
- label: Safety Related
82+
- label: Security Related

.github/ISSUE_TEMPLATE/2-improvement.yml

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -16,37 +16,37 @@ description: Issue to track a improvement / task
1616
title: "Improvement: Your Improvement title"
1717
labels: ["codeowner_review"]
1818
body:
19-
- type: textarea
20-
attributes:
21-
label: What
22-
description: |
23-
- Goal of the Improvement / Task
24-
- If Req/Architecture is affected, the template of
25-
[Change Management](https://eclipse-score.github.io/process_description/main/process_areas/change_management/guidance/change_management_impact_analysis_template.html) needs to be used
26-
validations:
27-
required: true
28-
- type: textarea
29-
attributes:
30-
label: How
31-
description: Details on implementation approach
32-
validations:
33-
required: false
34-
- type: textarea
35-
attributes:
36-
label: Estimates for realization
37-
description: |
38-
- Estimate the effort, resources, risk for the realization
39-
- Impact to users of the feature
40-
validations:
41-
required: true
42-
- type: checkboxes
43-
attributes:
44-
label: Category
45-
options:
46-
- label: Affects Detailed Design
47-
- type: checkboxes
48-
attributes:
49-
label: Requirements / Architecture
50-
options:
51-
- label: Requirements / Architecture are not affected by this change?
52-
required: true
19+
- type: textarea
20+
attributes:
21+
label: What
22+
description: |
23+
- Goal of the Improvement / Task
24+
- If Req/Architecture is affected, the template of
25+
[Change Management](https://eclipse-score.github.io/process_description/main/process_areas/change_management/guidance/change_management_impact_analysis_template.html) needs to be used
26+
validations:
27+
required: true
28+
- type: textarea
29+
attributes:
30+
label: How
31+
description: Details on implementation approach
32+
validations:
33+
required: false
34+
- type: textarea
35+
attributes:
36+
label: Estimates for realization
37+
description: |
38+
- Estimate the effort, resources, risk for the realization
39+
- Impact to users of the feature
40+
validations:
41+
required: true
42+
- type: checkboxes
43+
attributes:
44+
label: Category
45+
options:
46+
- label: Affects Detailed Design
47+
- type: checkboxes
48+
attributes:
49+
label: Requirements / Architecture
50+
options:
51+
- label: Requirements / Architecture are not affected by this change?
52+
required: true

.github/workflows/build_and_test_host_gcc.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,16 @@ on:
2121
merge_group:
2222
types: [checks_requested]
2323
jobs:
24-
build_and_test_gcc_host_gcc12:
25-
runs-on: ubuntu-latest
26-
steps:
27-
- name: Checkout repository
28-
uses: actions/checkout@v4.2.2
29-
- name: Setup Bazel
30-
uses: bazel-contrib/setup-bazel@0.9.1
31-
- name: Bazel build communication targets
32-
run: |
33-
bazel build //...
34-
- name: Bazel test communication targets
35-
run: |
36-
bazel test //... --build_tests_only
24+
build_and_test_gcc_host_gcc12:
25+
runs-on: ubuntu-latest
26+
steps:
27+
- name: Checkout repository
28+
uses: actions/checkout@v4.2.2
29+
- name: Setup Bazel
30+
uses: bazel-contrib/setup-bazel@0.9.1
31+
- name: Bazel build communication targets
32+
run: |
33+
bazel build //...
34+
- name: Bazel test communication targets
35+
run: |
36+
bazel test //... --build_tests_only

BUILD

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,14 @@
1010
#
1111
# SPDX-License-Identifier: Apache-2.0
1212
# *******************************************************************************
13+
load("@score_format_checker//:macros.bzl", "use_format_targets")
14+
load("@score_starpls_lsp//:starpls.bzl", "setup_starpls")
15+
16+
# Add target for formatting checks
17+
use_format_targets()
18+
19+
# Add StarPLS server for formatting
20+
setup_starpls(
21+
name = "starpls_server",
22+
visibility = ["//visibility:public"],
23+
)

MODULE.bazel

Lines changed: 36 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,15 @@
1212
# *******************************************************************************
1313
module(name = "communication")
1414

15-
1615
bazel_dep(name = "platforms", version = "0.0.11")
17-
bazel_dep(name = "score_toolchains_gcc", version = "0.4", dev_dependency=True)
1816

19-
gcc = use_extension("@score_toolchains_gcc//extentions:gcc.bzl", "gcc", dev_dependency=True)
17+
bazel_dep(name = "score_toolchains_gcc", version = "0.4", dev_dependency = True)
18+
19+
gcc = use_extension("@score_toolchains_gcc//extentions:gcc.bzl", "gcc", dev_dependency = True)
2020
gcc.toolchain(
21-
url = "https://github.com/eclipse-score/toolchains_gcc_packages/releases/download/0.0.1/x86_64-unknown-linux-gnu_gcc12.tar.gz",
2221
sha256 = "457f5f20f57528033cb840d708b507050d711ae93e009388847e113b11bf3600",
2322
strip_prefix = "x86_64-unknown-linux-gnu",
23+
url = "https://github.com/eclipse-score/toolchains_gcc_packages/releases/download/0.0.1/x86_64-unknown-linux-gnu_gcc12.tar.gz",
2424
)
2525

2626
# TODO to be moved to toolchain. https://github.com/eclipse-score/toolchains_gcc/issues/11
@@ -31,32 +31,50 @@ gcc.extra_features(
3131
],
3232
)
3333
gcc.warning_flags(
34-
minimal_warnings = ["-Wall", "-Wno-error=deprecated-declarations"],
35-
strict_warnings = ["-Wextra", "-Wpedantic"],
34+
minimal_warnings = [
35+
"-Wall",
36+
"-Wno-error=deprecated-declarations",
37+
],
38+
strict_warnings = [
39+
"-Wextra",
40+
"-Wpedantic",
41+
],
3642
treat_warnings_as_errors = ["-Werror"],
3743
)
38-
3944
use_repo(gcc, "gcc_toolchain", "gcc_toolchain_gcc")
4045

4146
bazel_dep(name = "googletest", version = "1.15.0")
4247
bazel_dep(name = "google_benchmark", version = "1.9.1")
43-
4448
bazel_dep(name = "rules_rust", version = "0.61.0")
4549

46-
crate = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
47-
48-
crate.spec(package = "futures", version = "0.3.31")
49-
crate.spec(package = "libc", version = "0.2.155")
50-
crate.spec(package = "clap", version = "4.5.4", features = ["derive"])
50+
# Format checker
51+
bazel_dep(name = "score_format_checker", version = "0.1.1")
52+
bazel_dep(name = "aspect_rules_lint", version = "1.0.3")
53+
bazel_dep(name = "buildifier_prebuilt", version = "7.3.1")
54+
bazel_dep(name = "score_starpls_lsp", version = "0.1.0")
5155

56+
crate = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
57+
crate.spec(
58+
package = "futures",
59+
version = "0.3.31",
60+
)
61+
crate.spec(
62+
package = "libc",
63+
version = "0.2.155",
64+
)
65+
crate.spec(
66+
features = ["derive"],
67+
package = "clap",
68+
version = "4.5.4",
69+
)
5270
crate.from_specs(name = "crate_index")
5371
use_repo(crate, "crate_index")
5472

5573
bazel_dep(name = "rules_boost", repo_name = "com_github_nelhage_rules_boost")
5674
archive_override(
5775
module_name = "rules_boost",
58-
urls = "https://github.com/nelhage/rules_boost/archive/refs/heads/master.tar.gz",
5976
strip_prefix = "rules_boost-master",
77+
urls = "https://github.com/nelhage/rules_boost/archive/refs/heads/master.tar.gz",
6078
)
6179

6280
non_module_boost_repositories = use_extension("@com_github_nelhage_rules_boost//:boost/repositories.bzl", "non_module_dependencies")
@@ -65,22 +83,22 @@ use_repo(
6583
"boost",
6684
)
6785

68-
6986
bazel_dep(name = "download_utils", version = "1.0.1")
87+
7088
download_archive = use_repo_rule("@download_utils//download/archive:defs.bzl", "download_archive")
89+
7190
download_archive(
7291
name = "json_schema_validator",
73-
urls = ["https://github.com/pboettch/json-schema-validator/archive/refs/tags/2.1.0.tar.gz"],
7492
build = "//third_party/json_schema_validator:json_schema_validator.BUILD",
7593
strip_prefix = "json-schema-validator-2.1.0",
94+
urls = ["https://github.com/pboettch/json-schema-validator/archive/refs/tags/2.1.0.tar.gz"],
7695
)
7796

7897
bazel_dep(name = "nlohmann_json", version = "3.11.3")
7998
bazel_dep(name = "bazel_skylib", version = "1.7.1")
80-
8199
bazel_dep(name = "score-baselibs", version = "0.0.0")
82100
git_override(
83101
module_name = "score-baselibs",
84-
remote = "https://github.com/eclipse-score/baselibs.git",
85102
commit = "ae349b99cafc1e79d98c0391a851fc5664c04ebc",
103+
remote = "https://github.com/eclipse-score/baselibs.git",
86104
)

0 commit comments

Comments
 (0)