diff --git a/.github/workflows/autobuild.yml b/.github/workflows/autobuild.yml index 88a7b6438c..678e89073d 100644 --- a/.github/workflows/autobuild.yml +++ b/.github/workflows/autobuild.yml @@ -6,10 +6,10 @@ on: paths: - anda/** branches: - - main + - f37 pull_request: branches: - - main + - f37 workflow_dispatch: workflow_call: @@ -20,7 +20,7 @@ jobs: outputs: build_matrix: ${{ steps.generate_build_matrix.outputs.build_matrix }} container: - image: ghcr.io/terrapkg/builder:main + image: ghcr.io/terrapkg/builder:37 options: --cap-add=SYS_ADMIN --privileged steps: - name: Set workspace as safe @@ -42,7 +42,7 @@ jobs: fail-fast: false runs-on: ${{ matrix.pkg.arch == 'aarch64' && 'ARM64' || 'ubuntu-latest' }} container: - image: ghcr.io/terrapkg/builder:main + image: ghcr.io/terrapkg/builder:37 options: --cap-add=SYS_ADMIN --privileged steps: - name: Checkout diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7a9d449eb1..6f6518918c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,7 +25,7 @@ jobs: fail-fast: false runs-on: ${{ matrix.arch == 'aarch64' && 'ARM64' || 'ubuntu-latest' }} container: - image: ghcr.io/terrapkg/builder:main + image: ghcr.io/terrapkg/builder:37 options: --cap-add=SYS_ADMIN --privileged steps: - name: Checkout @@ -36,7 +36,7 @@ jobs: - uses: terrapkg/anda-build@main with: name: "${{ matrix.pkg }}pkg" - mockConfig: anda-37-${{ matrix.arch }} + mockConfig: anda-${{ matrix.version }}-${{ matrix.arch }} extraArgs: -D "sccache_bucket ${{secrets.SCCACHE_BUCKET}}" -D "sccache_endpoint ${{secrets.SCCACHE_ENDPOINT}}" -D "sccache_secret ${{secrets.SCCACHE_SECRET}}" -D "sccache_accesskey ${{secrets.SCCACHE_ACCESSKEY}}" andaRepo: https://github.com/terrapkg/subatomic-repos/raw/main/terra.repo diff --git a/.github/workflows/mg.sh b/.github/workflows/mg.sh index 273d6e1380..985f6959dc 100755 --- a/.github/workflows/mg.sh +++ b/.github/workflows/mg.sh @@ -4,6 +4,13 @@ dirs=$2 dirs=${dirs/\/pkg/} export p="{\"id\":\"$5\",\"ver\":\"%v\",\"rel\":\"%r\",\"arch\":\"$4\",\"dirs\":\"$dirs\",\"succ\":$1}" +if [[ $succ == false ]]; then + d=${p/\%v/?} + d=${d/\%r/?} + curl -H "Authorization: Bearer $6" https://madoguchi.fyralabs.com/ci/terra$3/builds/$n -X PUT -H "Content-Type: application/json" -d $d --fail-with-body + exit 0 +fi + for f in anda-build/rpm/rpms/*; do n=$(lesspipe.sh $f | grep -E "Name\s*: " | sed "s@Name\s*: @@") v=$(lesspipe.sh $f | grep -E "Version\s*: " | sed "s@Version\s*: @@") diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index f92139e0be..8913585ddd 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -4,10 +4,13 @@ on: types: - closed branches: - - main + - f39 jobs: sync: + strategy: + matrix: + branch: ["f37", "f38"] if: github.event.pull_request.merged == true && !contains(github.event.pull_request.labels.*.name, 'nosync') runs-on: ubuntu-latest steps: @@ -16,23 +19,18 @@ jobs: with: fetch-depth: 0 ssh-key: ${{ secrets.SSH_AUTHENTICATION_KEY }} - - name: Install SSH key + ref: ${{ matrix.branch }} + - name: Install SSH key and Setup Git run: | mkdir -p ${{ runner.temp }} echo "${{ secrets.SSH_SIGNING_KEY }}" > ${{ runner.temp }}/signing_key chmod 0700 ${{ runner.temp }}/signing_key - - name: Setup Git - run: | git config --global --add safe.directory "$GITHUB_WORKSPACE" git config user.name "Raboneko" git config user.email "raboneko@fyralabs.com" git config gpg.format "ssh" git config user.signingkey "${{ runner.temp }}/signing_key" - - name: Download patches - run: curl https://github.com/terrapkg/packages/pull/${{ github.event.pull_request.number }}.patch > pr.patch - - name: Apply patches + - name: Apply patches and Push run: | - git checkout f38 - git am -S --keep-cr --signoff < pr.patch - - name: Push - run: git push -u origin --all + git am -S --keep-cr --signoff < curl https://github.com/terrapkg/packages/pull/${{ github.event.pull_request.number }}.patch + git push -u origin --all diff --git a/.github/workflows/update-comps.yml b/.github/workflows/update-comps.yml index 9301f64676..2c614f2aca 100644 --- a/.github/workflows/update-comps.yml +++ b/.github/workflows/update-comps.yml @@ -3,8 +3,9 @@ name: Push comps updates on: push: branches: - - main + - f39 - f38 + - f37 paths: - comps.xml workflow_dispatch: diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml index 2396c2d847..345d42fcfa 100644 --- a/.github/workflows/update.yml +++ b/.github/workflows/update.yml @@ -39,5 +39,14 @@ jobs: git config user.signingkey "${{ runner.temp }}/signing_key" msg="bump: $(git status | grep modified | sed -r 's@.+/([^/]+)/[^/]+\n?@\1 @g' | tr -d '\n')" git commit -S -a -m "$msg" + git format-patch HEAD^ + git checkout f38 + git apply *.patch || true + git add anda + git commit -S -a -m "$msg" + git checkout f37 + git apply *.patch || true + git add anda + git commit -S -a -m "$msg" git push -u origin --all fi