165042b18Sopenharmony_ciname: "CodeQL"
265042b18Sopenharmony_ci
365042b18Sopenharmony_cion:
465042b18Sopenharmony_ci  push:
565042b18Sopenharmony_ci    branches: [main]
665042b18Sopenharmony_ci  pull_request:
765042b18Sopenharmony_ci    # The branches below must be a subset of the branches above
865042b18Sopenharmony_ci    branches: [master]
965042b18Sopenharmony_ci  schedule:
1065042b18Sopenharmony_ci    - cron: '0 15 * * 5'
1165042b18Sopenharmony_ci
1265042b18Sopenharmony_cijobs:
1365042b18Sopenharmony_ci  analyze:
1465042b18Sopenharmony_ci    name: Analyze
1565042b18Sopenharmony_ci    runs-on: ubuntu-latest
1665042b18Sopenharmony_ci
1765042b18Sopenharmony_ci    strategy:
1865042b18Sopenharmony_ci      fail-fast: false
1965042b18Sopenharmony_ci      matrix:
2065042b18Sopenharmony_ci        # Override automatic language detection by changing the below list
2165042b18Sopenharmony_ci        # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python']
2265042b18Sopenharmony_ci        language: ['cpp']
2365042b18Sopenharmony_ci        # Learn more...
2465042b18Sopenharmony_ci        # https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection
2565042b18Sopenharmony_ci
2665042b18Sopenharmony_ci    steps:
2765042b18Sopenharmony_ci    - name: Checkout repository
2865042b18Sopenharmony_ci      uses: actions/checkout@v3
2965042b18Sopenharmony_ci      with:
3065042b18Sopenharmony_ci        # We must fetch at least the immediate parents so that if this is
3165042b18Sopenharmony_ci        # a pull request then we can checkout the head.
3265042b18Sopenharmony_ci        fetch-depth: 2
3365042b18Sopenharmony_ci
3465042b18Sopenharmony_ci    # If this run was triggered by a pull request event, then checkout
3565042b18Sopenharmony_ci    # the head of the pull request instead of the merge commit.
3665042b18Sopenharmony_ci    #- run: git checkout HEAD^2
3765042b18Sopenharmony_ci    #  if: ${{ github.event_name == 'pull_request' }}
3865042b18Sopenharmony_ci
3965042b18Sopenharmony_ci    # Initializes the CodeQL tools for scanning.
4065042b18Sopenharmony_ci    - name: Initialize CodeQL
4165042b18Sopenharmony_ci      uses: github/codeql-action/init@v1
4265042b18Sopenharmony_ci      with:
4365042b18Sopenharmony_ci        languages: ${{ matrix.language }}
4465042b18Sopenharmony_ci
4565042b18Sopenharmony_ci    # Autobuild attempts to build any compiled languages  (C/C++, C#, or Java).
4665042b18Sopenharmony_ci    # If this step fails, then you should remove it and run the build manually (see below)
4765042b18Sopenharmony_ci    #- name: Autobuild
4865042b18Sopenharmony_ci    #  uses: github/codeql-action/autobuild@v1
4965042b18Sopenharmony_ci
5065042b18Sopenharmony_ci    # ℹ️ Command-line programs to run using the OS shell.
5165042b18Sopenharmony_ci    # � https://git.io/JvXDl
5265042b18Sopenharmony_ci
5365042b18Sopenharmony_ci    # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
5465042b18Sopenharmony_ci    #    and modify them (or add more) to build your code if your project
5565042b18Sopenharmony_ci    #    uses a compiled language
5665042b18Sopenharmony_ci
5765042b18Sopenharmony_ci    - run: |
5865042b18Sopenharmony_ci       cmake -B build -D ELFIO_BUILD_EXAMPLES=ON
5965042b18Sopenharmony_ci       cmake --build build
6065042b18Sopenharmony_ci
6165042b18Sopenharmony_ci    - name: Perform CodeQL Analysis
6265042b18Sopenharmony_ci      uses: github/codeql-action/analyze@v1
63