How to develop a Custom Keywords Plugin


This is a companion discussion topic for the original entry at


I’m getting the following error when packaging my custom keywords (I’m new with Gradle):

~/test-projects/ $ gradle katalonPluginPackage
Starting a Gradle Daemon (subsequent builds will be faster)

FAILURE: Build failed with an exception.

  • Where:
    Build file ‘/home/pentaho6/test-projects/’ line: 1

  • What went wrong:
    A problem occurred evaluating root project ‘’.

Could not find method plugins() for arguments [build_6tdk8u13k3f1rr6ysushd0pq$_run_closure1@204a1f6e] on root project ‘’ of type org.gradle.api.Project.

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at


My build.gradle file has this content (almost identical to the one in documentation):

plugins {
id ‘java’
id ‘groovy’
id ‘com.github.johnrengelman.shadow’ version ‘4.0.4’
id “com.katalon.gradle-plugin” version “0.0.6”

repositories {

sourceSets {
main {
groovy {
srcDirs = [‘Keywords’, ‘Include/scripts/groovy’]
srcDir ‘Libs’

shadowJar {
exclude ‘Temp*.class’

katalon {
dependencyPrefix = “com.katalon”
minimize = false

groovydoc {

source = ‘Keywords/com/runmyprocess’
docTitle = ‘RunMyProcess Custom Keywords’

And my katalon-plugin.json has this content:

“keywords”: [


Ok, I’ve fixed it: edit the file build.gradle with line ending of type Unix (LF) or MacOS, but not Windows line ends (CR+LF).
I did the same with file Keywords/katalon-plugin.json, but I’m not sure if this last is required to use LF.
That modification solved the issue.


To generate the .jar plugin with a different name than the project, especify in your build.gradle (at the end for example):

archivesBaseName = ‘runmyprocess-custom-keywords-for-katalon’


only the fail in version 7.0,it is very good in version 6.3.3


Please make sure the project has been opened by KS at least once.