Article 53WM5 Shell script

Shell script

by
BringMara
from LinuxQuestions.org on (#53WM5)
Hi,I am really struggling with a homework.I have to make a shell script that will copy to a separate path the files in which the user modified more than 20 lines on a specific date.The files should also be archived and them deleted.
What I know right now:
To copy a file somewhere else i use this:
$ ls dir1/
dir2/
$ cp -r dir1/ dir1.copy
$ ls dir1.copy
dir2/
To show number of lines in a file and modified files in the last days:
wc -l file1
mtime or find ~/Desktop -type f -newermt 2020-05-22 -ls for example

I use tar for archives and rm to remove.The problem is I have very little experience with linux and I don't know how to form the final shell script.latest?d=yIl2AUoC8zA latest?i=3dpse5fS5VM:QLgwMqKyRPg:F7zBnMy latest?i=3dpse5fS5VM:QLgwMqKyRPg:V_sGLiP latest?d=qj6IDK7rITs latest?i=3dpse5fS5VM:QLgwMqKyRPg:gIN9vFw3dpse5fS5VM
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments