Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-223

support `command arguments` notation (backticks) for executing scripts

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • None
    • None
    • parser
    • None

    Description

      We should support `cmd` to be syntax sugar for this...

      "cmd".execute()

      which returns an instance of java.lang.Process. In addition if this expression is used within a String it should make a GString which extracts the output of the command in the middle of the string.

      e.g.

      println "blah `command` blah"

      it should behave like

      println "blah ${`command`.text} blah"

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jstrachan James Strachan
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: