[
https://issues.apache.org/jira/browse/GROOVY-2681?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Sun resolved GROOVY-2681.
--------------------------------
Resolution: Fixed
> In-place edit (-i option) still fails across file systems.
> ----------------------------------------------------------
>
> Key: GROOVY-2681
> URL: https://issues.apache.org/jira/browse/GROOVY-2681
> Project: Groovy
> Issue Type: Bug
> Components: command line processing
> Affects Versions: 1.5.4
> Environment: I am using Ubuntu 7.10 (Linux).
> $ groovy -v
> Groovy Version: 1.5.4 JVM: 1.6.0_03-b05
> Reporter: Tim Heaney
> Assignee: Daniel Sun
> Priority: Minor
> Fix For: 7.0.0-alpha-1
>
>
> The situation described in
> http://jira.codehaus.org/browse/GROOVY-820
> still exists when executed from a file system different from the one on which
> /tmp is mounted. The symptoms are exactly the same
> $ groovy -pi -e "(line =~ 'a').replaceAll('b')" foo
> Caught: java.io.IOException: unable to rename foo to /tmp/groovy_15520.tmp
> $ groovy -pi.bak -e "(line =~ 'a').replaceAll('b')" foo
> If the rename fails, isn't there a way to do a copy and delete, rather than
> just throw an exception?
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)