Skip to content

Commit

Permalink
Update workflows.
Browse files Browse the repository at this point in the history
  • Loading branch information
kaklik committed Feb 1, 2025
1 parent f4bf432 commit 1f6ecbb
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 35 deletions.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
hw/cam_profi/* merge=theirs
doc/gen/* merge=theirs
38 changes: 19 additions & 19 deletions .github/workflows/kicad_outputs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/erc.kibot.yaml
schema: ${{ env.schema }}
Expand All @@ -51,7 +51,7 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/drc.kibot.yaml
schema: ${{ env.schema }}
Expand All @@ -69,14 +69,14 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/schematics.kibot.yaml
schema: ${{ env.schema }}
board: ${{ env.board }}
dir: ${{ env.dir }}_docs

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_sch
Expand All @@ -93,14 +93,14 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/placement.kibot.yaml
schema: ${{ env.schema }}
board: ${{ env.board }}
dir: ${{ env.dir }}_docs

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/xml.kibot.yaml
schema: ${{ env.schema }}
Expand All @@ -119,15 +119,15 @@ jobs:
mv hw/sch_pcb/*.xml doc_xml/ || true;
mv hw/out_docs/*.csv doc_xml/ || true;
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_xml
path: |
doc_xml
# Zde se zahazuji debugovaci videa
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_placement
Expand All @@ -146,14 +146,14 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/report.kibot.yaml
schema: ${{ env.schema }}
board: ${{ env.board }}
dir: ${{ env.dir }}_report

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_report
Expand All @@ -170,7 +170,7 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/ibom.kibot.yaml
schema: ${{ env.schema }}
Expand All @@ -180,7 +180,7 @@ jobs:
- name: "Rename output"
run: for file in $(find ${{env.dir}} -type f); do sudo mv "${file}" "${file//${{env.project}}/${{env.branch}}}" ; done

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_ibom
Expand All @@ -199,7 +199,7 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/gerbers.kibot.yaml
schema: ${{ env.schema }}
Expand All @@ -210,7 +210,7 @@ jobs:
- name: "Rename output"
run: for file in $(find ${{env.dir}}_gerbers -type f); do sudo mv "${file}" "${file//${{env.project}}/${{env.branch}}}" || true ; done

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: hw_cam_profi
Expand All @@ -228,28 +228,28 @@ jobs:
token: ${{ secrets.pat }}
ref: ${{ github.head_ref }}

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/cad.kibot.yaml
schema: ${{ env.schema }}
board: ${{ env.board }}
dir: ${{ env.dir }}_cad

- uses: INTI-CMNB/KiBot@v2_dk7
- uses: INTI-CMNB/KiBot@v2_dk8
with:
config: ${{ env.kibot }}/render.kibot.yaml
schema: ${{ env.schema }}
board: ${{ env.board }}
dir: ${{ env.dir }}_img
verbose: 3

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_cad
path: ${{ env.dir }}_cad/**

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: ${{ success() }}
with:
name: doc_img
Expand All @@ -271,7 +271,7 @@ jobs:
git submodule update --remote || true
- name: Download a Build Artifact
uses: actions/download-artifact@v3.0.0
uses: actions/download-artifact@v4

- name: Remove old manufarturing data
run: |
Expand Down
36 changes: 36 additions & 0 deletions .github/workflows/release_assets.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Release Assets

permissions: write-all

on:
release:
types: [edited, prereleased, released]

jobs:
upload-gerber-assets:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up variables
run: |
REPO_NAME=$(basename -s .git `git config --get remote.origin.url`)
COMMIT_SHA=$(git rev-parse --short HEAD)
ZIP_NAME="${REPO_NAME}-${COMMIT_SHA}.gerber.zip"
echo "ZIP_NAME=$ZIP_NAME" >> $GITHUB_ENV
- name: Create ZIP archive of Gerber files
run: |
zip -j ${{ env.ZIP_NAME }} hw/cam_profi/gbr/*
- name: Upload ZIP as release asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ${{ env.ZIP_NAME }}
asset_name: ${{ env.ZIP_NAME }}
asset_content_type: application/zip
31 changes: 15 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
# For PCBs designed using KiCad: http://www.kicad-pcb.org/
# Format documentation: http://kicad-pcb.org/help/file-formats/

# Temporary files
*~
*.000
_autosave-*
*auto_saved_files#
*backup*
*-backups
*.bak
*.bck
*.dsn
*fp-info-cache
fp-info-cache
*.kicad_pcb-bak
*.sch-bak
*~
*-backups*
_autosave-*
*.tmp
*-save.pro
*.kicad_prl
*.kicad_sch-bak
*.lck
*.orig
*-save.kicad_pcb
fp-info-cache

# Netlist files (exported from Eeschema)
*.net

# Autorouter files (exported from Pcbnew)
*.dsn
*-save.pro
*.sch-bak
*.ses
*.tmp

0 comments on commit 1f6ecbb

Please sign in to comment.