bonitasoft / bonita-documentation-site

The sources of the Bonita Documentation site
https://documentation.bonitasoft.com/
GNU General Public License v2.0
9 stars 5 forks source link

feat(script): add a new option to fail the preview on warning #596

Closed tbouffard closed 1 year ago

tbouffard commented 1 year ago

In most branches of repositories documentation content, no warning is generated. Warnings are generally due to wrong AsciiDoc attribute expansion and we should enforce that no new warning is added. So, the preview script allows to set the Antora failure_level to warn to make the build fail on warning. The action used to build and publish the preview and the reference validation now allow to fail on warning.

Tasks

bcd 3.6 warnings

[13:22:36.231] WARN (asciidoctor): skipping reference to missing attribute: bonita_gid
    file: modules/ROOT/pages/bcd_controller.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)
[13:22:36.231] WARN (asciidoctor): skipping reference to missing attribute: bonita_uid
    file: modules/ROOT/pages/bcd_controller.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)
[13:22:36.232] WARN (asciidoctor): skipping reference to missing attribute: bonita_gid
    file: modules/ROOT/pages/bcd_controller.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)
[13:22:36.388] WARN (asciidoctor): skipping reference to missing attribute: bonita_version
    file: modules/ROOT/pages/livingapp_build_and_deploy_without_docker.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)
[13:22:36.389] WARN (asciidoctor): skipping reference to missing attribute: bonita_version
    file: modules/ROOT/pages/livingapp_build_and_deploy_without_docker.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)
[13:22:36.392] WARN (asciidoctor): skipping reference to missing attribute: deployer_version
    file: modules/ROOT/pages/livingapp_build_and_deploy_without_docker.adoc
    source: https://github.com/bonitasoft/bonita-continuous-delivery-doc.git (branch: ci/simplify_xref_validation)

bonita-test-toolkit asccidoctor info --> xref problems

The job and the step in the workflow should be rename into "validate xref" for consistency with the workflow in the other repositories.

 [12:25:39.944] INFO (asciidoctor): possible invalid reference: _retrieve_contracts_from_files
    file: modules/ROOT/pages/contract.adoc
    source: https://github.com/bonitasoft/bonita-test-toolkit-doc.git (branch: ci/simplify_xref_validation)
[12:25:39.947] INFO (asciidoctor): possible invalid reference: _retrieve_contracts_from_files
    file: modules/ROOT/pages/contract.adoc
    source: https://github.com/bonitasoft/bonita-test-toolkit-doc.git (branch: ci/simplify_xref_validation)
[12:25:40.066] INFO (asciidoctor): possible invalid reference: _task_predicates
    file: modules/ROOT/pages/task.adoc
    source: https://github.com/bonitasoft/bonita-test-toolkit-doc.git (branch: ci/simplify_xref_validation)
github-actions[bot] commented 1 year ago

:recycle: PR Preview baed3223d9e1e64108792ab9e06c02a32519d38b has been successfully destroyed since this PR has been closed.

🤖 By surge-preview

github-actions[bot] commented 1 year ago

:recycle: PR Preview baed3223d9e1e64108792ab9e06c02a32519d38b has been successfully destroyed since this PR has been closed.

🤖 By surge-preview

sonarcloud[bot] commented 1 year ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication