From 29834155b0e7fbb62a020545d88a07c2bc9ec0eb Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 00:52:24 +0100 Subject: [PATCH 1/7] Create manual.yml --- .github/workflows/manual.yml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/manual.yml diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml new file mode 100644 index 00000000..0282db1b --- /dev/null +++ b/.github/workflows/manual.yml @@ -0,0 +1,32 @@ +# This is a basic workflow that is manually triggered + +name: Manual workflow + +# Controls when the action will run. Workflow runs when manually triggered using the UI +# or API. +on: + workflow_dispatch: + # Inputs the workflow accepts. + inputs: + name: + # Friendly description to be shown in the UI instead of 'name' + description: 'Person to greet' + # Default value if no value is explicitly provided + default: 'World' + # Input has to be provided for the workflow to run + required: true + # The data type of the input + type: string + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "greet" + greet: + # The type of runner that the job will run on + runs-on: ubuntu-latest + docker: 'ghcr.io/void-linux/void-musl-full:latest' + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Runs a single command using the runners shell + - name: Send greeting + run: echo "Hello ${{ inputs.name }}" From 25907455400a26fdc1f4f7cf2265ddd81ae81417 Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 00:55:27 +0100 Subject: [PATCH 2/7] Update manual.yml --- .github/workflows/manual.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml index 0282db1b..c89829a0 100644 --- a/.github/workflows/manual.yml +++ b/.github/workflows/manual.yml @@ -24,7 +24,8 @@ jobs: greet: # The type of runner that the job will run on runs-on: ubuntu-latest - docker: 'ghcr.io/void-linux/void-musl-full:latest' + container: + image: 'ghcr.io/void-linux/void-musl-full:latest' # Steps represent a sequence of tasks that will be executed as part of the job steps: # Runs a single command using the runners shell From db782de3f33183fcab07f74b5cfb49023f4d67ce Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 07:51:30 +0100 Subject: [PATCH 3/7] Update manual.yml --- .github/workflows/manual.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml index c89829a0..35b0625f 100644 --- a/.github/workflows/manual.yml +++ b/.github/workflows/manual.yml @@ -24,8 +24,8 @@ jobs: greet: # The type of runner that the job will run on runs-on: ubuntu-latest - container: - image: 'ghcr.io/void-linux/void-musl-full:latest' + container: + image: 'ghcr.io/void-linux/void-musl-full:latest' # Steps represent a sequence of tasks that will be executed as part of the job steps: # Runs a single command using the runners shell From f1de8da5f3e53ccfb8ea35f5183730c4991c35ac Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 08:46:15 +0100 Subject: [PATCH 4/7] run linux checks in void musl container --- .github/workflows/ci.yml | 10 +++-- .github/workflows/codeql.yml | 82 ------------------------------------ 2 files changed, 7 insertions(+), 85 deletions(-) delete mode 100644 .github/workflows/codeql.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 25299731..ae5611dd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,9 @@ on: jobs: lint: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest + container: + image: "ghcr.io/void-linux/void-musl-full:latest" steps: - uses: actions/checkout@v3 @@ -20,10 +22,12 @@ jobs: with: { python-version: "3.8" } - name: Install codespell - run: pip3 install codespell + run: | + xbps-install -Suy || xbps-install -u xbps + xbps-install -yu python3-codespell cmake clang - name: Lint - run: cmake -D FORMAT_COMMAND=clang-format-14 -P cmake/lint.cmake + run: cmake -D FORMAT_COMMAND=clang-format -P cmake/lint.cmake - name: Spell check if: always() diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml deleted file mode 100644 index f5741632..00000000 --- a/.github/workflows/codeql.yml +++ /dev/null @@ -1,82 +0,0 @@ -# For most projects, this workflow file will not need changing; you simply need -# to commit it to your repository. -# -# You may wish to alter this file to override the set of languages analyzed, -# or to provide custom queries or build logic. -# -# ******** NOTE ******** -# We have attempted to detect the languages in your repository. Please check -# the `language` matrix defined below to confirm you have the correct set of -# supported CodeQL languages. -# -name: "CodeQL" - -on: - push: - branches: [ "master" ] - pull_request: - # The branches below must be a subset of the branches above - branches: [ "master" ] - schedule: - - cron: '19 3 * * 2' - -jobs: - analyze: - name: Analyze - # Runner size impacts CodeQL analysis time. To learn more, please see: - # - https://gh.io/recommended-hardware-resources-for-running-codeql - # - https://gh.io/supported-runners-and-hardware-resources - # - https://gh.io/using-larger-runners - # Consider using larger runners for possible analysis time improvements. - runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }} - timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }} - permissions: - actions: read - contents: read - security-events: write - - strategy: - fail-fast: false - matrix: - language: [ 'c-cpp' ] - # CodeQL supports [ 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift' ] - # Use only 'java-kotlin' to analyze code written in Java, Kotlin or both - # Use only 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both - # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support - - steps: - - name: Checkout repository - uses: actions/checkout@v3 - - # Initializes the CodeQL tools for scanning. - - name: Initialize CodeQL - uses: github/codeql-action/init@v2 - with: - languages: ${{ matrix.language }} - # If you wish to specify custom queries, you can do so here or in a config file. - # By default, queries listed here will override any specified in a config file. - # Prefix the list here with "+" to use these queries and those in the config file. - - # For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs - # queries: security-extended,security-and-quality - - - # Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift). - # If this step fails, then you should remove it and run the build manually (see below) - - name: Autobuild - uses: github/codeql-action/autobuild@v2 - - # ℹī¸ Command-line programs to run using the OS shell. - # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun - - # If the Autobuild fails above, remove it and uncomment the following three lines. - # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. - - # - run: | - # echo "Run, Build Application using script" - # ./location_of_script_within_repo/buildscript.sh - - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 - with: - category: "/language:${{matrix.language}}" From f6c290f01470b1c1e3153f9b694b5045b64a2d52 Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 08:51:56 +0100 Subject: [PATCH 5/7] up --- .github/workflows/ci.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ae5611dd..b58006da 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,16 +16,14 @@ jobs: image: "ghcr.io/void-linux/void-musl-full:latest" steps: - - uses: actions/checkout@v3 - - - uses: actions/setup-python@v4 - with: { python-version: "3.8" } - - name: Install codespell run: | xbps-install -Suy || xbps-install -u xbps xbps-install -yu python3-codespell cmake clang + - name: Checkout + uses: classabbyamp/treeless-checkout-action@v1 + - name: Lint run: cmake -D FORMAT_COMMAND=clang-format -P cmake/lint.cmake From 9f75adf0c0013565adfbeee8beb85afacde2499b Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 08:54:35 +0100 Subject: [PATCH 6/7] up --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b58006da..a7203b62 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,8 @@ jobs: - name: Install codespell run: | xbps-install -Suy || xbps-install -u xbps - xbps-install -yu python3-codespell cmake clang + xbps-install -yu + xbps-install -y bash grep curl git python3-codespell cmake clang - name: Checkout uses: classabbyamp/treeless-checkout-action@v1 From 3d8b43dbbbdf5c1fe957530f958541a059a5c1cd Mon Sep 17 00:00:00 2001 From: hrzlgnm Date: Fri, 10 Nov 2023 08:59:57 +0100 Subject: [PATCH 7/7] Sanitize on void linux --- .github/workflows/ci.yml | 16 ++++++++++------ .github/workflows/manual.yml | 33 --------------------------------- 2 files changed, 10 insertions(+), 39 deletions(-) delete mode 100644 .github/workflows/manual.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a7203b62..97f455e2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,17 +34,21 @@ jobs: sanitize: needs: [lint] - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest + container: + image: "ghcr.io/void-linux/void-musl-full:latest" - env: { CXX: clang++-15 } + env: { CXX: clang++ } steps: - - uses: actions/checkout@v3 - - name: Install Deps run: | - sudo apt-get update -q - sudo apt-get install ninja-build clang-15 -q -y + xbps-install -Suy || xbps-install -u xbps + xbps-install -yu + xbps-install -y bash git ninja cmake clang + + - name: Checkout + uses: classabbyamp/treeless-checkout-action@v1 - name: Configure run: >- diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml deleted file mode 100644 index 35b0625f..00000000 --- a/.github/workflows/manual.yml +++ /dev/null @@ -1,33 +0,0 @@ -# This is a basic workflow that is manually triggered - -name: Manual workflow - -# Controls when the action will run. Workflow runs when manually triggered using the UI -# or API. -on: - workflow_dispatch: - # Inputs the workflow accepts. - inputs: - name: - # Friendly description to be shown in the UI instead of 'name' - description: 'Person to greet' - # Default value if no value is explicitly provided - default: 'World' - # Input has to be provided for the workflow to run - required: true - # The data type of the input - type: string - -# A workflow run is made up of one or more jobs that can run sequentially or in parallel -jobs: - # This workflow contains a single job called "greet" - greet: - # The type of runner that the job will run on - runs-on: ubuntu-latest - container: - image: 'ghcr.io/void-linux/void-musl-full:latest' - # Steps represent a sequence of tasks that will be executed as part of the job - steps: - # Runs a single command using the runners shell - - name: Send greeting - run: echo "Hello ${{ inputs.name }}"