I don't have sbt console in intellij - intellij-idea

I have created my first Sbt project and I would like to open Sbt console. Perhaps I make a confusion on what is Sbt plugin. I have scala plugin so I suppose Sbt is embeded inside it since I have Sbt windows.
When I look inside View -> Tool Windows I don't see Sbt console but I see Sbt
Even In Sbt panel, I don't see it
In this blog
https://blog.jetbrains.com/scala/2017/03/23/scala-plugin-for-intellij-idea-2017-1-cleaner-ui-sbt-shell-repl-worksheet-akka-support-and-more/
I find at section 2:
It’s now possible to build projects using SBT (instead of IntelliJ IDEA’s internal build system). As this option is still experimental, it should be manually enabled via Build / Execution / Deployment / Build Tools / SBT / Use SBT shell for build and import:
but I don't see Use SBT shell for build and import checkbox.
Do you have any idea?

You are running IntelliJ 2016.2. The integrated sbt shell and build by shell option is only available from 2017.1. I suggest you upgrade IntelliJ and the IntelliJ Scala plugin directly to 2017.3, where the options you are looking for are available.

You cannot access the sbt console from IntelliJ. For that you must run sbt in a terminal (even within IntelliJ), and once you’re inside the sbt shell type ‘console’ or ‘consoleQuick’ (runs the console without compiling the project you run it at).

Related

SBT plugin for Intellij IDEA Build #IC-181

I downloaded Intellij IDEA Build #IC-181. When I want to import my SBT project, I do not find such option.
How can I add SBT support?
It looks like you did not install the Scala Plugin!
If you updated to Intellij - make sure that you also updated the Plugins.
If you have, you just can open a directory that contains a build.sbt and Intellij will automatically recognize it.

Can't find SBT-shell in IntelliJ IDEA

Facing some issue with the build, I deleted the project and .idea directories of my SBT project (containing submodules) followed by Invalidate Caches / Restart... (invalidated the cache too)
Ever since relaunch of IntelliJ, I can't locate the sbt shell
Interestingly, I'm still getting the sbt shell when I open my other projects (in which I didn't delete the project and .idea directories) in IntelliJ
I can confirm that I have the latest release of IntelliJ IDEA for MacOS with the Scala plugin installed
what fixed my problem was:
install scala plugin
restart
file -> close project
instead of open, click new project, select scala with sbt option,
then next
select the same project as location.
hope it will save you time and energy
In Intellij 2018, under Preferences - Build, Execution, Deployment - Build Tools - sbt, check "Use sbt shell for build and import (requires sbt 0.13.5+)". Then restart Intellij. The sbt shell tool window tab will appear in the bottom pane (if not, select it from View - Tool Windows - sbt shell).
In my case, scala plugin needed to be updated and accordingly this caused sbt to disappear from build tools. Go to Settings --> Plugins --> Updates and make sure that scala plugin is updated. If it wasn't and you updated it, you should restart the IDE afterwards.
After that removing the .idea folder and reimporting the project was necessary for the project to build.
You can select
Window → Restore Default layout
Or press Shift + F12
This will restore your default window layout and the tab will be visible again (You can check this works by hiding the sbt tab by right clicking and selecting 'Remove From Sidebar').
Some windows such as Maven or Ant need to be brought back by
View → ToolWindows → [Window Name]
In my case I enabled the sbt shell going to "File - Settings - Build, Execution, Deployment - Build Tools - sbt " and after enabling here, you need to restart your intellij and then you can find sbt-shell here "view- Tool window - sbt shell"

Grails application is not found after updating to IntelliJ IDEA Ultimate 2016.2

I have updated my IntelliJ IDEA Ultimate to the 2016.2 version.
I had a Grails 3 project and now when I open the IDE I get the following error when trying to run my project:
Error running Grails: My_Project: Grails application is not found
I can still open the terminal and run the project manually, but it seems that IntelliJ IDEA no longer recognises my Grails application. When going to "Edit configurations...", in "Application" it says "[none]" and I can't select anything.
Grails Version: 3.1.9
Groovy Version: 2.4.7
JVM Version: 1.8.0_66
A Simple solution to this is to refresh the gradle projects.
You can do this by popping out the little gradle tab and hitting the "Refresh All Gradle Projects"
I run into the same problem always when i restart intellij. Running grails clean command from the terminal fixed it.
First, re-import the project into IntelliJ 2016.2. Choose the build.gradle file for the import. Use the gradle wrapper or a local gradle installation, where you have given IntelliJ the path to the locally installed Gradle. Let IntelliJ re-index everything. Wait until you see no further indexing on the bottom of the screen.
Second, run the application once, with no edit configuration. After this completes with error, you should be able to choose Run -> Edit Configuration / Application.
Third, you can go into the project pane to the grails-app/init/app-name/Application.groovy file and right-click on that and choose Run. After that, an edit configuration will be created.
Finally, you can try to invalidate cache and restart. (This has nothing to do with Edit Configuration, but sometimes the gradle and/or .idea caches get out of sync.)
I had the same problem after updating to IntelliJ Ultimate 2019.2.
It seems that the "little gradle tab" of the accepted answer no longer exists.
The reason in my case was that the Gradle Plugin had been disabled by the update process.
Resolution: Hit Help > Find Action > Type gradle. You should see a line "Gradle" and a ON-OFF switch at the end of that line.
Enable it and restart IntelliJ solved my problem.

Skip tests in IntelliJ using Gradle

Does anyone know how I can skip JUnit tests in IntelliJ when doing a Gradle build like the following command line version? I have searched extensively for a solution but can't find one. I am in the process of converting an existing project to Gradle and need to support many developers that are not familiar with Gradle, some UX, some front end, and some Java. There are many broken Junit tests in the myriad modules and long-term we will fix them. Short term I need all other developers to use the tools they are familiar with to be able to do their job easily.
./gradlew build -x test
The Gradle-Android Compiler settings allow for command-line options but not non-android projects as shown in the IntelliJ settings dialog shown below.
You should be able to run a standard clean build from intellij if it's a gradle project (aka gradle integration in intellij). Then edit the configuration and add at the script parameters : -x test which will run the clean build (or any other task) without running tests.
I am using Intellij IDEA 2019.3 (Community Edition).
You can skip test using following settings.
You can get to this via Gradle panel located at right top corner.
Select task -> Run Configuration -> Right click -> Edit Run Configuration..
From intellij 2021.2 onwards, type the argument directly in Run text

IntelliJ Ant Build Window Missing

I've been working on a project in IntelliJ and now when I decided to add Ant support I realised that the Ant Build Window is missing. I have recently upgraded to Ubuntu 11.10 but I doubt it makes any difference. Is this a known bug?
I am using IntelliJ IDEA Ultimate 10.5 and it works just fine. Even without having build.xml file I can open that window by pressing Ctrl + Shift + A and searching for Ant Build.
If you are missing this option you probably don't have installed/enabled Ant support plugin. Check out File -> Settings -> Plugins.
Please check that Ant plug-in in enabled in Settings | Plugins.