Skip to content

Commit

Permalink
Update assignment.sh
Browse files Browse the repository at this point in the history
This is try number 2
  • Loading branch information
lisafeeney33 authored Aug 23, 2024
1 parent 9086570 commit db08154
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions 02_activities/assignments/assignment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,11 @@ set -x
mkdir dir1 dir2 dir3 dir4 dir5

# 2. List the contents of the parent directory to verify the presence of the 5 directories
ls dir1 dir2 dir3 dir4 dir5
ls

# 3. Create 5 text files in dir2 named file1, file2, file3, file4, and file5
mkdir file1 file2 file3 file4 file5
mv file1 dir2
mv file2 dir2
mv file3 dir2
mv file4 dir2
mv file5 dir2
cd /c/Users/Lisa/Dir2
Touch file1 file2 file3 file4 file5

# 4. Append the words "Hello world" to dir2/file3
echo "Hello World" >> dir2/file3.txt
Expand All @@ -28,11 +24,11 @@ echo "Hello World" >> dir2/file3.txt
cat file3.txt

# 6. Delete file4
rm file4
$ rm file4 -r

# 7. Delete directories dir4 and dir5 including all their contents (if any)
rm dir4 dir5

# 8. List the contents of the parent directory to verify the deletion of dir4 and dir5
CD ~
LS
ls

0 comments on commit db08154

Please sign in to comment.