Merge pull request #61 from gnurizen/musl-bump #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate glibc | |
on: | |
workflow_call: | |
push: | |
branches: | |
- main | |
- release | |
paths: | |
- ".github/workflows/generate-glibc.yml" | |
- "pkg/libc/glibc/**" | |
- "scripts/**" | |
- "Makefile" | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
generate-and-create-branch: | |
runs-on: ubuntu-latest | |
timeout-minutes: 20 | |
steps: | |
- name: Check out the code | |
uses: actions/checkout@v4 | |
- name: Install devbox | |
uses: jetpack-io/[email protected] | |
with: | |
enable-cache: true | |
- name: Setup devbox | |
run: devbox run -- echo "done!" | |
- name: Load devbox shellenv | |
uses: HatsuneMiku3939/direnv-action@v1 | |
with: | |
direnvVersion: 2.32.3 | |
- name: Set up Go tool cache | |
uses: actions/cache@v4 | |
with: | |
path: ~/.devbox/go | |
key: devbox-go-tools.cache-${{ runner.os }}-${{ runner.arch }} | |
- name: Build | |
run: make build | |
- name: Set up cache for downloaded files | |
uses: actions/cache@v4 | |
with: | |
path: workspace-glibc | |
key: glibc-downloaded-${{ runner.os }}-${{ matrix.arch }} | |
restore-keys: | | |
glibc-downloaded-${{ runner.os }}-${{ matrix.arch }} | |
- name: Generate glibc Offsets | |
run: | | |
TEMP_DIR=workspace-glibc make generate/glibc | |
# If there are no changes (i.e. no diff exists with the checked-out base branch), | |
# no pull request will be created and the action exits silently. | |
- name: Create a pull-request | |
if: github.event_name != 'pull_request' | |
uses: peter-evans/create-pull-request@v6 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
commit-message: "chore: update glibc layouts" | |
title: "chore: Update glibc layouts" | |
branch: update-offsets-glibc-${{ github.run_number }} | |
add-paths: pkg/libc/glibc/layout | |
base: main | |
labels: chore | |
draft: false | |
delete-branch: true |