From 66867ef3796692e2f6fd3315c3be5abcae4d37ad Mon Sep 17 00:00:00 2001 From: Shlomo Dahan <64103471+shlomomdahan@users.noreply.github.com> Date: Fri, 8 Nov 2024 15:16:31 -0500 Subject: [PATCH] [JENKINS-74057] Extract inline script block in `BuildCardExtension/buildCardHelpers.jelly` (#146) --- .../build-card-script-helpers.js | 7 +++++++ .../BuildCardExtension/buildCardHelpers.jelly | 14 +------------- 2 files changed, 8 insertions(+), 13 deletions(-) create mode 100644 src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/build-card-script-helpers.js diff --git a/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/build-card-script-helpers.js b/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/build-card-script-helpers.js new file mode 100644 index 00000000..22ca1121 --- /dev/null +++ b/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/build-card-script-helpers.js @@ -0,0 +1,7 @@ +Handlebars.registerHelper('startScript', function() { + return new Handlebars.SafeString(""); +}); diff --git a/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/buildCardHelpers.jelly b/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/buildCardHelpers.jelly index 2bf013e3..6e20ffe1 100644 --- a/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/buildCardHelpers.jelly +++ b/src/main/resources/au/com/centrumsystems/hudson/plugin/buildpipeline/extension/BuildCardExtension/buildCardHelpers.jelly @@ -7,17 +7,5 @@ By default we just include helpers to append script tags to your build card --> - - Handlebars.registerHelper('startScript', function() { - return new Handlebars.SafeString(""); - }); - - Handlebars.registerHelper('endScript', function() { - return new Handlebars.SafeString(""); - }); - - - ]]> + \ No newline at end of file