-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathaction.yml
More file actions
32 lines (32 loc) · 1.07 KB
/
Copy pathaction.yml
File metadata and controls
32 lines (32 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: 'FreeCAD Gallery Builder'
description: 'Export FreeCAD models to STL/STEP and build an interactive Three.js gallery'
author: 'schmiddim'
branding:
icon: 'box'
color: 'orange'
inputs:
send-ping:
description: 'Send a POST ping to the aggregator after the gallery build'
required: false
default: 'false'
outputs:
models-count:
description: 'Number of models exported'
value: ${{ steps.build-gallery.outputs.models-count }}
runs:
using: 'composite'
steps:
- name: Export + Build Gallery
id: build-gallery
shell: bash
env:
DOCKER_IMAGE: ghcr.io/schmiddim/freecad-action:latest
WORKSPACE: ${{ github.workspace }}
ACTION_PATH: ${{ github.action_path }}
SEND_PING: ${{ inputs.send-ping }}
ACTION_REF: ${{ github.action_ref || github.ref_name }}
run: |
echo "==> FreeCAD Gallery Builder ${ACTION_REF}"
${{ github.action_path }}/scripts/build.sh build
MODEL_COUNT=$(find gallery/view -name '*.html' 2>/dev/null | wc -l)
echo "models-count=$MODEL_COUNT" >> "$GITHUB_OUTPUT"