diff --git a/.github/issue_template b/.github/issue_template index 72ff537..2b237e2 100644 --- a/.github/issue_template +++ b/.github/issue_template @@ -1,20 +1,16 @@ -Please make sure that the issue subject starts with `: ` so that it's easily identifiable. +Please make sure that the issue subject starts with `: ` -This repo here is ONLY for packages maintained in this repo. For base packages residing in the same repo as the build system and maintained by core devs, please consider opening tickets there for more timely responses +Also make sure that the package is maintained in this repository and not in base which should be submitted at https://bugs.openwrt.org or in the LuCI repository which should be submitted at https://github.com/openwrt/luci/issues. - - OpenWrt: https://dev.openwrt.org/newticket - - LEDE: https://bugs.lede-project.org/ - - Most LuCI packages: https://github.com/openwrt/luci/issues +Issues related to releases below 18.06 and forks are not supported or maintained and will be closed. -Thanks for your contribution -Please remove this text (before ---) and fill the following template -------------------------------- +# Issue template (remove lines from top till here) -Maintainer: @ (find it by checking history of the package Makefile) -Environment: (put here arch, model, OpenWRT/LEDE version) +Maintainer: @\ (find it by checking history of the package Makefile) +Environment: (put here arch, model, OpenWrt version) Description: ``` -Formating code blocks by wrapping them with pairs of ``` +Format code blocks by wrapping them with pairs of ``` ``` diff --git a/.github/pull_request_template b/.github/pull_request_template index 4114755..4bc4af6 100644 --- a/.github/pull_request_template +++ b/.github/pull_request_template @@ -1,16 +1,5 @@ -Please double check that your commits: -- all start with ": " -- all contain signed-off-by -- are linked to your github account (you see your logo in front of them) - -Please also read https://github.com/openwrt/packages/blob/master/CONTRIBUTING.md - -Thanks for your contribution -Please remove this text (before ---) and fill the following template -------------------------------- - -Maintainer: me / @ -Compile tested: (put here arch, model, OpenWRT/LEDE version) -Run tested: (put here arch, model, OpenWRT/LEDE version, tests done) +Maintainer: me / @\ (find it by checking history of the package Makefile) +Compile tested: (put here arch, model, OpenWrt version) +Run tested: (put here arch, model, OpenWrt version, tests done) Description: diff --git a/.github/workflows/Dockerfile b/.github/workflows/Dockerfile index aa269b7..fbd17fc 100644 --- a/.github/workflows/Dockerfile +++ b/.github/workflows/Dockerfile @@ -1,5 +1,5 @@ ARG ARCH=x86-64 -FROM openwrtorg/rootfs:$ARCH +FROM openwrt/rootfs:$ARCH ADD entrypoint.sh /entrypoint.sh diff --git a/.github/workflows/entrypoint.sh b/.github/workflows/entrypoint.sh index d7d4ecd..7604105 100755 --- a/.github/workflows/entrypoint.sh +++ b/.github/workflows/entrypoint.sh @@ -26,7 +26,7 @@ for PKG in /ci/*.ipk; do if [ -f "$TEST_SCRIPT" ]; then echo "Use package specific test.sh" if sh "$TEST_SCRIPT" "$PKG_NAME" "$PKG_VERSION"; then - echo "Test succesful" + echo "Test successful" else echo "Test failed" exit 1 diff --git a/.github/workflows/multi-arch-test-build.yml b/.github/workflows/multi-arch-test-build.yml index cbd9663..f8a907b 100644 --- a/.github/workflows/multi-arch-test-build.yml +++ b/.github/workflows/multi-arch-test-build.yml @@ -10,21 +10,45 @@ jobs: strategy: fail-fast: false matrix: - arch: - - arc_archs - - arm_cortex-a9_vfpv3-d16 - - mips_24kc - - powerpc_464fp - - powerpc_8540 - runtime_test: [false] include: + - arch: arc_archs + target: archs38-generic + runtime_test: false + + - arch: arm_cortex-a9_vfpv3-d16 + target: mvebu-cortexa9 + runtime_test: false + + - arch: mips_24kc + target: ath79-generic + runtime_test: false + + - arch: mipsel_24kc + target: mt7621 + runtime_test: false + + - arch: powerpc_464fp + target: apm821xx-nand + runtime_test: false + + - arch: powerpc_8540 + target: mpc85xx-p1010 + runtime_test: false + - arch: aarch64_cortex-a53 + target: mvebu-cortexa53 runtime_test: true + - arch: arm_cortex-a15_neon-vfpv4 + target: armvirt-32 runtime_test: true + - arch: i386_pentium-mmx + target: x86-geode runtime_test: true + - arch: x86_64 + target: x86-64 runtime_test: true steps: @@ -41,8 +65,10 @@ jobs: - name: Determine changed packages run: | # only detect packages with changes - PKG_ROOTS=$(find . -name Makefile | grep -v ".*/src/Makefile" | sed -e 's@./\(.*\)/Makefile@\1/@') - CHANGES=$(git diff --diff-filter=d --name-only origin/$BRANCH) + PKG_ROOTS=$(find . -name Makefile | \ + grep -v ".*/src/Makefile" | \ + sed -e 's@./\(.*\)/Makefile@\1/@') + CHANGES=$(git diff --diff-filter=d --name-only origin/$BRANCH...) for ROOT in $PKG_ROOTS; do for CHANGE in $CHANGES; do @@ -55,13 +81,13 @@ jobs: # fallback to test packages if nothing explicitly changes this is # should run if other mechanics in packages.git changed - PACKAGES="${PACKAGES:-vim tmux bmon}" + PACKAGES="${PACKAGES:-vim attendedsysupgrade-common bmon}" echo "Building $PACKAGES" echo "PACKAGES=$PACKAGES" >> $GITHUB_ENV - name: Build - uses: openwrt/gh-action-sdk@v1 + uses: openwrt/gh-action-sdk@v5 env: ARCH: ${{ matrix.arch }}-${{ env.BRANCH }} FEEDNAME: packages_ci @@ -69,17 +95,57 @@ jobs: - name: Move created packages to project dir run: cp bin/packages/${{ matrix.arch }}/packages_ci/*.ipk . || true + - name: Collect metadata + run: | + MERGE_ID=$(git rev-parse --short HEAD) + echo "MERGE_ID=$MERGE_ID" >> $GITHUB_ENV + echo "BASE_ID=$(git rev-parse --short HEAD^1)" >> $GITHUB_ENV + echo "HEAD_ID=$(git rev-parse --short HEAD^2)" >> $GITHUB_ENV + PRNUMBER=${GITHUB_REF_NAME%/merge} + echo "PRNUMBER=$PRNUMBER" >> $GITHUB_ENV + echo "ARCHIVE_NAME=${{matrix.arch}}-PR$PRNUMBER-$MERGE_ID" >> $GITHUB_ENV + + - name: Generate metadata + run: | + cat << _EOF_ > PKG-INFO + Metadata-Version: 2.1 + Name: ${{env.ARCHIVE_NAME}} + Version: $BRANCH + Author: $GITHUB_ACTOR + Home-page: $GITHUB_SERVER_URL/$GITHUB_REPOSITORY/pull/$PRNUMBER + Download-URL: $GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID + Summary: $PACKAGES + Platform: ${{ matrix.arch }} + + Packages for OpenWrt $BRANCH running on ${{matrix.arch}}, built from PR $PRNUMBER + at commit $HEAD_ID, against $BRANCH at commit $BASE_ID, with merge SHA $MERGE_ID. + + Modified packages: + _EOF_ + for p in $PACKAGES + do + echo " "$p >> PKG-INFO + done + echo >> PKG-INFO + echo Full file listing: >> PKG-INFO + ls -al *.ipk >> PKG-INFO || true + cat PKG-INFO + - name: Store packages uses: actions/upload-artifact@v2 with: - name: ${{ matrix.arch}}-packages - path: "*.ipk" + name: ${{env.ARCHIVE_NAME}}-packages + path: | + *.ipk + PKG-INFO - name: Store logs uses: actions/upload-artifact@v2 with: - name: ${{ matrix.arch}}-logs - path: logs/ + name: ${{env.ARCHIVE_NAME}}-logs + path: | + logs/ + PKG-INFO - name: Remove logs run: sudo rm -rf logs/ || true @@ -94,7 +160,7 @@ jobs: run: | docker build -t test-container --build-arg ARCH .github/workflows/ env: - ARCH: ${{ matrix.arch }} + ARCH: ${{ matrix.arch }}-${{ env.BRANCH }} - name: Test via Docker container if: ${{ matrix.runtime_test }}