Skip to content

Commit

Permalink
add build123d workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
willpuckett committed Sep 23, 2024
1 parent 418b960 commit e469058
Show file tree
Hide file tree
Showing 13 changed files with 205,838 additions and 135,142 deletions.
38 changes: 23 additions & 15 deletions .github/workflows/case.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,32 @@
name: Case Generator
name: Build123d Case

on:
workflow_run:
workflows: ["KiBot Check & Generate"]
types:
- completed
workflow_dispatch:

jobs:
Case:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: 'pip' # caching pip dependencies
- run: pip install -r requirements.txt
# - run: vpype read default/swoon-Edge_Cuts_LEFT.svg linemerge --tolerance 3mm linesort reloop linesimplify write default/swoon-Edge_Cuts_LEFT_vpype.svg
- run: python case.py
- uses: actions/upload-artifact@v4
with:
name: Case
path: "*.step"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: BOARD_OUTLINE
path: case/swoon_edges.svg
run-id: ${{ github.event.workflow_run.id }}
- run: |
python3 -m pip install vpype build123d
vpype read case/swoon_edges.svg linemerge --tolerance 3mm linesort reloop \
linesimplify write case/swoon_edges_vpype.svg
python case.py
- uses: actions/upload-artifact@v4
with:
name: Case_STEP
path: "*.step"
- uses: actions/upload-artifact@v4
with:
name: Case_STL
path: "*.stl"
4 changes: 0 additions & 4 deletions .github/workflows/keymap-drawer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ jobs:
with:
fetch-depth: 2
ref: ${{ github.head_ref }}
# - uses: pkgxdev/setup@v1
# with:
# +: python
# pipx
- run: |
python3 -m pip install keymap-drawer
.images/draw-keymaps.sh
Expand Down
6 changes: 3 additions & 3 deletions case/case.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#!/usr/bin/env -S pkgx +pip python
#!/usr/bin/env python3

# vpype read default/swoon-Edge_Cuts_LEFT.svg linemerge --tolerance 3mm linesort reloop linesimplify write default/swoon-Edge_Cuts_LEFT_vpype.svg

from build123d import *
from ocp_vscode import show_object as show, set_port
# from ocp_vscode import show_object as show, set_port

# set_port(3939)

Expand All @@ -25,6 +25,6 @@
# top_face = case.faces().sort_by(Axis.Z)[-1]
# fillet(top_face.edges(), radius=0.3 * MM)

show(case)
# show(case)
export_step(case.part, file_path="case/case.step")
export_stl(case.part, file_path="case/case.stl")
2 changes: 0 additions & 2 deletions case/requirements.txt

This file was deleted.

17 changes: 0 additions & 17 deletions case/swoon_edges_vpype.svg

This file was deleted.

2 changes: 1 addition & 1 deletion library/Swoon.kicad_sym
Original file line number Diff line number Diff line change
Expand Up @@ -911,7 +911,7 @@
(hide yes)
)
)
(property "Footprint" "Swoon:SW_PG1350_vias"
(property "Footprint" "Swoon:SW_PG1350_vias_tented"
(at 0.254 -3.81 0)
(effects
(font
Expand Down
Loading

0 comments on commit e469058

Please sign in to comment.