groovy
  1. groovy
  2. GROOVY-138

The groovy script should automatically compile any dependent groovy scripts

    Details

    • Type: Wish Wish
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0-beta-7
    • Component/s: None
    • Labels:
      None
    • Number of attachments :
      0

      Description

      This works right now for groovlets - we should offer a similar feature when running things from the command line. Here's an example from Mark Volkmann...

      I have a script in a file named Person.groovy that looks like the following.

      class Person {
      name
      age
      }

      I have another script in a file called Demo.groovy that looks like the
      following.

      p = new Person(name:"Jeremy", age:16)

      I didn't compile either script with groovyc.
      I want to run Demo.groovy with the following.

      groovy Demo.groovy

      but that results in MissingClassException: No such class: Person

        Activity

        Hide
        Michael Ivey added a comment -

        It would also be very cool to have a groovy script that would notice when its classes were modified, and re-compile. Also like groovlets.

        Show
        Michael Ivey added a comment - It would also be very cool to have a groovy script that would notice when its classes were modified, and re-compile. Also like groovlets.
        Hide
        John Stump added a comment -

        This feature works now. Can we close this?

        Show
        John Stump added a comment - This feature works now. Can we close this?
        Hide
        james strachan added a comment -

        Sure - BTW John you can close things too

        Show
        james strachan added a comment - Sure - BTW John you can close things too

          People

          • Assignee:
            Unassigned
            Reporter:
            james strachan
          • Votes:
            2 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: