Skip to content

Commit be542e2

Browse files
authored
Merge pull request #244 from com-pas/develop
Merge develop into main
2 parents 05da69b + e8c5680 commit be542e2

File tree

46 files changed

+3102
-403
lines changed

Some content is hidden

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

46 files changed

+3102
-403
lines changed
Lines changed: 26 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,29 @@
1-
# SPDX-FileCopyrightText: 2022 RTE FRANCE
1+
# SPDX-FileCopyrightText: 2022 2023 RTE FRANCE
22
#
33
# SPDX-License-Identifier: Apache-2.0
44
name: Continuous Deployment - JavaDocs
55

66
on:
7-
push:
8-
branches:
9-
- 'feat/javadoc'
7+
pull_request_target:
8+
types: [ labeled, closed ]
9+
1010
jobs:
1111
build:
12+
if: ${{ github.event.pull_request.base.ref == 'develop' && github.actor != 'dependabot[bot]' && github.event.pull_request.merged && contains(github.event.pull_request.labels.*.name, 'javadoc') }}
1213
name: Java Docs
1314
runs-on: ubuntu-latest
1415
env:
15-
from_branch: feat/javadoc
16-
target_branch: feat/117_Documentation_SCD_Generation_Process
16+
DEPLOYMENT_BRANCH: gh-pages
17+
DEPENDABOT_BRANCH: dependabot/javadoc-${{ github.head_ref || github.ref_name }}-${{ github.event.pull_request.number }}
1718
steps:
18-
# Use develop as base branch to generate javadoc
19-
- name: Setup Environment
19+
- name: Checkout
2020
uses: actions/checkout@v3
21+
22+
- name: Set up JDK 17
23+
uses: actions/setup-java@v3
2124
with:
2225
distribution: 'zulu'
2326
java-version: '17'
24-
ref: ${{ env.target_branch }}
2527

2628
- name: Create custom Maven Settings.xml
2729
uses: whelk-io/maven-settings-xml-action@v21
@@ -33,6 +35,8 @@ jobs:
3335
run: |
3436
git config --global user.name '${{ secrets.CONFIG_CI_USER_NAME }}'
3537
git config --global user.email '${{ secrets.CONFIG_CI_USER_EMAIL }}'
38+
git config pull.rebase false
39+
git fetch origin ${{ env.DEPLOYMENT_BRANCH }}
3640
3741
- name: Import GPG key
3842
id: import_gpg
@@ -42,27 +46,25 @@ jobs:
4246
git_user_signingkey: true
4347
git_commit_gpgsign: true
4448

45-
- name: Prepare Pull Request branch
49+
# Take note that your GitHub Pages site is currently being built from the /docs folder in the DEPLOYMENT_BRANCH branch.
50+
- name: Prepare Pull Request branch & commit files
4651
run: |
4752
mvn -s custom_maven_settings.xml clean javadoc:aggregate -P javadoc
4853
mkdir -p docs/javadoc
4954
yes | cp -Rf target/site/apidocs/* docs/javadoc/
50-
git checkout -b ${{ env.from_branch }}-pull-request
55+
git checkout -b temp
56+
git add docs/javadoc/
57+
git commit -m "[dependabot/javadoc/temp]: update javadoc"
58+
git checkout ${{ env.DEPLOYMENT_BRANCH }}
59+
git clean -fdx
60+
git checkout -b ${{ env.DEPENDABOT_BRANCH }}
61+
git cherry-pick -n -X theirs temp
62+
git commit -m "[dependabot/javadoc]: update javadoc"
63+
git checkout ${{ env.DEPLOYMENT_BRANCH }}
64+
git merge ${{ env.DEPENDABOT_BRANCH }}
5165
52-
# Note that will fail if branch already exists.
5366
- name: Push Git Branch
5467
uses: ad-m/[email protected]
5568
with:
5669
github_token: ${{ secrets.GITHUB_TOKEN }}
57-
branch: ${{ env.from_branch }}-pull-request
58-
59-
# Note that will silently fail if PR already exists.
60-
- name: Create Pull Request
61-
uses: repo-sync/pull-request@v2
62-
with:
63-
github_token: ${{ secrets.GITHUB_TOKEN }}
64-
source_branch: ${{ env.from_branch }}-pull-request
65-
destination_branch: ${{ env.target_branch }}
66-
pr_title: "Docs: Update Java docs repository"
67-
pr_body: "Automatically created from CI workflow"
68-
pr_label: "documentation,javadoc"
70+
branch: ${{ env.DEPLOYMENT_BRANCH }}

.github/workflows/automate_projects.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,29 @@ jobs:
1414
steps:
1515
- name: add-new-issues-to-repository-based-project-column
1616
if: github.event_name == 'issues' && github.event.action == 'opened'
17-
uses: alex-page/[email protected].2
17+
uses: alex-page/[email protected].3
1818
with:
1919
project: CoMPAS SCT Board
2020
column: To do
2121
repo-token: ${{ secrets.ORG_GITHUB_ACTION_SECRET }}
2222
- name: add-new-pull-request-to-repository-based-project-column
2323
if: (github.event_name == 'pull_request' || github.event_name == 'pull_request_target') && github.event.action == 'opened'
24-
uses: alex-page/[email protected].2
24+
uses: alex-page/[email protected].3
2525
with:
2626
project: CoMPAS SCT Board
2727
column: To do
2828
repo-token: ${{ secrets.ORG_GITHUB_ACTION_SECRET }}
2929

3030
- name: add-new-issues-to-organization-based-project-column
3131
if: github.event_name == 'issues' && github.event.action == 'opened'
32-
uses: alex-page/[email protected].2
32+
uses: alex-page/[email protected].3
3333
with:
3434
project: CoMPAS Issues Overview Board
3535
column: To do
3636
repo-token: ${{ secrets.ORG_GITHUB_ACTION_SECRET }}
3737
- name: add-new-pull-request-to-organization-based-project-column
3838
if: (github.event_name == 'pull_request' || github.event_name == 'pull_request_target') && github.event.action == 'opened'
39-
uses: alex-page/[email protected].2
39+
uses: alex-page/[email protected].3
4040
with:
4141
project: CoMPAS Pull Request Overview Board
4242
column: To do

.github/workflows/sonarcloud-analysis.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,24 +26,18 @@ jobs:
2626
key: ${{ runner.os }}-sonar
2727
restore-keys: ${{ runner.os }}-sonar
2828

29-
- name: Cache Maven packages
30-
uses: actions/cache@v3
31-
with:
32-
path: ~/.m2
33-
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
34-
restore-keys: ${{ runner.os }}-m2
35-
3629
- name: Set up JDK 17
3730
uses: actions/setup-java@v3
3831
with:
3932
distribution: 'zulu'
4033
java-version: '17'
34+
cache: 'maven'
4135

4236
- name: Set Common Sonar Variables
4337
id: sonar_env
4438
run: |
4539
echo "##[set-output name=sonar_opts;]$(echo -Dsonar.host.url=https://sonarcloud.io \
46-
-Dsonar.projectKey=com-pas_compas-core \
40+
-Dsonar.projectKey=com-pas_compas-sct \
4741
-Dsonar.organization=com-pas )"
4842
- name: Create custom Maven Settings.xml
4943
uses: whelk-io/maven-settings-xml-action@v21

docs/HOME.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ Technical Steering Committee [[email protected]](mailto:CoMPAS-tsc@l
3939
By contributing to the CoMPAS project, you accept and agree to the following terms and conditions for your present and future contributions submitted to CoMPAS.
4040

4141
All contributions to this project are licensed under the license stipulated at the corresponding sub-repository.
42-
Except where otherwise explicitely indicated, CoMPAS is an open source project licensed under the [Apache License, version 2.0](http://www.apache.org/licenses/LICENSE-2.0/).
42+
Except where otherwise explicitly indicated, CoMPAS is an open source project licensed under the [Apache License, version 2.0](http://www.apache.org/licenses/LICENSE-2.0/).
4343

4444
The project requires the use of the [Developer Certificate of Origin (DCO)](https://developercertificate.org/).
4545
The DCO is a legally binding statement asserting that you are you have the right to submit your contribution and to license it under the project's applicable license.
@@ -64,21 +64,21 @@ Note that checks will be performed during the integration in order to require th
6464

6565
## Community refinements
6666

67-
Every monday there is a CoMPAS Community Refinement at 10AM CET. The event is available at the CoMPAS mailing list [calendar](https://lists.lfenergy.org/g/CoMPAS/calendar) and can be subscribed to.
67+
Every Monday there is a CoMPAS Community Refinement at 10AM CET. The event is available at the CoMPAS mailing list [calendar](https://lists.lfenergy.org/g/CoMPAS/calendar) and can be subscribed to.
6868

6969
### Prepared topics
7070

71-
Every friday before the refinement meeting on Monday, all topics are published on the #compas channel on our [LFEnergy Slack](https://lfenergy.slack.com/).
71+
Every Friday before the refinement meeting on Monday, all topics are published on the #compas channel on our [LFEnergy Slack](https://lfenergy.slack.com/).
7272

7373
### Add your own topics
7474

75-
Everybody can suggest topics for the refinement. To do this, join the [LFEnergy Slack](https://lfenergy.slack.com/) if not already, and put your topics in the #compas channel. You can just do this by writing a message like "I want to add something to the refinement this monday, namely..." or add a comment to the already prepared topics if available (see [Prepared topics](#prepared-topics)).
75+
Everybody can suggest topics for the refinement. To do this, join the [LFEnergy Slack](https://lfenergy.slack.com/) if not already, and put your topics in the #compas channel. You can just do this by writing a message like "I want to add something to the refinement this Monday, namely..." or add a comment to the already prepared topics if available (see [Prepared topics](#prepared-topics)).
7676

7777
### Reporting Bugs and Suggesting Enhancements
7878

7979
Bugs and enhancement suggestions are tracked as [GitHub issues](https://guides.github.com/features/issues/). Create an issue in the repository where it belongs (an issue about the CIM to IEC 61850 mapping belongs in the [CIM Mapping repository](https://github.com/com-pas/compas-cim-mapping) for example) and provide the following information by filling in the template, which is either an issue or a bug.
8080

81-
When an issue is created, it is automatically being added to the `To do` column of the specific repository. This means it's added, but not yet refined. Every monday at 10AM CET, there is a Community Refinement (see our mailing list [calendar](https://lists.lfenergy.org/g/CoMPAS/calendar), everybody can join) where issues are being discussed that are not refined yet. Your issue is one of them.
81+
When an issue is created, it is automatically being added to the `To do` column of the specific repository. This means it's added, but not yet refined. Every Monday at 10AM CET, there is a Community Refinement (see our mailing list [calendar](https://lists.lfenergy.org/g/CoMPAS/calendar), everybody can join) where issues are being discussed that are not refined yet. Your issue is one of them.
8282
Once it's accepted and refined, it goes to the `Ready for development` column and it's ready to be implemented/fixed.
8383

8484
Before creating bug reports or suggesting enhancement, please **perform a [cursory search](https://github.com/search?q=+is%3Aissue+user%3Acom-pas)**
@@ -118,8 +118,8 @@ Continuous integration is set up to run on all branches automatically and will o
118118
### Tools to contribute
119119

120120
Continuous integration is setup automatically on all contributions. However, it's faster to iterate locally to fix problems than waiting for the status checks to finish.
121-
There are many tools that can be used to do the verifications that are enforced by all status checks. The most simple and universal tool is maven, but IDE integrations
122-
can be used to get more immediate feedback. Most of the team uses IntelliJ IDEA, but others IDEs can be used, for exemple the Eclipse IDE.
121+
There are many tools that can be used to do the verifications that are enforced by all status checks. The most simple and universal tool is Maven, but IDE integrations
122+
can be used to get more immediate feedback. Most of the team uses IntelliJ IDEA, but others IDEs can be used, for example the Eclipse IDE.
123123

124124
### Definition of Done
125125

@@ -147,7 +147,7 @@ On the [developing](https://com-pas.github.io/contributing/DEVELOPING.html) page
147147

148148
#### Open Community Calls
149149

150-
It's good to know that every other monday, we are having a so called Open Community Call. Everyone participating in the CoMPAS project can join
150+
It's good to know that every other Monday, we are having a so called Open Community Call. Everyone participating in the CoMPAS project can join
151151
and talk about and ask question about the CoMPAS project.
152152

153153
When the Open Community Calls are taking place, can be found at the [General CoMPAS mailing list calendar](https://lists.lfenergy.org/g/CoMPAS/calendar).
@@ -167,7 +167,7 @@ A good (open source) project requires documentation. We have two places for our
167167

168168
##### LF Energy Wiki
169169

170-
LF Energy has it's own [CoMPAS specific Wiki](https://wiki.lfenergy.org/display/HOME/CoMPAS). This is the place for documenation
170+
LF Energy has it's own [CoMPAS specific Wiki](https://wiki.lfenergy.org/display/HOME/CoMPAS). This is the place for documentation
171171
about CoMPAS in general (like roadmap and the community call agendas).
172172

173173
#### Architecture and technologies
@@ -178,7 +178,7 @@ please check the source code (duh!) and our [CoMPAS Architecture Github Pages](h
178178
### Copyright and Licensing
179179

180180
Copyright and license information is done on per-file basis. We use the specification of [REUSE](https://reuse.software/spec/)
181-
to ensure that copyright information of the project is clear and can be analuzed in an automated fashion.
181+
to ensure that copyright information of the project is clear and can be analyzed in an automated fashion.
182182

183183
Every source code repository within CoMPAS has a Github Action for checking against the REUSE specification.
184184

docs/compas-sct.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ import it in the temporary SCD file
170170
</SCL>
171171
```
172172
Operations can now be realized and validated on this minimal file (which has the same structure as an ICD file).
173-
Any validation on the minimal file guaranties a valid integration of those chunks into the large file.
173+
Any validation on the minimal file guarantees a valid integration of those chunks into the large file.
174174

175175
> **WARNING:** This concern only update/creation operations on SCL file.
176176

pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@
218218
<configuration>
219219
<doctitle>${javadoc.title}</doctitle>
220220
<doclint>${javadoc.lint}</doclint>
221-
<additionalJOption>--no-module-directories</additionalJOption>
222221
</configuration>
223222
</plugin>
224223
</plugins>

sct-app/src/main/java/org/lfenergy/compas/sct/app/package-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
// SPDX-License-Identifier: Apache-2.0
44

55
/**
6-
* <h3>sct-app is a group of automation services</h3>
6+
* <h2>sct-app is a group of automation services</h2>
77
*/
88
package org.lfenergy.compas.sct.app;
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// SPDX-FileCopyrightText: 2023 RTE FRANCE
2+
//
3+
// SPDX-License-Identifier: Apache-2.0
4+
5+
package org.lfenergy.compas.sct.commons.dto;
6+
7+
public enum ExtrefTarget {
8+
SRC_REF, SRC_CB
9+
}

sct-commons/src/main/java/org/lfenergy/compas/sct/commons/dto/SclReport.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,4 @@ public class SclReport {
3939
public boolean isSuccess() {
4040
return sclReportItems.stream().noneMatch(SclReportItem::isFatal);
4141
}
42-
4342
}

sct-commons/src/main/java/org/lfenergy/compas/sct/commons/dto/package-info.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
// SPDX-License-Identifier: Apache-2.0
44

55
/**
6-
* <h3>sct.commons.dto is a group of DTO utils for operating on
6+
* <h2>sct.commons.dto is a group of DTO utils for operating on
77
* {@link org.lfenergy.compas.scl2007b4.model.SCL SCL} services
8-
* </h3>
8+
* </h2>
99
*/
1010
package org.lfenergy.compas.sct.commons.dto;

0 commit comments

Comments
 (0)