Question

NOTE: I just need the answer for question 5 and 6. I already knew the question...

NOTE: I just need the answer for question 5 and 6. I already knew the question 1-4, and wrote down all the requirements for clarification.

In this assignment, you are required to write a Bash script, call it assignment2.sh. Your Bash script has to accept at least four input arguments, and must:

1) Print to the user a set of instructions explaining how the PATH variable can be used in Bash.

2) Save the manual of the 'awk' command in the file /tmp/help.txt.

3) Shut down your Ubuntu box at 2 o'clock tonight.

4) Store your name and your partner's name in a text file inside your home directory. The name of the file must have the following format: ite404-<date>.txt, where <date> is the current date; e.g. ite404-2020-10-26.txt.

5) Get the input arguments and print them. After that, create four other scripts to print the first four words, respectively. For example, if the user inputs 'HELLO FROM AUIS UNI', then the first generated script must print the word 'HELLO', the second script must print 'FROM', and so forth.

6) Download Ubuntu 20.04 and store on a USB memory stick, which must act as a bootable DVD.

NOTE: I just need the answer for question 5 and 6. I already knew the question 1-4, and wrote down all the requirements for clarification.

Homework Answers

Answer #1

As mentioned in the quesution this solution to Quesion 5:
assignment2.sh

#!bash.sh

input=$1
echo $input


a=( $input )


cat > script1.sh << EOF1
echo "${a[0]}"
EOF1

cat > script2.sh << EOF1
echo "${a[1]}"
EOF1


cat > script3.sh << EOF1
echo "${a[2]}"
EOF1


cat > script4.sh << EOF1
echo "${a[3]}"
EOF1
----------------------------------------------------------------------------------------------------

Steps to run above script:
Lenovo@DESKTOP-ILNTL2L MINGW64 ~/Downloads
$ ./assignment2.sh 'Tmaway mata chapita tumi bandhu'
Tmaway mata chapita tumi bandhu

Lenovo@DESKTOP-ILNTL2L MINGW64 ~/Downloads
$ ./script1.sh
Tmaway

Lenovo@DESKTOP-ILNTL2L MINGW64 ~/Downloads
$ ./script2.sh
mata

Lenovo@DESKTOP-ILNTL2L MINGW64 ~/Downloads
$ ./script3.sh
chapita

Lenovo@DESKTOP-ILNTL2L MINGW64 ~/Downloads
$ ./script4.sh
tumi

Solution Question 6 :

It needs downloading of the software to a hardware device.It needs physical prescence.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Question I This question carries 20% of the marks for this assignment. You are asked to...
Question I This question carries 20% of the marks for this assignment. You are asked to develop a set of bash shell script: Write a script that asks for the user's salary per month. If it is less or equals to 800, print a message saying that you need to get another job to increase your income, what you earn is the Minim living cost. If the user's salary is higher than 800 and below 2000, print a message telling...
please I want you to answer this question and most importantly, the answer is not already...
please I want you to answer this question and most importantly, the answer is not already available on this site or other site Course Learning Outcome: Apply Organizational behavior knowledge and skills to manage diversified culture in the organizational settings (Lo 2.2). Essay: Differences in Culture and Diversity at workplace Essay Write an essay about the differences in Culture and Diversity at workplace. Use examples, peer-reviewed journals to support your answer. This essay must be at least 1000-word in length....
You will write a program that loops until the user selects 0 to exit. In the...
You will write a program that loops until the user selects 0 to exit. In the loop the user interactively selects a menu choice to compress or decompress a file. There are three menu options: Option 0: allows the user to exit the program. Option 1: allows the user to compress the specified input file and store the result in an output file. Option 2: allows the user to decompress the specified input file and store the result in an...
Hello, I have question 4 and 5 answered, with the answers provided. I just need some...
Hello, I have question 4 and 5 answered, with the answers provided. I just need some help on question 6, thanks! Q4.   On Friday, April 3, 2019 you bought the following portfolio for the prices in the table:                                                                                                   Prices            Prices                                                                                    Beta                4,3,2019         4,3,2020 10,000 shares of IBM (IBM)                              b = 1.44           S = $80.79        S = $90.45 20,000 shares of CITIGP (C)                              b = 1.23           S = $37.23        S = $12.67 7,500   shares of BOING (BA)                           ...
***** this is question and answer i just need the schema Data Modelling is the primary...
***** this is question and answer i just need the schema Data Modelling is the primary step in the process of database design. Compare and contrast Conceptual data model versus Physical data model. Illustrates with help of example to list down data (entities), relationship among data and constraints on data. Data Modeling:- Data Modeling is the first step in database designing.It is the representation of data model, or collected data. Also shows that collected data stored in database and linked...
Please answer in JAVA IDS 401 Assignment 4 Deadline In order to receive full credit, this...
Please answer in JAVA IDS 401 Assignment 4 Deadline In order to receive full credit, this assignment must be submitted by the deadline on Blackboard. Submitting your assignment early is recommended, in case problems arise with the submission process. Late submissions will be accepted (but penalized 10pts for each day late) up to one week after the submission deadline. After that, assignments will not be accepted. Assignment The object of this assignment is to construct a mini-banking system that helps...
Task #4 Calculating the Mean Now we need to add lines to allow us to read...
Task #4 Calculating the Mean Now we need to add lines to allow us to read from the input file and calculate the mean. Create a FileReader object passing it the filename. Create a BufferedReader object passing it the FileReader object. Write a priming read to read the first line of the file. Write a loop that continues until you are at the end of the file. The body of the loop will: convert the line into a double value...
Question: can I have answers with the five requirements? Golf World, Inc., issued $240,000 of 6%,...
Question: can I have answers with the five requirements? Golf World, Inc., issued $240,000 of 6%, 15-year bonds dated January 1, 2018 that will pay interest semiannually on June 30 and December 31. These bonds were issued at $198,494, and the market rate of interest was 8% at the issue date. Notice that you are given the face value and the selling price, so you can already determine if it was sold at a Discount or a Premium. This problem...
Write a 4-6 sentence summary explaining how you can use STL templates to create real world...
Write a 4-6 sentence summary explaining how you can use STL templates to create real world applications. In your summary, provide an example of a software project that you can create using STL templates and provide a brief explanation of the STL templates you will use to create this project. After that you will implement the software project you described . Your application must be a unique project and must incorporate the use of an STL container and/or iterator and...
Jim Watanabe was in his new car, driving down I-5, on his way to work. He...
Jim Watanabe was in his new car, driving down I-5, on his way to work. He dreaded the phone call he knew he was going to have to make. The original go-live date for a pilot implementation of Petrie Electronics’ new customer relationship management (CRM) system was July 31. That was only six weeks away, and Jim knew there was no way they were going to be ready. The XRA CRM they were licensing turned out to be a lot...