So I am current learning bash and am struggling as this is my 1st program. Would
ID: 3563428 • Letter: S
Question
So I am current learning bash and am struggling as this is my 1st program. Would love some help with this if its possible. thank you
I am currently working on the back-end of an industry server where the following activity is required: when programmers log into their Unix account all the source files in their Source directory must be copied into their Backup directory automatically and immediately. The Source directory is a sud-directory of their home directory and the Backup directory is a sub-directory of their Source directory. They also want the programmers, while using the command-line, to be able to write a single command that would automatically do this backup operation immediately. Lastly, they want, after log-in, to alias the command "Is -1 -a" to "lsa". They also want to modify the command-line prompt to include the company motto (but you can put your own motto). This means that whatever the command-line prompt currently displays it should continue displaying but in addition it will include your motto (or phrase, anything you like). Create the above directory structure on your Ubuntu account in Trottier. Use bash to write a script that will perform this backup operation using relative paths when typed at the command-line as a command. Assume this script is saved in the Source directory. Update your Trottier log-in script to automatically run this backup script every time you log-in. Modify your log-in script to also implement the alias operation and the prompt modification operation. Use the "man" command to help you do this. Name your backup script "backup" and submit that as your answer. Identify which login script is your active login script in Trottier, modify it, then submit that file as your answer.Explanation / Answer
In your .bashrc or .profile (or maybe even .bash_profile) file in your home directory add (.bashrc usually contains other aliases, but this varies according to setup, I would check the .bashrc file and add there with the others):
alias lsa=
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.