diff --git a/02_activities/assignments/assignment.sh b/02_activities/assignments/assignment.sh index bead5b68..ecf27919 100644 --- a/02_activities/assignments/assignment.sh +++ b/02_activities/assignments/assignment.sh @@ -14,7 +14,12 @@ mkdir dir1 dir2 dir3 dir4 dir5 ls # 3. Create 5 text files in dir2 named file1, file2, file3, file4, and file5 -dir2/ Touch file1.txt file2.txt file3.txt file4.txt file5.txt +cd dir2/ +touch file1.txt +touch file2.txt +touch file3.txt +touch file4.txt +touch file5.txt # 4. Append the words "Hello world" to dir2/file3 echo "Hello World" >> dir2/file3.txt @@ -23,10 +28,10 @@ echo "Hello World" >> dir2/file3.txt cat dir2/file3.txt # 6. Delete file4 -rm_ dir2/file4 +rm dir2/file4.txt # 7. Delete directories dir4 and dir5 including all their contents (if any) -rm_ dir4 dir5 +rm dir4 dir5 # 8. List the contents of the parent directory to verify the deletion of dir4 and dir5 -ls /dir4 dir 5 +ls dir4 dir5