-
Notifications
You must be signed in to change notification settings - Fork 10
59 lines (52 loc) · 2 KB
/
build.yml
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
name: Build
on:
pull_request:
workflow_call:
outputs:
semver:
description: "The computed version number for this run"
value: ${{ jobs.build.outputs.semver }}
file_version:
description: "The assembly info version for this run"
value: ${{ jobs.build.outputs.file_version }}
jobs:
build:
runs-on: ubuntu-latest
outputs:
semver: ${{ steps.set-version.outputs.semver }}
file_version: ${{ steps.set-info-version.outputs.file-version }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.10
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v3.0.0
with:
versionSpec: "5.x"
- name: Determine Version
id: gitversion
uses: gittools/actions/gitversion/execute@v3.0.0
- name: Set connector version
run: |
python patch_version.py ${{steps.gitversion.outputs.semVer}}
- uses: montudor/action-zip@v1
with:
args: zip -q -r sketchup.zip vendor speckle_connector_3/ speckle_connector_3.rb
- name: ⬆️ Upload artifacts
uses: actions/upload-artifact@v4
with:
name: output-${{steps.gitversion.outputs.semVer}}
path: sketchup.zip
compression-level: 0 # no compression
- id: set-version
name: Set version to output
run: echo "semver=${{steps.gitversion.outputs.semVer}}" >> "$GITHUB_OUTPUT" # version will be retrieved from tag?
- id: set-info-version
name: Set version to output
run: echo "file-version=${{steps.gitversion.outputs.AssemblySemVer}}" >> "$GITHUB_OUTPUT" # version will be retrieved from tag?