What is the Default File Type for Jenkinsfile in Pycharm
I understand how to change default file type associations for formatting in pycharm.
What I don't know is what file is associated with Jenkinsfile files.
I can't find an entry for it, but it's clearly formatting stuff for me. I'd like to change its tabs / associate other files with it. I would have thought yaml or groovy but the first is wrong and the second isn't an option.
Thanks for any help!
Please sign in to leave a comment.
Jenkinsfile uses groovy syntax, and it's managed by TextMate Bundles
You can modify the settings for groovy bundle by editing <IDE_HOME>/plugins/textmate/lib/bundles/groovy/package.json
Settings related to file pattern:
This is great, but is it possible to add "Groovy" or "Jenkinsfile" as a recognized file types?
Gabenovstan My previous comment explains just that. You can add any file name/extension/pattern to the desired TextMate bundle.
Hello, nice tip thanks. Problem is although I have the textmate bundles installed and enabled I have no <IDE_HOME>/plugins/textmate folder. I can create it but then I don't know which structure is supposed to have the whole file, I cannot just use the snippet. Where can I find a complete file for reference ? Or am I missing soomething ? Thanks
Do you have a plugin directory there?
If not, how was PyCharm installed initially?
Hey. Yes I have the plugins directory. I have installed pycharm using the DMG provided by Jetbrains.
For MacOS, it should be something like this: /Applications/Pycharm.app/Contents/plugins/.
Thanks, so now I can find the file here: /Applications/PyCharm.app/Contents/plugins/textmate/lib/bundles/groovy/package.json
I suppose there is a folder for user plugin and a folder for internal plugins. Anyway, my file contains (extract):
And my files are named `Jenkinsfile-build`, `Jenkinsfile-toto` and there is no syntax highlightning in the application.
I have checked that the groovy texmate bundle is activated in the settings and it is.
What do I miss ?
BTW I have also tested “Jenkinsfile.*” for the pattern and restarted Pycharm but I did not help.
Hello Bigjohnaumic ,
We have the issue related to Jenkinsfile: https://youtrack.jetbrains.com/issue/IDEA-327196
Can you please check if this fix can help you? The fix is available in 2023.3 Beta version.