Giter Site home page Giter Site logo

scala-cli-setup's Introduction

Scala CLI setup GitHub Action

A GitHub Action to install Scala CLI.

Features

  • run it on any platform: Linux, MacOS, Windows
  • install any JVM you need
  • setup the build tool of your choice: sbt, mill, seed, etc.
  • install other common Scala CLI tools: Ammonite, Bloop, giter8, etc.

Inputs

  • scala-cli-version (optional): scala-cli version to install
    • "latest" to install the latest version.
  • jvm (optional): JVM to install
    • one of the options from cs java --available.
    • if left empty either the existing JVM will be used or Coursier will install its default JVM.
  • apps (optional): Scala apps to install (sbtn by default)
  • version (optional): Coursier version to install
    • This is defaulted to the latest stable release of Coursier
  • power (optional): Value for the --power launcher option
    • Necessary for using feature of scala-cli that require the --power option, like publishing.
    • Defaults to false

Environment variables

  • JAVA_HOME: path to the JVM to use
  • COURSIER_BIN_DIR: (optional) path to the directory where Coursier will install app binaries
    • defaults to $HOME/cs/bin
    • shouldn't have to be tampered with for vanilla GitHub action runners
    • make sure the directory is reachable for self-hosted runners
    • in case of issues, you can set it to something like
      env:
        COURSIER_BIN_DIR: ${{ github.workspace }}/cs/bin

Example with custom inputs

  steps:
    - uses: actions/checkout@v2
    - uses: VirtusLab/scala-cli-setup@main
      with:
        jvm: adopt:11
        apps: sbtn bloop ammonite

Outputs

  • cs-version: version of the installed Coursier (should be the latest available)
  • scala-cli-version: version of the installed Scala CLI (should be the latest available)

Caching

This action should work well with the official Coursier cache-action. For example:

  steps:
    - uses: actions/checkout@v2
    - uses: coursier/cache-action@v6
    - uses: VirtusLab/scala-cli-setup@main

scala-cli-setup's People

Contributors

dependabot[bot] avatar tgodzik avatar github-actions[bot] avatar gedochao avatar alexarchambault avatar lwronski avatar laughedelic avatar actions-user avatar web-flow avatar ckipp01 avatar ptrdom avatar hugo-vrijswijk avatar romanowski avatar balmungsan avatar maciejg604 avatar 2m avatar olafurpg avatar

Stargazers

Dallin Huff avatar Tu Nguyen avatar He-Pin(kerr) avatar Bruno Henriques avatar Alessandro avatar Martin Mauch avatar Aleh Reishal avatar Shohei Shimomura avatar Andriy Plokhotnyuk avatar Satoshi Kobayashi avatar Shunsuke Tadokoro avatar ebigram avatar Thanh Le avatar spamegg avatar Matt Bovel avatar  avatar

Watchers

James Cloos avatar Andriy Plokhotnyuk avatar  avatar  avatar  avatar

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.