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

The Edit command should replace the shell buffer, not append.

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.1.5
    • 2.2.0-beta-1
    • Groovysh
    • None
    • Patch

    Description

      When you use the edit command in groovysh, the editor's contents should replace the current shell buffer, not append to it.

      Steps to reproduce:

      1) launch groovysh on any platform
      2) type an incomplete expression:
      groovy:000> x = {
      3) type '\e' to launch an editor
      4) Complete the expression in the editor:
      x =

      { println 2 + 2 }
      5) save and close the editor
      6) notice the new expression has not been parsed and executed
      7) type '\d' to display the current buffer. Notice the edit command appended rather than replaced the current buffer:
      groovy:002> \d
      000> x = {
      001> x = { println 2 + 2 }

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            pschumacher Pascal Schumacher
            larryj Larry Jacobson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment