DeLaGuardo / setup-graalvm

MIT License
62 stars 17 forks source link

How to install native image on Windows #8

Closed lispyclouds closed 3 years ago

lispyclouds commented 3 years ago

Thanks a lot for this handy action! 😄

I have been happily using this for Mac and Linux but wanted to try out native images for Windows too but im running into the following issues when trying to run gu install native-image:

This is my YAML

- name: Setup GraalVM
  uses: DeLaGuardo/setup-graalvm@master
  with:
    graalvm-version: '20.3.0.java11'
- name: Setup Leiningen
  uses: DeLaGuardo/setup-clojure@master
    with:
      lein: 2.9.5
- name: Install native image toolchain
  shell: bash # Or without this
  run: gu install native-image # This is what fails
lispyclouds commented 3 years ago

I tried setting up the PATH manually too but my limited Windows skills are failing me miserably 🙁

DeLaGuardo commented 3 years ago

I'll have a look. Probably you right and this is just misconfiguration so should be easy to fix

DeLaGuardo commented 3 years ago

To install additional components on windows you can use gu.cmd instead of gu however, I don't know yet why there is a difference between windows and other platforms (they all should work the same) :(

BlueSkunka commented 2 years ago

By default, windows has an alias named 'gu' for Get-Unique command

dermoritz commented 1 year ago

what is "gu" and how to install it on windows?

DeLaGuardo commented 1 year ago

@dermoritz it is a command line tool called GraalVM updater - https://www.graalvm.org/latest/reference-manual/graalvm-updater/

I recommend using official action from graalvm and this is how you can use gu on windows - https://github.com/graalvm/setup-graalvm/blob/main/.github/workflows/test.yml#L119-L126