SlideShare ist ein Scribd-Unternehmen logo
1 von 1
Downloaden Sie, um offline zu lesen
Create a shell program which: 1. Called mynewshellscript.sh 2. Displays to the terminal the
message "About to begin the program" 3. Displays the current working directory. 4. Displays the
current user. 5. Creates an empty file called text.txt 6. Does the following 20 times: a. Tests if the
file text.txt exists b. If the file exists i. Display the message "Going to delete the file text.txt" ii.
Deletes the file text.txt c. If the file does not exist i. Display the message "Going to create the file
text.txt" ii. Creates a file text.txt which is the output of the list command from the current directory
7. Displays the message "Ending the program"

Weitere ähnliche Inhalte

Mehr von yuvarajm76

Cuestionario de comunicaciones comerciales 15 La declara.pdf
Cuestionario de comunicaciones comerciales   15   La declara.pdfCuestionario de comunicaciones comerciales   15   La declara.pdf
Cuestionario de comunicaciones comerciales 15 La declara.pdf
yuvarajm76
 
Cuestionario de prctica de OPS 2 Los beneficios de la agr.pdf
Cuestionario de prctica de OPS  2 Los beneficios de la agr.pdfCuestionario de prctica de OPS  2 Los beneficios de la agr.pdf
Cuestionario de prctica de OPS 2 Los beneficios de la agr.pdf
yuvarajm76
 

Mehr von yuvarajm76 (20)

Cul de las siguientes afirmaciones sobre la hepatitis B V.pdf
Cul de las siguientes afirmaciones sobre la hepatitis B V.pdfCul de las siguientes afirmaciones sobre la hepatitis B V.pdf
Cul de las siguientes afirmaciones sobre la hepatitis B V.pdf
 
Cul de las siguientes afirmaciones sobre la especiacin al.pdf
Cul de las siguientes afirmaciones sobre la especiacin al.pdfCul de las siguientes afirmaciones sobre la especiacin al.pdf
Cul de las siguientes afirmaciones sobre la especiacin al.pdf
 
Cul de las siguientes afirmaciones sobre la gemacin de ve.pdf
Cul de las siguientes afirmaciones sobre la gemacin de ve.pdfCul de las siguientes afirmaciones sobre la gemacin de ve.pdf
Cul de las siguientes afirmaciones sobre la gemacin de ve.pdf
 
Cul de las siguientes afirmaciones representa la fotosnte.pdf
Cul de las siguientes afirmaciones representa la fotosnte.pdfCul de las siguientes afirmaciones representa la fotosnte.pdf
Cul de las siguientes afirmaciones representa la fotosnte.pdf
 
Cul de las siguientes afirmaciones sobre el efecto del pH .pdf
Cul de las siguientes afirmaciones sobre el efecto del pH .pdfCul de las siguientes afirmaciones sobre el efecto del pH .pdf
Cul de las siguientes afirmaciones sobre el efecto del pH .pdf
 
Cuando no conocemos las desviaciones estndar de la poblaci.pdf
Cuando no conocemos las desviaciones estndar de la poblaci.pdfCuando no conocemos las desviaciones estndar de la poblaci.pdf
Cuando no conocemos las desviaciones estndar de la poblaci.pdf
 
Cul de estos cidos grasos de 18 carbonos tendra el menor.pdf
Cul de estos cidos grasos de 18 carbonos tendra el menor.pdfCul de estos cidos grasos de 18 carbonos tendra el menor.pdf
Cul de estos cidos grasos de 18 carbonos tendra el menor.pdf
 
Cul de estos componentes proporciona redundancia de datos .pdf
Cul de estos componentes proporciona redundancia de datos .pdfCul de estos componentes proporciona redundancia de datos .pdf
Cul de estos componentes proporciona redundancia de datos .pdf
 
Cuestionario de comunicaciones comerciales 15 La declara.pdf
Cuestionario de comunicaciones comerciales   15   La declara.pdfCuestionario de comunicaciones comerciales   15   La declara.pdf
Cuestionario de comunicaciones comerciales 15 La declara.pdf
 
Cuanto ms relacionadas estn dos especies ms similares so.pdf
Cuanto ms relacionadas estn dos especies ms similares so.pdfCuanto ms relacionadas estn dos especies ms similares so.pdf
Cuanto ms relacionadas estn dos especies ms similares so.pdf
 
Critical values for quick reference during this activity In.pdf
Critical values for quick reference during this activity In.pdfCritical values for quick reference during this activity In.pdf
Critical values for quick reference during this activity In.pdf
 
Cul de estas texturas ayuda al gelogo a determinar si una.pdf
Cul de estas texturas ayuda al gelogo a determinar si una.pdfCul de estas texturas ayuda al gelogo a determinar si una.pdf
Cul de estas texturas ayuda al gelogo a determinar si una.pdf
 
Cuestionario de prctica de OPS 2 Los beneficios de la agr.pdf
Cuestionario de prctica de OPS  2 Los beneficios de la agr.pdfCuestionario de prctica de OPS  2 Los beneficios de la agr.pdf
Cuestionario de prctica de OPS 2 Los beneficios de la agr.pdf
 
Cuando un gran nmero de especies a veces taxones principal.pdf
Cuando un gran nmero de especies a veces taxones principal.pdfCuando un gran nmero de especies a veces taxones principal.pdf
Cuando un gran nmero de especies a veces taxones principal.pdf
 
Cub Foods grocery stores have more than one location in Mank.pdf
Cub Foods grocery stores have more than one location in Mank.pdfCub Foods grocery stores have more than one location in Mank.pdf
Cub Foods grocery stores have more than one location in Mank.pdf
 
Creeping commitment refers to an approach to systems develop.pdf
Creeping commitment refers to an approach to systems develop.pdfCreeping commitment refers to an approach to systems develop.pdf
Creeping commitment refers to an approach to systems develop.pdf
 
Cuckoo Egg LengthsCuckoos lay their eggs in the nests of .pdf
Cuckoo Egg LengthsCuckoos lay their eggs in the nests of .pdfCuckoo Egg LengthsCuckoos lay their eggs in the nests of .pdf
Cuckoo Egg LengthsCuckoos lay their eggs in the nests of .pdf
 
Cuando se transfiere un grupo fosfato del ATP el transporte.pdf
Cuando se transfiere un grupo fosfato del ATP el transporte.pdfCuando se transfiere un grupo fosfato del ATP el transporte.pdf
Cuando se transfiere un grupo fosfato del ATP el transporte.pdf
 
Cuando Noruega Islandia Liechtenstein y Suiza se unieron a.pdf
Cuando Noruega Islandia Liechtenstein y Suiza se unieron a.pdfCuando Noruega Islandia Liechtenstein y Suiza se unieron a.pdf
Cuando Noruega Islandia Liechtenstein y Suiza se unieron a.pdf
 
Cuando las empresas son contratadas por otras empresas para .pdf
Cuando las empresas son contratadas por otras empresas para .pdfCuando las empresas son contratadas por otras empresas para .pdf
Cuando las empresas son contratadas por otras empresas para .pdf
 

Kürzlich hochgeladen

Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
ZurliaSoop
 

Kürzlich hochgeladen (20)

Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structure
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
Wellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptxWellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptx
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)Jamworks pilot and AI at Jisc (20/03/2024)
Jamworks pilot and AI at Jisc (20/03/2024)
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptx
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptx
 
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptxOn_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
 

Create a shell program which 1 Called mynewshellscriptsh .pdf

  • 1. Create a shell program which: 1. Called mynewshellscript.sh 2. Displays to the terminal the message "About to begin the program" 3. Displays the current working directory. 4. Displays the current user. 5. Creates an empty file called text.txt 6. Does the following 20 times: a. Tests if the file text.txt exists b. If the file exists i. Display the message "Going to delete the file text.txt" ii. Deletes the file text.txt c. If the file does not exist i. Display the message "Going to create the file text.txt" ii. Creates a file text.txt which is the output of the list command from the current directory 7. Displays the message "Ending the program"