Make Case #11
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Make Case | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| switch-type: | |
| description: 'MX or Choc (V1 or V2). Allowed values: "mx", "choc".' | |
| default: "mx" | |
| type: string | |
| mcu: | |
| description: 'MCU used. Allowed values: "xiao", "rp2040-zero", "either".' | |
| default: "rp2040-zero" | |
| type: string | |
| mcu-socket-height: | |
| description: 'The height of the sockets in millimeters above the PCB. Default 4.7mm (round pin sockets).' | |
| default: "4.7" | |
| battery: | |
| description: 'Battery type used. Allowed values: "none", "coin", "lipo".' | |
| default: "none" | |
| type: string | |
| tenting: | |
| description: 'Integrated tenting options. Allowed values: "none", "magsafe", "puck".' | |
| default: "none" | |
| type: string | |
| inner-index: | |
| description: 'Adjust the number and position of the inner index keys for better comfort. Allowed values: "all", "reduced", "flex". Flex allows either configuration to be used.' | |
| default: "all" | |
| type: string | |
| remove-num-row: | |
| description: 'Removes the num row keys by covering them up with the tray.' | |
| type: boolean | |
| default: false | |
| thumb-type: | |
| description: 'Select what thumb cluster type should be used. Allowed values: "ripple", "all-1u", "classic", "flex". Classic is 1u-1u-1.5u. Flex allows for any of the three options, but may be less stable.' | |
| default: "ripple" | |
| type: string | |
| thumb-adjustment: | |
| description: 'Move the thumb cluster. Format: "x,y,r" where x is the number of mm that the cluster should be moved inwards, y is the number of mm that the cluster should be moved downwards, and r is the clockwise rotation in degrees around the outermost down-most corner of the cluster.' | |
| default: "0,0,0" | |
| extra-options: | |
| description: 'Any additional options. See documentation for details.' | |
| type: string | |
| default: '' | |
| jobs: | |
| Generate-Apiaster-Case: | |
| name: Generate Apiaster Case | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: Set up Python | |
| uses: actions/setup-python@v2 | |
| with: | |
| python-version: '3.12' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install build123d==0.9.1 | |
| - name: Run Python command | |
| run: | | |
| python case/make_case.py \ | |
| --switch ${{ github.event.inputs['switch-type'] }} \ | |
| --mcu ${{ github.event.inputs['mcu'] }} \ | |
| --mcu-socket-height ${{ github.event.inputs['mcu-socket-height'] }} \ | |
| --battery ${{ github.event.inputs['battery'] }} \ | |
| --tenting ${{ github.event.inputs['tenting'] }} \ | |
| --expose ${{ github.event.inputs['expose'] }} \ | |
| --inner-index ${{ github.event.inputs['inner-index'] }} \ | |
| ${{ github.event.inputs['remove-num-row'] == 'true' && '--remove-num-row' || '' }} \ | |
| --thumb-type ${{ github.event.inputs['thumb-type'] }} \ | |
| --thumb-adjustment ${{ github.event.inputs['thumb-adjustment'] }} \ | |
| ${{ github.event.inputs['extra-options'] }} \ | |
| --export-stl --no-show | |
| - name: Archive Apiaster Case STL files | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: apiaster-case-stl | |
| path: case/stl/ |