Git Product home page Git Product logo

setup-scarb's People

Contributors

ametel01 avatar evolveart avatar mkaput avatar mrdenkov avatar pfcrowe avatar szymmis avatar tomek0123456789 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

setup-scarb's Issues

Read `scarb-version` from `.tool-versions`

Problem

Better to avoid having the scarb version repeated across many places

Proposed Solution

Something like this:

      - name: Getting scarb
        uses: software-mansion/setup-scarb@v1
        with:
          scarb-version: from-tool-versions

/.tool-versions in the repo:

scarb 0.5.2

Notes

No response

Allow providing custom path to `.tool-versions` file to look at

Problem

One of our users has a Scarb project in a submodule/subdirectory of the repository. This project contains a .tool-versions file that the user wants to use as reference point for version selection, but there is no way to instruct the action to look for this file elsewhere than the working directory.

Proposed Solution

Add a new input, named tool-versions, typed as an optional string. It will accept a path, absolute or relative to action's PWD, to the tool-versions file, that must exist. If provided, the action will always and only look for Scarb version in that provided path. No other deduction techniques will be applied, and inability to look for information should yield an error.

Example:

- uses: software-mansion/setup-scarb@v1
  with:
    tool-versions: ./my-submodule/.tool-versions

Notes

Most of the meat lies in this file: https://github.com/software-mansion/setup-scarb/blob/67ef98b555967b95dd7fc56ecdd1e93ce7cefdae/lib/versions.js. It is called from here:

setup-scarb/lib/main.js

Lines 15 to 22 in 67ef98b

const scarbVersionInput = core.getInput("scarb-version");
const { repo: scarbRepo, version: scarbVersion } = await determineVersion(
scarbVersionInput,
{
repo: "software-mansion/scarb",
nightliesRepo: "software-mansion/scarb-nightlies",
},
);

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.