You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ja...@apache.org on 2026/10/19 08:10:51 UTC

(mynewt-newt) branch master updated (498f097f -> 6c259c7a)

This is an automated email from the ASF dual-hosted git repository.

sjanc pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newt.git


    from 498f097f newt/builder: Fix crash if project doesn't use apache-mynewt-core
     new 875a8889 ci: Run CodeQL only on schedule
     new dc596b98 ci: Pin apache-mynewt-core release in sysinit test
     new 22f5f88f ci: Clone only needed repositories in commands test
     new 6c259c7a ci: Merge test workflows into single workflow

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../mynewt => .github/newt_commands}/project.yml   |  22 +--
 .../mynewt => .github/newt_sysinit}/project.yml    |  21 +--
 .github/workflows/ci.yml                           | 154 +++++++++++++++++++++
 .github/workflows/codeql.yml                       | 113 +++++----------
 .github/workflows/test_commands.yml                |  97 -------------
 .github/workflows/test_sysinit.yml                 |  61 --------
 .github/workflows/test_unit.yml                    |  41 ------
 README.md                                          |   8 +-
 8 files changed, 214 insertions(+), 303 deletions(-)
 copy {newt/testdata/dump/proj/repos/mcuboot/testplan/mynewt => .github/newt_commands}/project.yml (75%)
 copy {newt/testdata/dump/proj/repos/mcuboot/testplan/mynewt => .github/newt_sysinit}/project.yml (70%)
 create mode 100644 .github/workflows/ci.yml
 delete mode 100644 .github/workflows/test_commands.yml
 delete mode 100644 .github/workflows/test_sysinit.yml
 delete mode 100644 .github/workflows/test_unit.yml


(mynewt-newt) 04/04: ci: Merge test workflows into single workflow

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sjanc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newt.git

commit 6c259c7ac3b3657b768a74104a81fa5564dab41f
Author: Szymon Janc <sz...@codecoup.pl>
AuthorDate: Fri Oct 16 22:06:45 2026 +0200

    ci: Merge test workflows into single workflow
    
    Run unit tests, the sysinit test and the commands test as jobs of one
    CI workflow, with 6 jobs in total, well within the ASF limit of 20
    concurrent jobs per workflow.
    
    The sysinit test runs as part of the integration job, before the
    commands test. The commands test is split into steps, so failures and
    time spent are easier to find.
    
    Run on push to master only, as pull requests from repository branches
    were tested twice. Cancel runs superseded by a newer push, limit the
    token to reading contents and add job timeouts.
    
    Assisted-by: Claude:claude-opus-5-5
---
 .github/workflows/ci.yml            | 154 ++++++++++++++++++++++++++++++++++++
 .github/workflows/test_commands.yml |  97 -----------------------
 .github/workflows/test_sysinit.yml  |  53 -------------
 .github/workflows/test_unit.yml     |  41 ----------
 README.md                           |   8 +-
 5 files changed, 156 insertions(+), 197 deletions(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 00000000..b7256e82
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,154 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+name: CI
+
+on:
+  push:
+    branches: [master]
+  pull_request:
+  workflow_dispatch:
+
+permissions:
+  contents: read
+
+concurrency:
+  group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
+  cancel-in-progress: true
+
+defaults:
+  run:
+    shell: bash
+
+jobs:
+  unit:
+    name: Unit tests (${{ matrix.os }})
+    strategy:
+      fail-fast: false
+      matrix:
+        os: [ubuntu-latest, windows-latest, macos-latest]
+    runs-on: ${{ matrix.os }}
+    timeout-minutes: 20
+    steps:
+      - uses: actions/checkout@v7
+      - uses: actions/setup-go@v7
+        with:
+          go-version: 'stable'
+      - name: Run tests
+        run: |
+          go version
+          go test -v ./newt
+
+  integration:
+    name: Integration tests (${{ matrix.os }})
+    strategy:
+      fail-fast: false
+      matrix:
+        os: [ubuntu-latest, windows-latest, macos-latest]
+    runs-on: ${{ matrix.os }}
+    timeout-minutes: 45
+    steps:
+      - uses: actions/checkout@v7
+      - uses: actions/setup-go@v7
+        with:
+          go-version: 'stable'
+      - uses: carlosperate/arm-none-eabi-gcc-action@v1.14.0
+        with:
+          release: '12.2.Rel1'
+      - name: Install dependencies
+        if: matrix.os == 'ubuntu-latest'
+        run: |
+          sudo apt-get update
+          sudo apt-get install -y gcc-multilib
+      - name: Build newt
+        working-directory: newt
+        run: |
+          go version
+          go build
+          echo ${GITHUB_WORKSPACE}/newt >> $GITHUB_PATH
+
+      - name: Sysinit configuration
+        run: |
+          cp -r .github/newt_sysinit sysinit
+          cp -r .github/targets sysinit/targets
+          cd sysinit
+          newt upgrade -v --shallow=1
+          newt info
+          newt target sysinit brief nordic_pca10056_btshell > tmp.txt
+          diff -w tmp.txt expected.txt
+
+      - name: Create project
+        run: |
+          newt
+          newt help
+          newt version
+          newt new project
+          cp .github/newt_commands/project.yml project/
+          cp -r .github/targets/nordic_pca10056_btshell project/targets
+      - name: Upgrade project
+        working-directory: project
+        run: |
+          newt upgrade -v --escape=false apache-mynewt-core apache-mynewt-nimble
+          newt info
+      - name: Build target
+        working-directory: project
+        run: |
+          newt build nordic_pca10056_btshell
+          newt create-image nordic_pca10056_btshell 1.0.0
+          newt size nordic_pca10056_btshell
+          newt size -F -R nordic_pca10056_btshell
+      - name: Package commands
+        working-directory: project
+        run: |
+          newt vals api app bsp build_profile compiler lib sdk target
+          newt pkg new --type=pkg sys/mylib
+          newt pkg copy apps/blinky apps/myapp
+          newt pkg move apps/myapp apps/newapp
+          newt pkg remove apps/newapp
+      - name: Target commands
+        working-directory: project
+        run: |
+          newt target show
+          newt target create my_target1
+          newt target set my_target1 bsp=@apache-mynewt-core/hw/bsp/nordic_pca10056
+          newt target set my_target1 app=apps/blinky
+          newt target set my_target1 build_profile=optimized cflags="-DNDEBUG"
+          newt target set my_target1 syscfg=LOG_NEWTMGR=1:CONFIG_NEWTMGR=0
+          newt target config init -f my_target1
+          newt target copy my_target1 my_target2
+          newt target amend my_target1 lflags="-Lmylib" syscfg=LOG_LEVEL=0:CONFIG_NEWTMGR=0
+          newt target delete -f my_target1
+          newt target delete -f my_target2
+          newt target cmake nordic_pca10056_btshell
+          newt target dep nordic_pca10056_btshell
+          newt target revdep nordic_pca10056_btshell
+      - name: Upgrade installed project
+        working-directory: project
+        run: |
+          newt upgrade -v
+          rm -rf repos/apache-mynewt-nimble
+          newt upgrade -v
+          test -d repos/apache-mynewt-nimble/nimble
+      - name: Unit test and simulator build
+        if: matrix.os == 'ubuntu-latest'
+        working-directory: project
+        run: |
+          newt test @apache-mynewt-core/util/cbmem
+          newt build my_blinky_sim
+          newt clean my_blinky_sim
diff --git a/.github/workflows/test_commands.yml b/.github/workflows/test_commands.yml
deleted file mode 100644
index 46440e17..00000000
--- a/.github/workflows/test_commands.yml
+++ /dev/null
@@ -1,97 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#  http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-name: Test commands
-
-on: [push, pull_request]
-
-jobs:
-  test_commands:
-    name: other
-    strategy:
-      fail-fast: false
-      matrix:
-        os: [ubuntu-latest, windows-latest, macos-latest]
-    runs-on: ${{ matrix.os }}
-    steps:
-      - uses: actions/checkout@v7
-      - uses: actions/setup-go@v7
-        with:
-          go-version: 'stable'
-      - uses: carlosperate/arm-none-eabi-gcc-action@v1.14.0
-        with:
-          release: '12.2.Rel1'
-      - name: Install Dependencies
-        if: matrix.os == 'ubuntu-latest'
-        run: |
-             sudo apt-get update
-             sudo apt-get install -y gcc-multilib
-      - name: Build newt
-        working-directory: newt
-        shell: bash
-        run: |
-             go version
-             go build
-             echo  ${GITHUB_WORKSPACE}/newt >> $GITHUB_PATH
-      - name: Test commands
-        shell: bash
-        run: |
-             newt
-             newt help
-             newt version
-             newt new project
-             cp .github/newt_commands/project.yml project/
-             cp -r .github/targets/nordic_pca10056_btshell project/targets
-             cd project/
-             newt upgrade -v --escape=false apache-mynewt-core apache-mynewt-nimble
-             newt info
-             newt build nordic_pca10056_btshell
-             newt create-image nordic_pca10056_btshell 1.0.0
-             newt size nordic_pca10056_btshell
-             newt size -F -R nordic_pca10056_btshell
-             newt vals api app bsp build_profile compiler lib sdk target
-             newt pkg new --type=pkg sys/mylib
-             newt pkg copy apps/blinky apps/myapp
-             newt pkg move apps/myapp apps/newapp
-             newt pkg remove apps/newapp
-             newt target show
-             newt target create my_target1
-             newt target set my_target1 bsp=@apache-mynewt-core/hw/bsp/nordic_pca10056
-             newt target set my_target1 app=apps/blinky
-             newt target set my_target1 build_profile=optimized cflags="-DNDEBUG"
-             newt target set my_target1 syscfg=LOG_NEWTMGR=1:CONFIG_NEWTMGR=0
-             newt target config init -f my_target1
-             newt target copy my_target1 my_target2
-             newt target amend my_target1 lflags="-Lmylib" syscfg=LOG_LEVEL=0:CONFIG_NEWTMGR=0
-             newt target delete -f my_target1
-             newt target delete -f my_target2
-             newt target cmake nordic_pca10056_btshell
-             newt target dep nordic_pca10056_btshell
-             newt target revdep nordic_pca10056_btshell
-             newt upgrade -v
-             rm -rf repos/apache-mynewt-nimble
-             newt upgrade -v
-             test -d repos/apache-mynewt-nimble/nimble
-      - name: Test commands 2
-        if: matrix.os == 'ubuntu-latest'
-        run: |
-             cd project
-             newt test @apache-mynewt-core/util/cbmem
-             newt build my_blinky_sim
-             newt clean my_blinky_sim
diff --git a/.github/workflows/test_sysinit.yml b/.github/workflows/test_sysinit.yml
deleted file mode 100644
index eb0d495c..00000000
--- a/.github/workflows/test_sysinit.yml
+++ /dev/null
@@ -1,53 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#  http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-name: Test sysinit
-
-on: [push, pull_request]
-
-jobs:
-  test_sysinit:
-    name: other
-    strategy:
-      fail-fast: false
-      matrix:
-        os: [ubuntu-latest, windows-latest, macos-latest]
-    runs-on: ${{ matrix.os }}
-    steps:
-      - uses: actions/checkout@v7
-      - uses: actions/setup-go@v7
-        with:
-          go-version: 'stable'
-      - name: Build newt
-        working-directory: newt
-        shell: bash
-        run: |
-             go version
-             go build
-             echo  ${GITHUB_WORKSPACE}/newt >> $GITHUB_PATH
-      - name: Test_sysinit
-        shell: bash
-        run: |
-             cp -r .github/newt_sysinit project
-             cp -r .github/targets project/targets
-             cd project/
-             newt upgrade -v --shallow=1
-             newt info
-             newt target sysinit brief nordic_pca10056_btshell > tmp.txt
-             diff -w tmp.txt expected.txt
diff --git a/.github/workflows/test_unit.yml b/.github/workflows/test_unit.yml
deleted file mode 100644
index 2a93d10d..00000000
--- a/.github/workflows/test_unit.yml
+++ /dev/null
@@ -1,41 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#  http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-name: Unit tests
-
-on: [push, pull_request]
-
-jobs:
-  unit_tests:
-    name: go test
-    strategy:
-      fail-fast: false
-      matrix:
-        os: [ubuntu-latest, windows-latest, macos-latest]
-    runs-on: ${{ matrix.os }}
-    steps:
-      - uses: actions/checkout@v7
-      - uses: actions/setup-go@v7
-        with:
-          go-version: 'stable'
-      - name: Run tests
-        shell: bash
-        run: |
-             go version
-             go test -v ./newt
diff --git a/README.md b/README.md
index 594bde04..918d3fc3 100644
--- a/README.md
+++ b/README.md
@@ -19,12 +19,8 @@
 #
 -->
 
-<a href="https://github.com/apache/mynewt-newt/actions/workflows/test_commands.yml">
-  <img src="https://github.com/apache/mynewt-newt/actions/workflows/test_commands.yml/badge.svg">
-<a/>
-
-<a href="https://github.com/apache/mynewt-newt/actions/workflows/test_unit.yml">
-  <img src="https://github.com/apache/mynewt-newt/actions/workflows/test_unit.yml/badge.svg">
+<a href="https://github.com/apache/mynewt-newt/actions/workflows/ci.yml">
+  <img src="https://github.com/apache/mynewt-newt/actions/workflows/ci.yml/badge.svg">
 <a/>
 
 # Newt


(mynewt-newt) 03/04: ci: Clone only needed repositories in commands test

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sjanc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newt.git

commit 22f5f88f3ad0b5eaeabcf73e14e3c6492d4d6856
Author: Szymon Janc <sz...@codecoup.pl>
AuthorDate: Fri Oct 16 22:01:21 2026 +0200

    ci: Clone only needed repositories in commands test
    
    newt upgrade cloned all apache-mynewt-core dependencies, about 5 GB,
    three times per run. Replace the project.yml created by newt new with
    one that allows only repositories needed to build the test targets.
    The initial upgrade takes 42 seconds instead of 262 locally.
    
    Do not download all repositories again with a shallow clone, the
    sysinit test covers shallow clones now. Remove apache-mynewt-nimble
    instead of apache-mynewt-mcumgr, which is no longer cloned for
    apache-mynewt-core master, to test that a missing repository is
    downloaded again, and check that it was.
    
    Assisted-by: Claude:claude-opus-5-5
---
 .github/newt_commands/project.yml   | 40 +++++++++++++++++++++++++++++++++++++
 .github/workflows/test_commands.yml |  6 +++---
 2 files changed, 43 insertions(+), 3 deletions(-)

diff --git a/.github/newt_commands/project.yml b/.github/newt_commands/project.yml
new file mode 100644
index 00000000..ab2d881e
--- /dev/null
+++ b/.github/newt_commands/project.yml
@@ -0,0 +1,40 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+project.name: "newt_commands"
+
+project.repositories:
+    - apache-mynewt-core
+
+repository.apache-mynewt-core:
+    type: github
+    vers: 0.0.0
+    user: apache
+    repo: mynewt-core
+
+# apache-mynewt-core depends on many repositories, clone only those needed
+# to build the targets used by the tests.
+project.repositories.allowed:
+    - apache-mynewt-core
+    - apache-mynewt-nimble
+    - arm-CMSIS_5
+    - mbedtls
+    - mcuboot
+    - nordic-nrfx
+    - tinycbor
diff --git a/.github/workflows/test_commands.yml b/.github/workflows/test_commands.yml
index 7c3d8207..46440e17 100644
--- a/.github/workflows/test_commands.yml
+++ b/.github/workflows/test_commands.yml
@@ -56,6 +56,7 @@ jobs:
              newt help
              newt version
              newt new project
+             cp .github/newt_commands/project.yml project/
              cp -r .github/targets/nordic_pca10056_btshell project/targets
              cd project/
              newt upgrade -v --escape=false apache-mynewt-core apache-mynewt-nimble
@@ -83,11 +84,10 @@ jobs:
              newt target cmake nordic_pca10056_btshell
              newt target dep nordic_pca10056_btshell
              newt target revdep nordic_pca10056_btshell
-             rm -rf repos
-             newt upgrade --shallow=1
              newt upgrade -v
-             rm -rf repos/apache-mynewt-mcumgr
+             rm -rf repos/apache-mynewt-nimble
              newt upgrade -v
+             test -d repos/apache-mynewt-nimble/nimble
       - name: Test commands 2
         if: matrix.os == 'ubuntu-latest'
         run: |


(mynewt-newt) 01/04: ci: Run CodeQL only on schedule

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sjanc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newt.git

commit 875a88893b78c4bde8535b5d40cbb6afc170e252
Author: Szymon Janc <sz...@codecoup.pl>
AuthorDate: Fri Oct 16 21:58:50 2026 +0200

    ci: Run CodeQL only on schedule
    
    Run the analysis weekly and on demand instead of on every push and
    pull request. Drop the comments from the GitHub workflow template, the
    unused matrix and the permissions only needed by private repositories.
    
    Assisted-by: Claude:claude-opus-5-5
---
 .github/workflows/codeql.yml | 113 +++++++++++++------------------------------
 1 file changed, 33 insertions(+), 80 deletions(-)

diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
index 57bcf531..594ec90e 100644
--- a/.github/workflows/codeql.yml
+++ b/.github/workflows/codeql.yml
@@ -1,93 +1,46 @@
-# 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.
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
 #
-# ******** 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.
+#  http://www.apache.org/licenses/LICENSE-2.0
 #
-name: "CodeQL"
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+name: CodeQL
 
 on:
-  push:
-    branches: [ "master" ]
-  pull_request:
-    branches: [ "master" ]
   schedule:
     - cron: '27 1 * * 0'
+  workflow_dispatch:
+
+permissions:
+  contents: read
 
 jobs:
   analyze:
-    name: Analyze (${{ matrix.language }})
-    # 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 (GitHub.com only)
-    # Consider using larger runners or machines with greater resources for possible analysis time improvements.
-    runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
-    timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
+    name: Analyze (go)
+    runs-on: ubuntu-latest
+    timeout-minutes: 30
     permissions:
-      # required for all workflows
-      security-events: write
-
-      # required to fetch internal or private CodeQL packs
-      packages: read
-
-      # only required for workflows in private repositories
-      actions: read
       contents: read
-
-    strategy:
-      fail-fast: false
-      matrix:
-        include:
-        - language: go
-          build-mode: autobuild
-        # CodeQL supports the following values keywords for 'language': 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift'
-        # Use `c-cpp` to analyze code written in C, C++ or both
-        # Use 'java-kotlin' to analyze code written in Java, Kotlin or both
-        # Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
-        # To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
-        # see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
-        # If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
-        # your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
+      security-events: write
     steps:
-    - name: Checkout repository
-      uses: actions/checkout@v7
-
-    # Initializes the CodeQL tools for scanning.
-    - name: Initialize CodeQL
-      uses: github/codeql-action/init@v4
-      with:
-        languages: ${{ matrix.language }}
-        build-mode: ${{ matrix.build-mode }}
-        # 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
-
-    # If the analyze step fails for one of the languages you are analyzing with
-    # "We were unable to automatically build your code", modify the matrix above
-    # to set the build mode to "manual" for that language. Then modify this step
-    # to build your code.
-    # â„šī¸ 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: matrix.build-mode == 'manual'
-      shell: bash
-      run: |
-        echo 'If you are using a "manual" build mode for one or more of the' \
-          'languages you are analyzing, replace this with the commands to build' \
-          'your code, for example:'
-        echo '  make bootstrap'
-        echo '  make release'
-        exit 1
-
-    - name: Perform CodeQL Analysis
-      uses: github/codeql-action/analyze@v4
-      with:
-        category: "/language:${{matrix.language}}"
+      - uses: actions/checkout@v7
+      - uses: github/codeql-action/init@v4
+        with:
+          languages: go
+          build-mode: autobuild
+      - uses: github/codeql-action/analyze@v4
+        with:
+          category: /language:go


(mynewt-newt) 02/04: ci: Pin apache-mynewt-core release in sysinit test

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sjanc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-newt.git

commit dc596b981e6218836858b234486a72f325f1b732
Author: Szymon Janc <sz...@codecoup.pl>
AuthorDate: Fri Oct 16 21:59:03 2026 +0200

    ci: Pin apache-mynewt-core release in sysinit test
    
    The expected sysinit output had to follow apache-mynewt-core master,
    so any change there broke the test. Use a project with
    apache-mynewt-core pinned to 1.15.0, whose output for the btshell
    target matches the current expected output.
    
    The project allows only repositories with packages used by the
    target, sysinit configuration does not need the sources of others,
    and uses a shallow clone. This takes 16 seconds instead of over four
    minutes for all apache-mynewt-core dependencies. Nothing is built, so
    the toolchain and gcc-multilib are no longer installed.
    
    Assisted-by: Claude:claude-opus-5-5
---
 .github/newt_sysinit/project.yml   | 39 ++++++++++++++++++++++++++++++++++++++
 .github/workflows/test_sysinit.yml | 16 ++++------------
 2 files changed, 43 insertions(+), 12 deletions(-)

diff --git a/.github/newt_sysinit/project.yml b/.github/newt_sysinit/project.yml
new file mode 100644
index 00000000..8046327e
--- /dev/null
+++ b/.github/newt_sysinit/project.yml
@@ -0,0 +1,39 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+project.name: "newt_sysinit"
+
+project.repositories:
+    - apache-mynewt-core
+
+# Pinned to a release, so that the expected output does not change with
+# apache-mynewt-core master.
+repository.apache-mynewt-core:
+    type: github
+    vers: 1.15.0
+    user: apache
+    repo: mynewt-core
+
+# Only repos with packages used by nordic_pca10056_btshell; sysinit
+# configuration does not need the external sources these depend on.
+project.repositories.allowed:
+    - apache-mynewt-core
+    - apache-mynewt-mcumgr
+    - apache-mynewt-nimble
+    - mcuboot
diff --git a/.github/workflows/test_sysinit.yml b/.github/workflows/test_sysinit.yml
index 85700a35..eb0d495c 100644
--- a/.github/workflows/test_sysinit.yml
+++ b/.github/workflows/test_sysinit.yml
@@ -34,14 +34,6 @@ jobs:
       - uses: actions/setup-go@v7
         with:
           go-version: 'stable'
-      - uses: carlosperate/arm-none-eabi-gcc-action@v1.14.0
-        with:
-          release: '12.2.Rel1'
-      - name: Install Dependencies
-        if: matrix.os == 'ubuntu-latest'
-        run: |
-             sudo apt-get update
-             sudo apt-get install -y gcc-multilib
       - name: Build newt
         working-directory: newt
         shell: bash
@@ -52,10 +44,10 @@ jobs:
       - name: Test_sysinit
         shell: bash
         run: |
-             newt new project
-             cp -r .github/targets/nordic_pca10056_btshell project/targets
+             cp -r .github/newt_sysinit project
+             cp -r .github/targets project/targets
              cd project/
-             newt upgrade -v --escape=false apache-mynewt-core apache-mynewt-nimble
+             newt upgrade -v --shallow=1
              newt info
              newt target sysinit brief nordic_pca10056_btshell > tmp.txt
-             diff -w tmp.txt ../.github/newt_sysinit/expected.txt
+             diff -w tmp.txt expected.txt