File tree Expand file tree Collapse file tree 2 files changed +33
-6
lines changed Expand file tree Collapse file tree 2 files changed +33
-6
lines changed Original file line number Diff line number Diff line change 7
7
description : " Test with develop branch"
8
8
required : false
9
9
type : boolean
10
+ arm_toolchain_version :
11
+ description : " ARM toolchain version"
12
+ required : false
13
+ type : string
14
+ default : " default"
15
+ riscv_toolchain_version :
16
+ description : " RISC-V toolchain version"
17
+ required : false
18
+ type : string
19
+ default : " default"
10
20
11
21
jobs :
12
22
build :
@@ -24,12 +34,14 @@ jobs:
24
34
key : pico-sdk-${{ hashFiles('scripts/genExamples.py') }}
25
35
- name : Run genExamples.py
26
36
env :
27
- SDK_VERSION : ${{ inputs.develop && '2-develop' || '' }}
37
+ SDK_VERSION : ${{ inputs.develop && '2-develop' || 'default' }}
38
+ ARM_TOOLCHAIN_VERSION : ${{ inputs.arm_toolchain_version }}
39
+ RISCV_TOOLCHAIN_VERSION : ${{ inputs.riscv_toolchain_version }}
28
40
run : |
29
41
python scripts/genExamples.py
30
42
- name : List errors
31
43
run : |
32
- ls -la errors-pico*
44
+ ls -la errors-pico* || true
33
45
- name : Upload Artifact
34
46
uses : actions/upload-artifact@v4
35
47
with :
Original file line number Diff line number Diff line change 37
37
38
38
CURRENT_DATA_VERSION = "0.17.0"
39
39
40
- SDK_VERSION = os .environ .get ("SDK_VERSION" , "2.1.1" )
41
- ARM_TOOLCHAIN_VERSION = os .environ .get ("ARM_TOOLCHAIN_VERSION" , "14_2_Rel1" )
42
- RISCV_TOOLCHAIN_VERSION = os .environ .get (
43
- "RISCV_TOOLCHAIN_VERSION" , "RISCV_ZCB_RPI_2_1_1_3"
40
+ SDK_VERSION_DEFAULT = "2.1.1"
41
+ ARM_TOOLCHAIN_VERSION_DEFAULT = "14_2_Rel1"
42
+ RISCV_TOOLCHAIN_VERSION_DEFAULT = "RISCV_ZCB_RPI_2_1_1_3"
43
+
44
+
45
+ def env_get_default (env_var , default ):
46
+ value = os .environ .get (env_var , default )
47
+ if value == "default" :
48
+ # The action passes default in the environment variable
49
+ value = default
50
+ return value
51
+
52
+
53
+ SDK_VERSION = env_get_default ("SDK_VERSION" , SDK_VERSION_DEFAULT )
54
+ ARM_TOOLCHAIN_VERSION = env_get_default (
55
+ "ARM_TOOLCHAIN_VERSION" , ARM_TOOLCHAIN_VERSION_DEFAULT
56
+ )
57
+ RISCV_TOOLCHAIN_VERSION = env_get_default (
58
+ "RISCV_TOOLCHAIN_VERSION" , RISCV_TOOLCHAIN_VERSION_DEFAULT
44
59
)
45
60
46
61
# To test with develop SDK, uncomment the line below - this will clone the SDK & picotool, and build picotool & pioasm
You can’t perform that action at this time.
0 commit comments