Skip to content
Open
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
16 changes: 8 additions & 8 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ jobs:
docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
fetch-depth: 0
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3
- name: Log in to GHCR
uses: docker/login-action@v3
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand Down Expand Up @@ -62,7 +62,7 @@ jobs:
git tag ${{ steps.full_version.outputs.full_version }}
git push origin ${{ steps.full_version.outputs.full_version }}
- name: Build and push
uses: docker/build-push-action@v6
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6
with:
push: true
tags: ghcr.io/usa-reddragon/kiri:${{ steps.tag_name.outputs.tag }}
Expand All @@ -79,15 +79,15 @@ jobs:
run: |
echo "major_version=${GITHUB_REF#refs/*/}" | sed 's/\.[^.]*$//' | sed 's/\.[^.]*$//' >> $GITHUB_OUTPUT
- name: Build and push minor version
uses: docker/build-push-action@v6
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'release'
with:
push: true
tags: ghcr.io/usa-reddragon/kiri:${{ steps.minor_version.outputs.minor_version }}
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Build and push major version
uses: docker/build-push-action@v6
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'release'
with:
push: true
Expand All @@ -108,7 +108,7 @@ jobs:
- name: Create Release
id: create_release
if: startsWith(github.ref, 'refs/tags/v')
uses: actions/create-release@v1
uses: actions/create-release@0cb9c9b65d5d1901c1f53e5e66eaf4afd303e70e # v1
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
with:
Expand All @@ -118,7 +118,7 @@ jobs:
prerelease: false
- name: Create Issue on Failure
if: failure() && startsWith(github.ref, 'refs/tags/v')
uses: actions/github-script@v7
uses: actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/notify.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-24.04
steps:
- name: Send notification
uses: USA-RedDragon/telegram-notification@v1.0.0
uses: USA-RedDragon/telegram-notification@5c9e380b10cc3af7bd3290a51c3e42485ee2b93f # v1.0.0
with:
bot-token: ${{ secrets.TG_BOT_TOKEN }}
chat-id: ${{ secrets.TG_CHAT_ID }}
10 changes: 5 additions & 5 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,20 @@ jobs:
name: Build and Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
# Docker testing
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3
with:
driver: docker
- name: Log in to GHCR
uses: docker/login-action@v3
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.PAT }}
- name: Build version
uses: docker/build-push-action@v6
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6
with:
push: true
tags: ghcr.io/usa-reddragon/kiri-ci:${{ github.sha }}
Expand All @@ -34,7 +34,7 @@ jobs:
sed -i "s#ghcr.io/usa-reddragon/kiri:__KIRI_VERSION__#ghcr.io/usa-reddragon/kiri-ci:${{ github.sha }}#g" action.yml
# Action testing
- name: Clone SnekSafe for testing
uses: actions/checkout@v4
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
repository: USA-RedDragon/SnekSafe
path: SnekSafe
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@

# Latest stable version of Ubuntu, of course
FROM ubuntu:24.04
FROM ubuntu:24.04@sha256:c4a8d5503dfb2a3eb8ab5f807da5bc69a85730fb49b5cfca2330194ebcc41c7b

LABEL org.opencontainers.image.authors "Leandro Heck <leoheck@gmail.com>, Jacob McSwain <kiri-github-action@mcswain.dev>"
LABEL org.opencontainers.image.description "Kicad 9 and KiRI"
LABEL org.opencontainers.image.url "https://github.com/USA-RedDragon/kiri-github-action/pkgs/container/kiri"
LABEL org.opencontainers.image.documentation "https://github.com/USA-RedDragon/kiri-github-action"
LABEL org.opencontainers.image.source "https://github.com/USA-RedDragon/kiri-github-action"

Check warning on line 9 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "LABEL key=value" should be used instead of legacy "LABEL key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/

ARG DEBIAN_FRONTEND=noninteractive
ARG DEBCONF_NOWARNINGS="yes"
Expand Down Expand Up @@ -58,8 +58,8 @@
USER github
WORKDIR "/home/github"
ENV USER github
ENV HOME /home/github

Check warning on line 61 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV DISPLAY :0

Check warning on line 62 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/

ENV PATH "${PATH}:/home/github/.local/bin"

Expand Down Expand Up @@ -103,7 +103,7 @@
rm -rf ~/.opam/download-cache ;\
rm -rf ~/.opam/repo/*

ENV PATH "${KIRI_HOME}/bin:${KIRI_HOME}/submodules/KiCad-Diff/bin:${PATH}"

Check warning on line 106 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/

# Clean unnecessary stuff
RUN sudo apt-get purge -y \
Expand All @@ -129,16 +129,16 @@

# GitHub Actions environment variables
ENV KIRI_PROJECT_FILE ""
ENV KIRI_OUTPUT_DIR ""

Check warning on line 132 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV KIRI_REMOVE ""
ENV KIRI_ARCHIVE ""

Check warning on line 134 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV KIRI_PCB_PAGE_FRAME ""
ENV KIRI_FORCE_LAYOUT_VIEW ""
ENV KIRI_SKIP_KICAD6_SCHEMATICS ""
ENV KIRI_SKIP_CACHE ""

Check warning on line 138 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV KIRI_OLDER ""

Check warning on line 139 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV KIRI_NEWER ""

Check warning on line 140 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/
ENV KIRI_LAST ""
ENV KIRI_ALL ""

Check warning on line 142 in Dockerfile

View workflow job for this annotation

GitHub Actions / Build and Test

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/

ENTRYPOINT ["/entrypoint.sh"]
10 changes: 5 additions & 5 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ runs:
with:
args: ${{ inputs.extra-args }}
- name: Upload Kiri custom output
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.output-dir != '' && github.event_name == 'pull_request' && github.event.action != 'closed' && steps.kicad-files.outputs.changed == 'true'
with:
name: kiri-output
Expand All @@ -108,14 +108,14 @@ runs:
echo "output-dir=$(dirname ${{ inputs.project-file }})/.kiri" >> $GITHUB_OUTPUT
fi
- name: Upload Kiri output
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.output-dir == '' && github.event_name == 'pull_request' && github.event.action != 'closed' && steps.kicad-files.outputs.changed == 'true'
with:
name: kiri-output
path: ${{ steps.kiri-output.outputs.output-dir }}
- name: Checkout gh-pages branch
if: github.event_name == 'pull_request'
uses: actions/checkout@v4
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
ref: gh-pages
fetch-depth: 0
Expand Down Expand Up @@ -148,7 +148,7 @@ runs:
REPO: ${{ github.repository }}
- name: Create a comment with the link to the output
if: github.event_name == 'pull_request' && github.event.action != 'closed' && steps.kicad-files.outputs.changed == 'true'
uses: peter-evans/create-or-update-comment@v4
uses: peter-evans/create-or-update-comment@71345be0265236311c031f5c7866368bd1eff043 # v4
with:
issue-number: ${{ github.event.pull_request.number }}
body: |
Expand All @@ -175,7 +175,7 @@ runs:
git push origin gh-pages
- name: Create a comment on the PR
if: steps.delete.outputs.deleted == 'true' && github.event_name == 'pull_request' && github.event.action == 'closed'
uses: peter-evans/create-or-update-comment@v4
uses: peter-evans/create-or-update-comment@71345be0265236311c031f5c7866368bd1eff043 # v4
with:
issue-number: ${{ github.event.pull_request.number }}
body: |
Expand Down
Loading