Console Plugin
  1. Console Plugin
  2. GPCONSOLE-1

Ability to point console at a file on the file system

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: Grails-Console 1.0
    • Fix Version/s: Grails-Console 1.2
    • Labels:
      None
    • Patch Submitted:
      Yes
    • Patch attached:
      Yes

      Description

      Sometimes I use console service to develop various scripts that run on our server (e.g. importing data). When the script gets somewhat lengthy, it becomes more difficult to manage, plus I have to copy and paste it to an editor to save it. This is very cumbersome, plus using an IDE can help during such script development.

      I modified the console plugin to have a file mode. You can activate it by going to /console/file (and disable by going to /console/nofile). Then it expects the first line to be the file location/name, e.g. /tmp/MyScript.groovy, and it runs it.

      This allows me to edit the file separately from the console plugin, which I found very useful.

      I've been meaning to contribute my code changes for some time into GIT, but for now attaching my version here so that others can either merge them in themselves, or at least get access to this functionality.

        Activity

        Hide
        Burt Beckwith added a comment -

        I implemented this a bit differently, adding a text box to type the file path into and adding a button to execute its contents

        Show
        Burt Beckwith added a comment - I implemented this a bit differently, adding a text box to type the file path into and adding a button to execute its contents

          People

          • Assignee:
            Burt Beckwith
            Reporter:
            Jean Barmash
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: