# Lists of paths for artifacts of various stages.

.doxygen_log_artifacts:
    artifacts:
        expire_in: 1 day
        # Because build logs are in here, we should always upload artifacts.
        when: always
        paths:
            - compile_output.log
            - doxygen_output.log
            - prepare_output.log
            - build/CMakeCache.txt
            - build/Documentation/ParaViewGeneratedDocs.tar.gz

.cmake_translations_artifacts:
    artifacts:
        expire_in: 1d
        when: always
        paths:
            # Translations source files
            - translations/*.ts

.cmake_build_artifacts:
    artifacts:
        expire_in: 1d
        # Because build logs are in here, we should always upload artifacts.
        when: always
        paths:
            # Logs of the build
            - compile_output.log

            # The artifacts of the build.
            - build/bin/
            - build/lib/
            - build/VTK/Utilities/KWIML/vtkkwiml/test/kwiml_test
            - build/VTK/Utilities/KWIML/vtkkwiml/test/kwiml_test.exe

            # Python packages go here
            - build/lib64/

            # Needed for installation.
            - build/CMakeCache.txt
            - build/build.ninja
            - build/rules.ninja
            - build/CMakeFiles/rules.ninja
            - build/Clients/ParaView/Documentation/paraview.qch
            - build/cmake_install.cmake
            - build/**/cmake_install.cmake

            # CTest files.
            - build/CTestCustom.cmake
            - build/VTK/CTestCustom.cmake
            - build/CTestTestfile.cmake
            - build/**/CTestTestfile.cmake
            - build/**/*.h
            - build/**/*.hxx
            - build/**/*.mod
            - build/ExternalData/
            - build/Testing/
            - build/Testing/Temporary/
            - build/Clients/ParaView/Testing/XML/

            # CDash files.
            - build/DartConfiguration.tcl

            # Virtual environment
            - build/ci-venv/

            # proj.db
            - build/share/vtk-*/proj/proj.db

            # translation source files
            - translations/*.ts

            # SPDX files
            - build/**/*.spdx
            - build/cdash-build-id
        reports:
            annotations:
                - build/annotations.json

.cmake_test_artifacts:
    artifacts:
        expire_in: 1d
        # Tests failing should still upload the artifact for further testing.
        when: always
        reports:
            junit:
                - build/junit.xml
            annotations:
                - build/annotations.json
        paths:
            # Debugging logs
            - build/Testing/Temporary/Last*.log

.cmake_doxygen_artifacts:
    artifacts:
        expire_in: 1d
        when: always
        paths:
            - compile_output.log
            - doxygen_output.log

.cmake_tidy_artifacts:
    artifacts:
        expire_in: 1d
        # Because build logs are in here, we should always upload artifacts.
        when: always
        paths:
            # Logs of the build
            - compile_output.log
            - build/cdash-build-id
        reports:
            annotations:
                - build/annotations.json
