这是indexloc提供的服务,不要输入任何密码
Skip to content

Update branches with updated submodule on libjxl #1030

Update branches with updated submodule on libjxl

Update branches with updated submodule on libjxl #1030

# Copyright (c) the JPEG XL Project Authors. All rights reserved.
#
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
# Workflow for building and running tests.
name: Update branches with updated submodule on libjxl
on:
workflow_dispatch:
schedule:
- cron: '37 2 * * *' # Daily on 02:37 UTC
permissions:
contents: read
jobs:
update:
if: github.repository_owner == 'libjxl'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- branch: 'test_highway'
tag: 'origin/master'
- branch: 'test_highway_1.0.7'
tag: '1.0.7'
- branch: 'test_highway_1.1.0'
tag: '1.1.0'
- branch: 'test_highway_1.2.0'
tag: '1.2.0'
- branch: 'test_highway_1.3.0'
tag: '1.3.0'
steps:
- name: Harden Runner
uses: step-security/harden-runner@f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a # v2.13.1
with:
egress-policy: audit
- name: 'Cloning libjxl'
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
submodules: recursive
persist-credentials: false # otherwise, the wrong authentication is used in the push
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
- name: Pull & update highway
working-directory: ./third_party/highway
run: |
git fetch origin
git checkout ${{ matrix.tag }}
- name: Update deps.sh
run: |
NEWHASH=`git -C third_party/highway rev-parse HEAD`
sed -i "s/\(THIRD_PARTY_HIGHWAY=\"\)[^\"]*/\1$NEWHASH/" deps.sh
- name: Commit
run: |
git config user.email "firsching@google.com"
git config user.name "GitHub Actions - update submodules"
git add --all
git commit -m "Update highway submodule" || echo "No changes to commit"
- name: Push changes
env:
# NB: token expires on 15 August every year.
TOKEN: ${{ secrets.PUSH_NEW_HWY_TOKEN }}
run: |
git push https://oauth2:${TOKEN%$'\n'}@github.com/libjxl/libjxl.git HEAD:refs/heads/${{ matrix.branch }} --force