Skip to content

timt/sbt-npm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sbt-npm Build Status Download

A really simple sbt plugin for running npm (or yarn) tasks as part of sbt build process

Requirements

Installation

Add the following lines to your plugins.sbt

//autoplugin
addSbtPlugin("io.shaka" % "sbt-npm" % "8")

Usage

sbt npm [some command]

e.g. sbt "npm --version"
or   sbt-prompt> npm --version

This will run the command 'npm --version' in the project default working directory '.'

Setting to specify location of the npm executable

npmExec := "/usr/local/bin/npm"

Setting working directory for npm

npmWorkingDir := "src/main/elm"

Setting npm commands to run as part of the compile phase

npmCompileCommands := "run build"

Setting npm commands to run as part of the compile phase

npmTestCommands := "run test"

Setting npm commands to run as part of the clean phase

npmTestCommands := "run clean"

To use yarn instead of npm set the npmExec setting to the location of yarn

e.g. nmpExec := "/usr/local/bin/yarn"

Code license

Apache License 2.0

About

Run npm tasks as part of an sbt build

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published