Giter Site home page Giter Site logo

Comments (2)

per1234 avatar per1234 commented on July 23, 2024

Hi @Jackbennett. I see there is an error in the documentation for the cli-compile-flags input. Instead of "YAML-format list of flags", it should say "YAML-format list of arguments".

You must use a separate element in the array for each of the arguments. Your current workflow produces an Arduino CLI command like this:

arduino-cli compile "--build-property build.extra_flags=-VARIANT_SELECTED=0" [...]

If you change it to this it should work as expected (though you probably meant to use -DVARIANT_SELECTED instead of -VARIANT_SELECTED):

          cli-compile-flags: |
            - --build-property
            - build.extra_flags=-VARIANT_SELECTED=${{ matrix.variant }}

The error in the documentation should be fixed and a simple example added to demonstrate the usage.

from compile-sketches.

Jackbennett avatar Jackbennett commented on July 23, 2024

Mmm ok makes sense. Can confirm that's working.

          cli-compile-flags: |
            - --build-property
            - build.extra_flags=-DVARIANT_SELECTED=${{ matrix.variant }}]

And yes thanks for the -D tip I'd missed that entirely, otherwise:

 avr-g++: error: unrecognized command line option '-VARIANT_SELECTED=1'

Edit* oh and the matrix injection works as expected.

from compile-sketches.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.