diff --git a/.github/workflows/continuous_integration.yml b/.github/workflows/continuous_integration.yml index 84bc783..6c48329 100644 --- a/.github/workflows/continuous_integration.yml +++ b/.github/workflows/continuous_integration.yml @@ -184,15 +184,23 @@ env: jobs: lint: name: Lint Repository + needs: + - setup-env runs-on: ${{ inputs.runner }} if: ${{ inputs.run_lint == 'true' }} steps: + - name: Checkout local github actions + uses: actions/checkout@v3 + with: + repository: everest/everest-ci + ref: ${{ needs.setup-env.outputs.sha_reusable_workflow }} + path: everest-ci - name: Checkout repository uses: actions/checkout@v3 with: path: source - name: Run clang-format - uses: everest/everest-ci/github-actions/run-clang-format@v1.3.1 + uses: ./everest-ci/github-actions/run-clang-format with: source-dir: source/${{ inputs.lint_source_dir }} extensions: ${{ inputs.lint_extensions }} @@ -257,7 +265,6 @@ jobs: BUILD_KIT_IMAGE: ${{ needs.build-and-push-build-kit.outputs.one_image_tag_long }} steps: - name: Checkout local github actions - # LTODO check all tags uses: actions/checkout@v3 with: repository: everest/everest-ci @@ -335,7 +342,6 @@ jobs: - name: Deploy html coverage report id: deploy_coverage_report if: ${{ steps.run_coverage.outcome == 'success' || steps.run_coverage.outcome == 'failure' }} - # LTODO update tag uses: ./everest-ci/github-actions/deploy-ci-artifact with: target_repo: ${{ inputs.artifact_deploy_target_repo }} @@ -457,6 +463,12 @@ jobs: # LTODO uncomment # if: ${{ inputs.run_coverage && inputs.do_not_run_coverage_badge_creation == 'false' && inputs.run_coverage == 'true' && github.event_name == 'push' && github.ref == 'refs/heads/main' }} steps: + - name: Checkout local github actions + uses: actions/checkout@v3 + with: + repository: everest/everest-ci + ref: ${{ needs.setup-env.outputs.sha_reusable_workflow }} + path: everest-ci - name: Download xml coverage report uses: actions/download-artifact@v4.1.2 with: @@ -477,13 +489,11 @@ jobs: f.write(f"line_coverage_percentage={float(line_coverage) * 100}\n") - name: Generate coverage badge run: | - # LTODO install in docker image pip install anybadge mkdir -p ${{ github.workspace }}/coverage-badge/ anybadge -o --label Coverage --value ${{ steps.parse_coverage_report.outputs.line_coverage_percentage }} -s "%" --file ${{ github.workspace }}/coverage-badge/coverage-badge.svg 20=red 40=orange 60=yellow 80=yellowgreen 100=green - name: Deploy coverage badge - # LTODO update version - uses: everest/everest-ci/github-actions/deploy-ci-artifact@feature/add-reusable-ci-workflow + uses: ./everest-ci/github-actions/deploy-ci-artifact with: target_repo: ${{ inputs.artifact_deploy_target_repo }} github_token: ${{ secrets.coverage_deploy_token }} @@ -497,13 +507,10 @@ jobs: name: coverage-report path: coverage-report - name: Deploy html coverage report - # LTODO update version - uses: everest/everest-ci/github-actions/deploy-ci-artifact@feature/add-reusable-ci-workflow + uses: ./everest-ci/github-actions/deploy-ci-artifact with: target_repo: ${{ inputs.artifact_deploy_target_repo }} github_token: ${{ secrets.coverage_deploy_token }} artifact_name: coverage-report artifact_directory: ${{ github.workspace }}/coverage-report/ deploy_global_artifact: true - -# LTODO add link to badge