Questions tagged [sbt-plugin]

A plugin extends the build definition, most commonly by adding new settings. The new settings could be new tasks. For example, a plugin could add a codeCoverage task which would generate a test coverage report.

An SBT plugin extends the build definition, most commonly by adding new settings. The new settings could be new tasks. For example, a plugin could add a codeCoverage task which would generate a test coverage report.

192 questions
1
vote
2 answers

How does publishing a "thrift repo" work with Scrooge and associated plugins?

Scrooge has both plugins for sbt and for maven. I am not really interested in the maven plugin. It would appear the sbt plugin has the ability to extract thrift files from a dependency artifact. See the scroogeThriftDependencies option here However…
jedesah
  • 2,983
  • 2
  • 17
  • 29
1
vote
1 answer

SBT plugin just for your local machine

Often time, I need to add SBT plugin which is not applicable to the project but just for myself. For example, I use eclipse as my IDE so I want to enable this plugin for all my SBT projects without having to include it in plugin.sbt file. This is…
user_1357
  • 7,766
  • 13
  • 63
  • 106
1
vote
0 answers

Why sbt-jsHint is not executing on "sbt jshint" command?

I am using sbt-jsHint plugin by typeFace: https://github.com/sbt/sbt-jshint Followed the steps as mentioned in the document, but could not the run the "sbt jshint" and getting invalid command error in sbt console. Question: 1. What is best way to…
Sandeep
  • 21
  • 3
1
vote
1 answer

why are sbt moving to AutoPlugin?

I've recently been informed that my sbt plugins don't work using the magical new "Auto Plugin" feature, which is the recommended mechanism. why are sbt doing this? will all plugins have to be updated? will it support sonatype snapshot…
fommil
  • 5,757
  • 8
  • 41
  • 81
1
vote
1 answer

Unable to run custom sbt task from AutoPlugin's command

I tried everything I could think of but running taskB still ends up with the error message that task is not defined either in */*:taskB or in */cmd:taskB if I put it in custom configuration. Command.command("doStuff", Help.more("doStuff",…
lisak
  • 21,611
  • 40
  • 152
  • 243
0
votes
1 answer

sbt scala tutorial for plugin tutorial is not adding in the grizzled plugin correctly

I'm trying to follow the steps listed here https://www.scala-sbt.org/1.x/docs/Plugins.html#Using+a+library+in+a+build+definition+example so I have project/plugins.sbt, (I changed this line b/c the original line wasn't installing due to prob the…
user2167582
  • 5,986
  • 13
  • 64
  • 121
0
votes
1 answer

How can I use sbt commands like clean and compile in my custom sbtplugin

I have the following, minimal, custom sbt plugin, where I'd like to implement (override) the standard clean command to do the same action as myTask. package nigeleke.sbt import sbt.* import Keys.* import scala.sys.process.* object MyPlugin…
Nigel Eke
  • 531
  • 1
  • 6
  • 18
0
votes
1 answer

Unable to import plugin to scala project

I added this to /project/plugins.sbt: resolvers += "bintray-spark-packages" at "https://dl.bintray.com/spark-packages/maven/" addSbtPlugin("org.spark-packages" % "sbt-spark-package" % "0.2.6") in order to import…
AT181903
  • 11
  • 4
0
votes
1 answer

fetch set plugin from CodeArtifacts using sbt fail

I used this explanation how to publish and fetch SBT libraries from CodeArtifacts: Publish artifact to AWS CodeArtifact with sbt my issue is that one of the things I want to publish is not a library, its a plugin, so I used the same explanation,…
JohnBigs
  • 2,691
  • 3
  • 31
  • 61
0
votes
1 answer

scalafmt download error while using nexus

I want to use Scalafmt in corporate network ( on a windows machine) using Nexus. I get below error if i run scalafmt [error] failed to resolve Scalafmt version '2.4.6': X:\ProjectA\.scalafmt.conf [error] (Compile / scalafmt) failed to resolve…
KK2486
  • 353
  • 2
  • 3
  • 13
0
votes
1 answer

SBT Formatter Plugin Using Common Config File

I have the following piece of code: package my.package import sbt._ import Keys._ object OpenElectronsScalaFmtPlugin extends AutoPlugin { override def trigger = allRequirements override def requires = plugins.JvmPlugin override def…
joesan
  • 13,963
  • 27
  • 95
  • 232
0
votes
1 answer

SBT Plugin Published Locally Fails with an Error When Included in a Project

I have implemented a simple sbt plugin which I published locally to my .ivy repository. I wanted to use this plugin on one of my project for which I added it in my plugins.sbt file. I then tried to run this from the console and it failed with the…
joesan
  • 13,963
  • 27
  • 95
  • 232
0
votes
0 answers

SBT Plugin Published Locally Could not Resolve Proper Scala Version

I wrote a simple sbt plugin which I published locally on my machine. I wanted to reference this plugin in one of my project and I ran into errors. The sbt plugin that I published had the following settings: lazy val root = (project in file(".")). …
joesan
  • 13,963
  • 27
  • 95
  • 232
0
votes
0 answers

intellij: 'sbt' is not recognized

I have installed sbt plugin in intellij, but whne I try to run some sbt command, it is not recognized. >sbt clean compile 'sbt' is not recognized as an internal or external command, operable program or batch file. Shouldn't sbt plugin take care of…
Mandroid
  • 6,200
  • 12
  • 64
  • 134
0
votes
1 answer

sbt-protoc error File does not reside within any path specified using --proto_path (or -I).You must specify a --proto_path which encompasses this file

I've scala grpc protobuf project with below build.sbt. ThisBuild / version := "0.1.0-SNAPSHOT" val openRtbCoreVersion = "1.5.5" val googleCommonProtosVersion = "1.12.0" val commonSettings: Seq[Def.Setting[_]] = Seq[Def.Setting[_]]( scalaVersion…
user51
  • 8,843
  • 21
  • 79
  • 158