Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
fd3b922
feat (generator): add symfony config files
bou3108 Nov 26, 2025
6c8fdb4
feat (generator): add symfony to automatic-generator script
bou3108 Nov 26, 2025
0bc75b7
feat (generator): add symfony model github actions
bou3108 Nov 26, 2025
9a76cf0
fix (ci): fix PR versioning to be ruby & python compliant
bou3108 Nov 26, 2025
882d38b
feat (ci): add file to trigger ci
bou3108 Nov 30, 2025
3d44a68
⚙️ Auto-génération des classes et des specs
bou3108 Nov 30, 2025
8a323cd
fix (ci): let "-" char to be pep compliant
bou3108 Nov 30, 2025
ce04565
⚙️ Auto-génération des classes et des specs
bou3108 Nov 30, 2025
dc32d08
⚙️ Auto-génération des librairies
bou3108 Nov 30, 2025
76727af
fix (php) : fix config file
bou3108 Dec 2, 2025
ee5987f
fix (php) : add RS-ERROR & RC-DE templates & config
bou3108 Dec 2, 2025
9452d9b
feat (php) : add EDXL non generated classes
bou3108 Dec 2, 2025
2ec667a
⚙️ Auto-génération des classes et des specs
bou3108 Dec 2, 2025
6715368
feat (php) : refresh symfony config
bou3108 Dec 2, 2025
6d5d9cb
feat (php) : regenrate symfony classes
bou3108 Dec 2, 2025
47c1582
feat (php) : add composer.json
bou3108 Dec 2, 2025
363526e
⚙️ Auto-génération des classes et des specs
bou3108 Dec 2, 2025
be5d915
feat (php) : generate edxl package with openapi
bou3108 Dec 2, 2025
f2a0d5a
⚙️ Auto-génération des classes et des specs
bou3108 Dec 2, 2025
aa5aa68
feat (php) : add EDXL-DE config files
bou3108 Dec 2, 2025
32ff740
⚙️ Auto-génération des classes et des specs
bou3108 Dec 2, 2025
3862f05
fix (php) : rm comment
bou3108 Dec 2, 2025
f9f90e4
⚙️ Auto-génération des classes et des specs
bou3108 Dec 2, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"name": "🏃", "description": "Run Docker container to upload Python distribution packages to PyPI", "inputs": {"user": {"description": "PyPI user", "required": false}, "password": {"description": "Password for your PyPI user or an access token", "required": false}, "repository-url": {"description": "The repository URL to use", "required": false}, "packages-dir": {"description": "The target directory for distribution", "required": false}, "verify-metadata": {"description": "Check metadata before uploading", "required": false}, "skip-existing": {"description": "Do not fail if a Python package distribution exists in the target package index", "required": false}, "verbose": {"description": "Show verbose output.", "required": false}, "print-hash": {"description": "Show hash values of files to be uploaded", "required": false}, "attestations": {"description": "[EXPERIMENTAL] Enable experimental support for PEP 740 attestations. Only works with PyPI and TestPyPI via Trusted Publishing.", "required": false}}, "runs": {"using": "docker", "image": "docker://ghcr.io/pypa/gh-action-pypi-publish:release-v1"}}
27 changes: 22 additions & 5 deletions .github/workflows/generate-libs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,16 @@ jobs:
COMMIT_SHA="${{ github.event.workflow_run.head_sha }}"
SHORT_COMMIT_SHA=${COMMIT_SHA::7}
# Remplace le "+" par "-" et les autres caractères non autorisés par des "."
SAFE_BRANCH=$(echo "${{ github.event.workflow_run.head_branch }}" | sed 's/[^a-zA-Z0-9]/./g')
RELEASE_VERSION="0.0.0-${SAFE_BRANCH}.$SHORT_COMMIT_SHA.${{ github.run_attempt }}"
SAFE_BRANCH=$(echo "${{ github.event.workflow_run.head_branch }}" | sed 's/[^a-zA-Z0-9]/-/g')
RELEASE_VERSION="0.0.0.dev${{ github.run_attempt }}-${SAFE_BRANCH}-$SHORT_COMMIT_SHA-${{ github.run_attempt }}"

else
echo "Workflow triggered via unsupported event"
exit 1
fi

# Make the RELEASE_VERSION semver compatible (replacing non letter/digit/./+ chars with .)
RELEASE_VERSION=$(echo "$RELEASE_VERSION" | sed 's/[^a-zA-Z0-9\.\+]/./g')
# Make the RELEASE_VERSION semver compatible (replacing non letter/digit/./+/- chars with .)
RELEASE_VERSION=$(echo "$RELEASE_VERSION" | sed 's/[^a-zA-Z0-9\.\+\-]/./g')

# Display the RELEASE_VERSION for verification
echo "The RELEASE_VERSION is: $RELEASE_VERSION"
Expand All @@ -78,8 +78,9 @@ jobs:

- name: Cleaning output directories
run: |
rm -r generator_ruby/gem/ generator_python/package/ generator_csharp/package/ || true
rm -r generator_ruby/gem/ generator_python/package/ generator_csharp/package/ generator_php-symfony/package || true

# Python
- name: Python - Generate classes
working-directory: ./generator_python
run: |
Expand Down Expand Up @@ -153,6 +154,7 @@ jobs:
with:
packages-dir: ./generator_python/package/dist/

# Ruby
- name: Ruby - Generate classes
working-directory: ./generator_ruby
run: |
Expand Down Expand Up @@ -205,6 +207,7 @@ jobs:
env:
GEM_HOST_API_KEY: ${{ secrets.GITHUB_TOKEN }} # GitHub token used to authenticate

# C#
- name: C# - Generate classes
working-directory: ./generator_csharp
run: |
Expand Down Expand Up @@ -247,6 +250,20 @@ jobs:
# run: |
# dotnet nuget push bin/Release/*.nupkg --source https://nuget.pkg.github.com/ansforge/index.json --api-key ${{ secrets.GITHUB_TOKEN }}

# Php-symfony
- name: PHP - Generate classes
working-directory: ./generator_php-symfony
run: |
# Iterate over each file in the ./config directory, including the entire subfolder structure
# and then run @openapitools/openapi-generator-cli generate for each file found
# Important notice:
# Results of the find command are sorted in an alphabetic order before being passed to xargs
# This means that since the order of class generation is important, it's necessary to maintain an adequately
# named file structure in the ./config/** directories
# generator-config.json (if exists) -> usecase.generator-config.json -> wrapper.generator-config.json
# Add "| head -n 1" after sort for faster iterations while developing
find ./config/ -type f | sort -n | while read -r file; do npx @openapitools/openapi-generator-cli generate -c "$file" --skip-validate-spec; done

- name: Commit and push changes
if: ${{ !env.ACT }}
uses: stefanzweifel/git-auto-commit-action@v5
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/generate-model.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -103,14 +103,21 @@ jobs:
./automatic-generator.sh

# Move generated OpenAPI config files to the corresponding locations
# Java
rm -r ../generator/config/generated || true
rsync -a --remove-source-files output/generator ..
# Ruby
rm -r ../generator_ruby/config/generated || true
rsync -a --remove-source-files output/generator_ruby ..
# python
rm -r ../generator_python/config/generated || true
rsync -a --remove-source-files output/generator_python ..
# C#
rm -r ../generator_csharp/config/generated || true
rsync -a --remove-source-files output/generator_csharp ..
# php-symfony
rm -r ../generator_php-symfony/config/generated || true
rsync -a --remove-source-files output/generator_php-symfony ..

# Move generated EDXL-DE and JSON Schemas to the corresponding locations
rsync -a --remove-source-files output/edxl ../src/main/java/com/hubsante/model
Expand Down
8 changes: 7 additions & 1 deletion automatic-schema-generator/automatic-generator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,16 @@
# required for each schema

# Generate config files for each language
for lang in "." "ruby" "python" "csharp"; do
for lang in "." "ruby" "python" "csharp" "php-symfony"; do
# generate base generator config files
gomplate -f "./templates/$lang/schema.generator-config.json.tmpl" -d config=./schemas.yaml

# generate usecase and wrapper overwrite configs only for Java
if [ "$lang" == "php-symfony" ]; then
# generate wrapper config files
gomplate -f "./templates/$lang/schema.wrapper.generator-config.json.tmpl" -d config=./schemas.yaml
fi

# generate usecase and wrapper overwrite configs only for Java
if [ "$lang" == "." ]; then
# generate usecase config files
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{{ define "generator-config" }}{
"inputSpec": "../generator/input/{{.schema}}.openapi.yaml",
"outputDir": "package/",
"generatorName": "php-symfony",
"globalProperties": {
"models": "",
"apis": false,
"apiTests": false,
"apiDocs": false,
"modelDocs": false,
"modelTests": false
},
"additionalProperties": {
"invokerPackage": "Hubsante",
"modelPackage": "Model\\{{.package}}",
"packageName": "hubsante_model.{{ .package }}",
"srcBasePath": "src/",
"composerVendorName": "hubsante",
"composerProjectName": "model-sdk",
"variableNamingConvention": "camelCase",
"useStrictTypes": true,
"useEnumCaseInsensitive": false,
"phpVersion": "8.3",
"legacyDiscriminatorBehavior": false,
"generateModelTests": false,
"generateModelDocumentation": false,
"withInterfaces": true,
"withAbstractClasses": false,
"allowUnicodeIdentifiers": true
}
}
{{ end }}
{{- range (datasource "config").schemas }}
{{ if and (eq .automaticGeneration "Y") (eq .subschema "N") }}
{{- tmpl.Exec "generator-config" . | file.Write (printf "output/generator_php-symfony/config/generated/%s/%s.generator-config.json" .schema .schema) }}
{{end}}
{{end}}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{{ define "wrapper.generator-config" }}{
"inputSpec": "../generator/input/{{.schema}}.openapi.yaml",
"outputDir": "package/",
"generatorName": "php-symfony",
"templateDir": "./config/templates/wrapper",
"globalProperties": {
"models": "{{.rootElement}}Wrapper",
"apis": false,
"apiTests": false,
"apiDocs": false,
"modelDocs": false,
"modelTests": false
},
"additionalProperties": {
"invokerPackage": "Hubsante",
"modelPackage": "Model\\{{.package}}",
"packageName": "hubsante_model.{{ .package }}",
"srcBasePath": "src/",
"composerVendorName": "hubsante",
"composerProjectName": "model-sdk",
"variableNamingConvention": "camelCase",
"useStrictTypes": true,
"useEnumCaseInsensitive": false,
"phpVersion": "8.3",
"legacyDiscriminatorBehavior": false,
"generateModelTests": false,
"generateModelDocumentation": false,
"withInterfaces": true,
"withAbstractClasses": false,
"allowUnicodeIdentifiers": true
}
}
{{ end }}
{{- range (datasource "config").schemas }}
{{ if eq .automaticGeneration "Y" }}
{{- tmpl.Exec "wrapper.generator-config" . | file.Write (printf "output/generator_php-symfony/config/generated/%s/%s.wrapper.generator-config.json" .schema .schema) }}
{{end}}
{{end}}
Empty file added csv_parser/models/.gitkeep
Empty file.
Binary file modified csv_parser/out/EMSI/EMSI.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/EMSI/EMSI.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/GEO-POS/GEO-POS.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/GEO-POS/GEO-POS.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/GEO-REQ/GEO-REQ.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/GEO-REQ/GEO-REQ.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/GEO-RES/GEO-RES.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/GEO-RES/GEO-RES.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RC-DE/RC-DE.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RC-DE/RC-DE.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RC-EDA/RC-EDA.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RC-EDA/RC-EDA.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RC-REF/RC-REF.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RC-REF/RC-REF.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RC-RI/RC-RI.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RC-RI/RC-RI.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-BPV/RS-BPV.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-BPV/RS-BPV.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-DR/RS-DR.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-DR/RS-DR.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-EDA-MAJ/RS-EDA-MAJ.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-EDA-MAJ/RS-EDA-MAJ.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-EDA/RS-EDA.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-EDA/RS-EDA.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-ER/RS-ER.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-ER/RS-ER.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-ERROR/RS-ERROR.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-ERROR/RS-ERROR.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-RI/RS-RI.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-RI/RS-RI.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-RPIS/RS-RPIS.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-RPIS/RS-RPIS.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-RR/RS-RR.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-RR/RS-RR.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-SAS-RDV/RS-SAS-RDV.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-SAS-RDV/RS-SAS-RDV.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-SR/RS-SR.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-SR/RS-SR.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/RS-URL/RS-URL.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/RS-URL/RS-URL.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/TECHNICAL/TECHNICAL.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/TECHNICAL/TECHNICAL.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/TECHNICAL_NOREQ/TECHNICAL_NOREQ.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/TECHNICAL_NOREQ/TECHNICAL_NOREQ.uml_diagram.pdf
Binary file not shown.
Binary file modified csv_parser/out/customContent/customContent.schema.docx
Binary file not shown.
Binary file modified csv_parser/out/customContent/customContent.uml_diagram.pdf
Binary file not shown.
100 changes: 100 additions & 0 deletions generator/input/EDXL-DE.openapi.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
openapi: 3.0.0
components:
schemas:
EdxlMessage:
properties:
distributionID:
type: string
senderID:
type: string
dateTimeSent:
type: string
format: date-time
dateTimeExpires:
type: string
format: date-time
distributionStatus:
$ref: '#/components/schemas/DistributionStatus'
distributionKind:
$ref: '#/components/schemas/DistributionKind'
descriptor:
$ref: '#/components/schemas/Descriptor'
content:
$ref: '#/components/schemas/Content'
additionalProperties: false
required:
- distributionID
- senderID
- dateTimeSent
- dateTimeExpires
- distributionStatus
- distributionKind
- descriptor
- content
DistributionStatus:
type: string
enum:
- Actual
- Exercise
- System
- Test
- Unknown
- NoAppropriateDefault
DistributionKind:
type: string
enum:
- Report
- Update
- Cancel
- Request
- Response
- Dispatch
- Ack
- Error
- SensorConfiguration
- SensorControl
- SensorStatus
- SensorDetection
- Unknown
- NoAppropriateDefault
Descriptor:
properties:
language:
type: string
explicitAddress:
$ref: '#/components/schemas/ExplicitAddress'
additionalProperties: false
required:
- language
- explicitAddress
ExplicitAddress:
properties:
explicitAddressScheme:
type: string
explicitAddressValue:
type: string
additionalProperties: false
required:
- explicitAddressScheme
- explicitAddressValue
Content:
properties:
contentObject:
$ref: '#/components/schemas/ContentObject'
additionalProperties: false
required:
- contentObject
ContentObject:
properties:
jsonContent:
$ref: '#/components/schemas/JsonContent'
JsonContent:
properties:
embeddedJsonContent:
$ref: '#/components/schemas/EmbeddedJsonContent'
EmbeddedJsonContent:
properties:
message:
$ref: '#/components/schemas/ContentMessage'
ContentMessage:
type: object
Loading