Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ jobs:

strategy:
matrix:
cc: [gcc, clang]
include:
- cc: gcc
extra_cflags: -Wno-error=maybe-uninitialized
- cc: clang
extra_cflags: ''

steps:
- name: Checkout repository
Expand All @@ -36,6 +40,6 @@ jobs:
sudo apt-get install -y libusb-1.0-0-dev ${{ matrix.cc }}

- name: Build with ${{ matrix.cc }}
run: make CC=${{ matrix.cc }} CFLAGS="${CFLAGS} -Werror -Wno-error=maybe-uninitialized"
run: make CC=${{ matrix.cc }} CFLAGS="${CFLAGS} -Werror ${{ matrix.extra_cflags }}"
env:
CFLAGS: -MMD -O2 -Wall -Wextra -I/opt/local/include -g
12 changes: 10 additions & 2 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ jobs:
with:
images: |
ghcr.io/${{ github.repository }}
${{ secrets.DOCKER_USERNAME }}/${{ github.event.repository.name }}
${{ secrets.DOCKER_USERNAME != '' && format('{0}/{1}', secrets.DOCKER_USERNAME, github.event.repository.name) || '' }}
tags: |
type=ref,event=branch
type=ref,event=pr
Expand Down Expand Up @@ -103,6 +103,14 @@ jobs:
run: |
images=""
for tag in ${TAGS}; do
images+="${tag}@${DIGEST} "
# Only sign tags for registries that were actually pushed to
case "${tag}" in
ghcr.io/*) images+="${tag}@${DIGEST} " ;;
*/*)
if [ -n "${{ secrets.DOCKER_USERNAME }}" ]; then
images+="${tag}@${DIGEST} "
fi
;;
esac
done
cosign sign --yes ${images}