Skip to content

Commit

Permalink
Moved part of the PR github workflow to a shared action.
Browse files Browse the repository at this point in the history
  • Loading branch information
rakshasa committed Dec 7, 2024
1 parent 5d734da commit 420c859
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 20 deletions.
26 changes: 26 additions & 0 deletions .github/actions/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: "Project Builder"
runs:
using: "builder"
runs-on: ubuntu-22.04

steps:
- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang-tidy bear
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0
- name: Fetch base branch
run: |
git remote add upstream "https://github.com/${{ github.event.pull_request.base.repo.full_name }}"
git fetch --no-tags --no-recurse-submodules upstream "${{ github.event.pull_request.base.ref }}"
- name: Configure Project
run: |
libtoolize
aclocal -I scripts
autoconf -i
autoheader
automake --add-missing
./configure
21 changes: 1 addition & 20 deletions .github/workflows/PR.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,9 @@ jobs:

clang-tidy:
runs-on: ubuntu-22.04
using: "builder"

steps:
- name: Install clang-tidy
run: |
sudo apt-get update
sudo apt-get install -y clang-tidy bear
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0
- name: Fetch base branch
run: |
git remote add upstream "https://github.com/${{ github.event.pull_request.base.repo.full_name }}"
git fetch --no-tags --no-recurse-submodules upstream "${{ github.event.pull_request.base.ref }}"
- name: Configure Project
run: |
libtoolize
aclocal -I scripts
autoconf -i
autoheader
automake --add-missing
./configure
- name: Prepare compile_commands.json
run: |
bear -- make
Expand Down

0 comments on commit 420c859

Please sign in to comment.