QUESTION 1: A Project Setup Script Software developers use scripting to support good software engineering practices. For this question we will explore a standard way that software developers organize their home directory when writing software. Write a script called: mkproj ARGUMENT OWNER Example: ./mkproj Ass2 johnsmith Where: The script's name is mkproj ARGUMENT is the name of the software project the developer wants to initialize. OWNER is the username of the person whom the project belongs to. Use vi to create the script. The script must do the following in the order presented: 1. Make sure the script is running in Bash 2. If the user did not provide the correct number of arguments, then display the following error message and then terminate the script: "Error: Wrong number of arguments. Please type ./mkproj ARGUMENT OWNER. The argument is the name of the project. The OWNER is the user name the project belongs to." · · 3. If the directory "Projects" does not exist, then the script creates that directory. If the directory already exists, then nothing is done. 4. Change the working directory to Projects 5. If the directory ARGUMENT (i.e. the project name) already exists within the directory Projects, then terminate the script with the following error and change directory to the parent directory (where we came from): "Error: The project name has already been used. Please select another project name and try again." 6. Create the directory ARGUMENT (i.e. the project name). 7. Change the current directory to the directory ARGUMENT (i.e. the project name) 8. Create the subdirectories: archive, docs, source. Then use the 1s command to display them as verification to the user. 9. Create a readme.txt file in the docs directory with the following default information: "Created by:" and then insert the OWNER name. Display the file as verification to the user.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
QUESTION 1: A Project Setup Script
Software developers use scripting to support good software engineering practices. For
this question we will explore a standard way that software developers organize their
home directory when writing software.
Write a script called: mkproj ARGUMENT OWNER
Example: ./mkproj Ass2 johnsmith
Where:
The script's name is mkproj
ARGUMENT is the name of the software project the developer wants to initialize.
OWNER is the username of the person whom the project belongs to.
Use vi to create the script.
The script must do the following in the order presented:
1. Make sure the script is running in Bash
●
2.
If the user did not provide the correct number of arguments, then display the
following error message and then terminate the script: "Error: Wrong number of
arguments. Please type ./mkproj ARGUMENT OWNER. The argument is the
name of the project. The OWNER is the user name the project belongs to.
,,
3. If the directory “Projects” does not exist, then the script creates that directory. If
the directory already exists, then nothing is done.
4. Change the working directory to Projects
5. If the directory ARGUMENT (i.e. the project name) already exists within the
directory Projects, then terminate the script with the following error and change
directory to the parent directory (where we came from): "Error: The project name
has already been used. Please select another project name and try again."
6.
Create the directory ARGUMENT (i.e. the project name).
7. Change the current directory to the directory ARGUMENT (i.e. the project name)
8. Create the subdirectories: archive, docs, source. Then use the 1s command to
display them as verification to the user.
9. Create a readme.txt file in the docs directory with the following default
information: "Created by:" and then insert the OWNER name. Display the file as
verification to the user.
Transcribed Image Text:QUESTION 1: A Project Setup Script Software developers use scripting to support good software engineering practices. For this question we will explore a standard way that software developers organize their home directory when writing software. Write a script called: mkproj ARGUMENT OWNER Example: ./mkproj Ass2 johnsmith Where: The script's name is mkproj ARGUMENT is the name of the software project the developer wants to initialize. OWNER is the username of the person whom the project belongs to. Use vi to create the script. The script must do the following in the order presented: 1. Make sure the script is running in Bash ● 2. If the user did not provide the correct number of arguments, then display the following error message and then terminate the script: "Error: Wrong number of arguments. Please type ./mkproj ARGUMENT OWNER. The argument is the name of the project. The OWNER is the user name the project belongs to. ,, 3. If the directory “Projects” does not exist, then the script creates that directory. If the directory already exists, then nothing is done. 4. Change the working directory to Projects 5. If the directory ARGUMENT (i.e. the project name) already exists within the directory Projects, then terminate the script with the following error and change directory to the parent directory (where we came from): "Error: The project name has already been used. Please select another project name and try again." 6. Create the directory ARGUMENT (i.e. the project name). 7. Change the current directory to the directory ARGUMENT (i.e. the project name) 8. Create the subdirectories: archive, docs, source. Then use the 1s command to display them as verification to the user. 9. Create a readme.txt file in the docs directory with the following default information: "Created by:" and then insert the OWNER name. Display the file as verification to the user.
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Analysis of Performance Measurement
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education