[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Tue, 20 Jul 2021 21:38:20 +0000 (UTC)
In one folder I have list of several files. Based on a condition (grep) I
want pick the latest file from all files and and copy this file to somehwere.
Here is my sample of the zipped files and my attempt
I used this,
ll | grep -e AB1 |tail -1
the result is
How do I copy this file to this folder?
ll | grep -e AB1 |tail -1 -exec bash -c 'cp "$1" c:\data\AB1
did not work.