Skip to content

Commit

Permalink
- Cherry picking commits from main
Browse files Browse the repository at this point in the history
- Update diff.yml
- ci: Fix kidiff output resolution to a valid range.
- ci: Update uploaded artifact name in diff.yml
- Fix cherry-pick conflict
- Fix path to ci workflow READE badge.
  • Loading branch information
Kampi committed Nov 7, 2024
1 parent 2768973 commit 30bce4f
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 15 deletions.
39 changes: 25 additions & 14 deletions .github/workflows/diff.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,46 @@
name: Diff

on:
workflow_dispatch:
pull_request_target:
types:
- closed
push:

jobs:
build:
runs-on: ubuntu-latest
container: ghcr.io/inti-cmnb/kicad8_auto_full:latest

permissions:
contents: write

env:
KICAD_LIBRARY: /home/runner/work/ZSWatch-HW/ZSWatch-HW/library

steps:
- name: Checkout-Branch
- name: Checkout branch
uses: actions/checkout@v4
with:
ref: ${{ github.ref_name }}
path: modified
submodules: recursive

- name: Checkout-main
- name: Checkout main
uses: actions/checkout@v4
with:
ref: main
path: original
submodules: recursive

- name: Dependencies
run: git clone https://github.com/Kampi/KiCad.git library
- name: Create schematics diff
run: |
kicad-diff.py original/project/ZSWatch.kicad_sch modified/project/ZSWatch.kicad_sch --diff_mode red_green --all_pages --output_dir diff-schematics --no_reader --keep_pngs --resolution 400
- name: Create layout diff
run: |
kicad-diff.py original/project/ZSWatch.kicad_pcb modified/project/ZSWatch.kicad_pcb --diff_mode red_green --all_pages --output_dir diff-layout --no_reader --keep_pngs --resolution 400
- name: Upload Layout Diff
uses: actions/upload-artifact@v4
with:
name: "diff-layout-${{ github.ref_name }}"
path: diff-layout
if-no-files-found: ignore

- name: Upload Schematics Diff
uses: actions/upload-artifact@v4
with:
name: "diff-schematics-${{ github.ref_name }}"
path: diff-schematics
if-no-files-found: ignore
2 changes: 2 additions & 0 deletions .github/workflows/production.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Production

on:
pull_request:
workflow_dispatch:
pull_request_target:
types:
- closed
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# ZSWatch Hardware

[![License](https://img.shields.io/badge/License-GPL%203.0-blue.svg)](https://opensource.org/license/gpl-3-0/)
![Badge](https://github.com/jakkra/zswatch-hw/actions/workflows/build.yml/badge.svg?color=yellow)
![Badge](https://github.com/jakkra/zswatch-hw/actions/workflows/production.yml/badge.svg?color=yellow)

## Table of Contents

Expand Down

0 comments on commit 30bce4f

Please sign in to comment.