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...
I did already posted this question before, I did get the answer but i am not...
I did already posted this question before, I did get the answer but i am not satisfied with the answer i did the code as a solution not the description as my solution, so i am reposting this question again. Please send me the code as my solution not the description In this project, build a simple Unix shell. The shell is the heart of the command-line interface, and thus is central to the Unix/C programming environment. Mastering use of...
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....
I NEED TASK 3 ONLY TASK 1 country.py class Country:     def __init__(self, name, pop, area, continent):...
I NEED TASK 3 ONLY TASK 1 country.py class Country:     def __init__(self, name, pop, area, continent):         self.name = name         self.pop = pop         self.area = area         self.continent = continent     def getName(self):         return self.name     def getPopulation(self):         return self.pop     def getArea(self):         return self.area     def getContinent(self):         return self.continent     def setPopulation(self, pop):         self.pop = pop     def setArea(self, area):         self.area = area     def setContinent(self, continent):         self.continent = continent     def __repr__(self):         return (f'{self.name} (pop:{self.pop}, size: {self.area}) in {self.continent} ') TASK 2 Python Program: File: catalogue.py from Country...
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...
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...
Consider the C program (twoupdate) to demonstrate race condition. In this assignment, we will implement Peterson's...
Consider the C program (twoupdate) to demonstrate race condition. In this assignment, we will implement Peterson's algorithm to ensure mutual exclusion in the respective critical sections of the two processes, and thereby eliminate the race condition. In order to implement Peterson's Algorithm, the two processes should share a boolean array calledflagwith two components and an integer variable called turn, all initialized suitably. We will create and access these shared variables using UNIX system calls relating to shared memory – shmget,...
PLEASE READ THE ARTICLES ATTACHED AND ANSWER THE FOLLOWING QUESTION. THE ARTICLES ARE BOTH LISTED PLEASE...
PLEASE READ THE ARTICLES ATTACHED AND ANSWER THE FOLLOWING QUESTION. THE ARTICLES ARE BOTH LISTED PLEASE PROVIDE DETAILED EXPLANATIONS. PLEASE WRITE ONE REFLECTION COMBINING BOTH ARTICLES. The purpose of the Article Reflection is to deepen your engagement with the topic of Epidemiology. It will give you the opportunity to reflect on the current real-life epidemiological issues at hand and help to bring meaning to them. ARTICLE 1: A group of students knew they had covid-19. They hosted a party over...
Team 5 answer the questions What are 4 key things you learned about the topic from...
Team 5 answer the questions What are 4 key things you learned about the topic from reading their paper? How does the topic relate to you and your current or past job? Critique the paper in terms of the organization and quality. Incentive Systems             In this paper, we will focus primarily on financial rewards that companies use to attract, retain and motivate the brightest and most talented candidates in the labor market. By providing a reward system that...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT