Add tree/GITHUB_REF to yml file so Compile Sketch runs on the current branch, not main

This commit is contained in:
PaulZC
2021-12-02 10:15:08 +00:00
parent 9c52398855
commit 1b7ba984c3
+5 -2
View File
@@ -1,7 +1,7 @@
name: Compile Sketch
on:
# - push
- push
- pull_request
@@ -88,13 +88,16 @@ jobs:
- name: Checkout
uses: actions/checkout@v2
- name: Branch name
run: echo running on branch ${GITHUB_REF##*/}
- name: Compile Sketch
uses: arduino/compile-sketches@v1
with:
platforms: ${{ matrix.board.platforms }}
fqbn: ${{ matrix.board.fqbn }}
libraries: |
- source-url: https://github.com/${{github.repository}}.git
- source-url: https://github.com/${{github.repository}}/tree/${GITHUB_REF##*/}.git
sketch-paths: |
- examples/Example10_AltitudeMSL
- examples/Example11_ResetModule/Example1_FactoryDefaultviaI2C