DeLaGuardo / setup-graalvm

MIT License
62 stars 17 forks source link

Add a flag for installing the native-image tool #23

Closed helpermethod closed 2 years ago

helpermethod commented 2 years ago

Hi!

First of all, great tool, it's basically my go-to action for setting up GraalVM!

I was wondering if instead of installing the native-image executable in a separate run step, your action couldn't provide an additional flag for installing the executable, something like native-image: true?

This would allow using this action in composite actions, like here and generally simplify its usage. Wdyt?

DeLaGuardo commented 2 years ago

Hello! Thanks for using it :)

And thanks for a good idea. I can see how it can improve user experience. But at the same native-image is not the only available component. What if instead of "native-image" option there will be an option like "components" taking a list of desired component names?

    steps:
      - name: Setup GraalVM
        uses: DeLaGuardo/setup-graalvm@master
        with:
          graalvm: '21.3.0'
          java: java17
          components:
            - native-image
            - R
            - python
          personal-token: ${{ secrets.GITHUB_TOKEN }}
helpermethod commented 2 years ago

Hi @DeLaGuardo,

I've totally forgotten that there are other installable components as well. That is a great idea!

DeLaGuardo commented 2 years ago

Good, then I can add it later this week.

michadvorak-cen38289 commented 2 years ago

Great, just what we need atm. Just note that action arguments takes only string as an input, so it will have to be separated list (ideally both comma and space being supported). Thanks

helpermethod commented 2 years ago

Closing the issue as the functionality is already implemented in the official GraalVM Github Action :).