it's still experemental.
Currently works only if
sctags used as CLI utility if SCALA_LIB and SCALA_HOME
enviroument variables configured according to
sctags readme (see #1).
(Currently works only with Sbt 0.13x)
It able generate ctags file (currently in emacs format (aka etags)) for your
project with tags for dependencies.
(TAGS file allow you to get
go to definition functionality for Scala files at
text editors like emacs which has
Tags file will be generated by patched version of SCtags (probably different tags generations backends will be available later).
In compasion to
Exuberant Ctags current backend has better undestanding of
Scala code specific and as result you will get much better failure rate at
go to definition attempts.
Just add following to your
// libraryDependencies += "cc.evgeniy" %% "sctags" % "1.0.1" // this not required currently because of current classpath configuration issue see Warn section of readme addSbtPlugin("cc.evgeniy" % "sbt-ctags4s" % "0.1.1")
Because of #1 currently you have to install sctags as separate CLI utility and provide correct set up for SCALA_HOME and SCALA_LIB.
How it works - example
First update your dependencies:
Then select the dependency you wish to import for example
> ctagsAdd <tab>... > ctagsAdd org.scala-lang:scala-library... ... or ... > ctagsAdd org.scala-lang* ... or ... > ctagsAdd *
This will extract the
scala-library source into
.lib-src/org.scala-lang.scala-library/ and run ctags over the whole project including the imported sources. Both Java and Scala libs can be added.
Now you can use ctags to navigate the
Make sure to add the following to your
.lib-src tags ctags
You can remove a library for your tags file with:
> ctagsRemove <tab>... > ctagsRemove org.scala-lang... ... or ... > ctagsRemoveAll ... or ... > ctagsRemove *
> help ctagsDownload > help ctagsAdd > help ctagsShowCurrent > help ctagsRemove > help ctagsRemoveAll
-  fix classpath setup issue #1
-  sbt settings which allow choose result format (etags, ctags) and backend kind (ctags, SCTags etc.)
-  sbt obsolete API reactor
-  add Sbt 1x support (with crossbuilding to 0.13x)
Currently it's just a mix of following projects:
Copyright 2017 Evgeniy Tokarev
Copyright (c) 2013 Kalman Bekesi
Copyright 2008 Geoff Reedy
Copyright 2015 Luben Karavelov
Published under the Apache License 2.0.