• Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Major Major
    • scriptler-plugin
    • None

      It would be great if one could generate HTML output in the Groovy scripts executed in scriptler.

      A typical usage is when you have a script which filters builds matching some criteria. Currently we have just the build id, like "Project #116". Instead we could have something like:

      <a href="http://jenkins:8080/job/Project/116">Project #116</a>
      

          [JENKINS-10839] Allow for HTML output in scriptler

          Maybe it's a security issue (for us it doesn't seem to be), but wouldn't it be enough to get rid of the wrapping <pre> element and add HTML escaping?

          grzegorz_oledzki added a comment - Maybe it's a security issue (for us it doesn't seem to be), but wouldn't it be enough to get rid of the wrapping <pre> element and add HTML escaping?

          Frank Merrow added a comment -

          Yeah, I came here to file this exact CR, found this and voted for it instead.

          Outputting HTML tables and such would be huge . . . though I suspect it would require Jenkins support.

          If security is the issue (mentioned above), about about at least allow us to create a HTML page "someplace" and provide a link to it. That way you could build the results in HTML and make it easy for the user to browse to it. This does have problems though given multiple users from multiple clients . . . you need someplace to store the HTML and some kind of clean up function for when the user is done with it (or 2 days later) . . .

          Frank

          Frank Merrow added a comment - Yeah, I came here to file this exact CR, found this and voted for it instead. Outputting HTML tables and such would be huge . . . though I suspect it would require Jenkins support. If security is the issue (mentioned above), about about at least allow us to create a HTML page "someplace" and provide a link to it. That way you could build the results in HTML and make it easy for the user to browse to it. This does have problems though given multiple users from multiple clients . . . you need someplace to store the HTML and some kind of clean up function for when the user is done with it (or 2 days later) . . . Frank

          I guess for most use cases it would be enough to allow links to jobs and builds. At least for everything I wanted to create links in Groovy scripts for that would do...

          Florian Loikasek added a comment - I guess for most use cases it would be enough to allow links to jobs and builds. At least for everything I wanted to create links in Groovy scripts for that would do...

          Code changed in jenkins
          User: imod
          Path:
          src/main/resources/org/jenkinsci/plugins/scriptler/ScriptlerManagment/runscript.jelly
          http://jenkins-ci.org/commit/scriptler-plugin/20636e7b887de37cb00abb3a7cd36f89ae4f5c40
          Log:
          [FIXED JENKINS-10839] Allow for HTML output in scriptler

          Compare: https://github.com/jenkinsci/scriptler-plugin/compare/fe0d444...20636e7

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: imod Path: src/main/resources/org/jenkinsci/plugins/scriptler/ScriptlerManagment/runscript.jelly http://jenkins-ci.org/commit/scriptler-plugin/20636e7b887de37cb00abb3a7cd36f89ae4f5c40 Log: [FIXED JENKINS-10839] Allow for HTML output in scriptler Compare: https://github.com/jenkinsci/scriptler-plugin/compare/fe0d444...20636e7

          dogfood added a comment -

          Integrated in plugins_scriptler #44
          [FIXED JENKINS-10839] Allow for HTML output in scriptler (Revision 20636e7b887de37cb00abb3a7cd36f89ae4f5c40)

          Result = SUCCESS
          imod :
          Files :

          • src/main/resources/org/jenkinsci/plugins/scriptler/ScriptlerManagment/runscript.jelly

          dogfood added a comment - Integrated in plugins_scriptler #44 [FIXED JENKINS-10839] Allow for HTML output in scriptler (Revision 20636e7b887de37cb00abb3a7cd36f89ae4f5c40) Result = SUCCESS imod : Files : src/main/resources/org/jenkinsci/plugins/scriptler/ScriptlerManagment/runscript.jelly

            domi Dominik Bartholdi
            grzegorz_oledzki grzegorz_oledzki
            Votes:
            2 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: