in reply to Re: Rolling variable (Update:prime the counts file first!)
in thread Rolling variable
The first time you run this you will get an error because the file counts doesn't exist.
Also, do you mean to have both @F and @f?
Running this on my machine adds nothing to the file.
$ pwd /Users/nick/monks $ ls | wc -l 39 $ perl -i'*' -anle"@f=</Users/nick/monks/*>; shift @F; push @F, scalar + @f; print join ' ', @F;" counts $ cat counts $
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Rolling variable
by BrowserUk (Patriarch) on Jul 30, 2015 at 17:07 UTC | |
by 1nickt (Canon) on Jul 30, 2015 at 17:28 UTC | |
by BrowserUk (Patriarch) on Jul 30, 2015 at 18:21 UTC |