Shell scripting help
Create a script that moves files you've downloaded from directory to destination. The script should take two arguments: from and to. The categories could be files with the following characters as the file name's first letters (case insensitive): A to F, G to L, M to R, S to Z. and "-" for the rest. Each of these categories should be represented as a directory in the destination and creation of these directories should be done interactively (Hint: command "read"). However, ask for creation of these subdirectories only if the destination directory itself exists. If it doesn't exists, create an error report and exit prematurely. Check also the existence of the "from" directory and the number of arguments.
|
Welcome to LQ:
Sounds like a plan. Show us your code. :) Or specify what kind of "help" you need exactly. Thank you, |
is OP giving out assignments to LQ personal? Someone ask Root if we get credits for that.. someone .. hello?
|
Quote:
We can help, but we are NOT going to do your assignment for you. Show us what you have, and we might make suggestions. |
Just a little something to get you started in a direction.
For and Read-While Loops in Bash http://www.compciv.org/topics/bash/loops/ |
you may also need one or two of the following but due to the laziness of the first post, I ain't gunna say which
http://tldp.org/LDP/abs/html/fto.html |
|
Quote:
Please review the Site FAQ as well as the LQ Rules for further information about what other members are saying to you. LQ and the members are not here to provide on call support or provide free support for questions. Instead LQ is here to help you to learn more about Linux. Therefore showing your effort with this is important. Further, without having shown any of your effort, LQ members cannot know what script language you are using, what environment you have, or what existing knowledge level you have with scripting, therefore any answers they may offer would potentially be incorrect advice. |
Hit and run?
|
All times are GMT -5. The time now is 11:37 AM. |