I have Jenkinsfile
it's written in Groovy, but file name doesn't have approprite extension: .groovy
. How can I tell IDEA to check groovy syntax of this file?
Update: Also I interested in the same question about GoLand IDE
I have Jenkinsfile
it's written in Groovy, but file name doesn't have approprite extension: .groovy
. How can I tell IDEA to check groovy syntax of this file?
Update: Also I interested in the same question about GoLand IDE
From the project sidebar, right-click the file and choose "Associate with File Type". Then just select Groovy from the menu, and you're all set.
GoLand does not support Groovy so this will not be possible there.
If you add following header comment in the beginning of your Jenkinsfile
:
#!groovy
IntelliJ IDEA will automatically recognize this file as a Groovy source file. It should work for other editors and IDEs as well.