On Wed, 25 Apr 2007, Peter Dalgaard wrote:
> Ernest Turro wrote:
>> It seems unlink doesn't work with wildcards in 2.5.0. I've tried
>> R-2.5.0 under gnu/linux from source and the Mac binary from att
>> research. Example:
>>
>> > dir()
>> [1] "bgx.Rnw" "bgx.pdf" "run.1"
>> > unlink("run.*",recursi
Ernest Turro wrote:
> It seems unlink doesn't work with wildcards in 2.5.0. I've tried
> R-2.5.0 under gnu/linux from source and the Mac binary from att
> research. Example:
>
> > dir()
> [1] "bgx.Rnw" "bgx.pdf" "run.1"
> > unlink("run.*",recursive=T)
> > dir()
> [1] "bgx.Rnw" "bgx.pdf" "run
Thanks, this now works.
I'd just like to mention that Sys.glob() wasn't necessary in 2.4.1
and this potential requirement should perhaps be mentioned in ?unlink.
Thanks
E
On 25 Apr 2007, at 12:38, Prof Brian Ripley wrote:
> This is shell-dependent on a Unix-alike, but Sys.glob() should
> w
This is shell-dependent on a Unix-alike, but Sys.glob() should work. So
try
unlink(Sys.glob("run.*"), recursive=TRUE)
On Wed, 25 Apr 2007, Ernest Turro wrote:
> It seems unlink doesn't work with wildcards in 2.5.0. I've tried
> R-2.5.0 under gnu/linux from source and the Mac binary from att
>
It seems unlink doesn't work with wildcards in 2.5.0. I've tried
R-2.5.0 under gnu/linux from source and the Mac binary from att
research. Example:
> dir()
[1] "bgx.Rnw" "bgx.pdf" "run.1"
> unlink("run.*",recursive=T)
> dir()
[1] "bgx.Rnw" "bgx.pdf" "run.1"
> unlink("run.1",recursive=T)
>