Git Product home page Git Product logo

Comments (2)

rwjblue avatar rwjblue commented on July 2, 2024

Thanks for opening this issue! This is definitely a bug conceptually, sorry about that!

I think the solution here would have to be to do something like:

  • Use the node-version specified as part of volta install node@<the version> to change the default / global node to the specified version (this is what we do now)
  • IFF the project has a top level package.json we run volta pin node@<the version> (this is the fix for the issue you reported)

from action.

alexlafroscia avatar alexlafroscia commented on July 2, 2024

That makes sense to me! I wasn't sure if the node-version setting was only supposed to be used to pre-download a particular Node version, but it honestly doesn't make a whole lot of sense to download it if it isn't used!

In the meantime, it should be possible to solve it like this I think, right?

name: Verify

on: [push]

jobs:
  test:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        node-version: [6.7.0, 12.16.1]
    steps:
      - uses: actions/checkout@v1
      - uses: volta-cli/action@v1
      - name: Switch Node version
        run: volta pin node@${{ matrix.node-version }}
      - run: yarn install
      - run: yarn test

I no longer actually need to do this on the project I originally tried this on, but I would love to see this supported. I'm really loving Volta and have started using it pretty heavily!

from action.

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.