Compulsory Task 1 Follow these steps: ● Create an empty folder called git_task_project. ● Open your terminal or command prompt and then change directory (cd) to your newly created folder. ● Enter the git init command to Initialise your new repository. ● Enter the git status command and make a note of what you see. You should have a clean working directory. ● Create a new file in the git_task_project folder called helloWorld.py and write a program that prints out the message “Hello World!” ● Run the git status command again. You should now see that your helloWorld.py file is untracked. ● Enter the git add command followed by helloWorld.py to start tracking your new file. ● Once again, run the git status command. You should now see that your helloWorld.py file is tracked and staged to be committed ● Now that it is tracked, let us change the file helloWorld.py. Change the message printed out by the program to “Git is awesome!” ● Run git status again. You should see that helloWorld.py appears under a section called “Changes not staged for commit”. This means that the file is tracked but has been modified and not yet staged. ● Take a screenshot of this change and title it: git_modified.pdf or git_modified.jpeg. Include it as part of your submission. ● To stage your file, simply run git add again. ● If you run git status again you should see that it is once again staged for your next commit. ● You can now commit your changes by running the git commit -m command. Remember to enter a suitable commit message after the -m switch. ● Running the git status command should show a clean working directory once again. ● Now run the git log command. You should see your commit listed. ● Take a screenshot of the output and add it to the task folder. Name the submitted image file: git_log.pdf or git_log.jpeg.
Compulsory Task 1
Follow these steps:
● Create an empty folder called git_task_project.
● Open your terminal or command prompt and then change directory (cd) to
your newly created folder.
● Enter the git init command to Initialise your new repository.
● Enter the git status command and make a note of what you see. You
should have a clean working directory.
● Create a new file in the git_task_project folder called helloWorld.py and
write a program that prints out the message “Hello World!”
● Run the git status command again. You should now see that your
helloWorld.py file is untracked.
● Enter the git add command followed by helloWorld.py to start tracking
your new file.
● Once again, run the git status command. You should now see that your
helloWorld.py file is tracked and staged to be committed
● Now that it is tracked, let us change the file helloWorld.py. Change the
message printed out by the program to “Git is awesome!”
● Run git status again. You should see that helloWorld.py appears under a
section called “Changes not staged for commit”. This means that the file is
tracked but has been modified and not yet staged.
● Take a screenshot of this change and title it: git_modified.pdf or
git_modified.jpeg. Include it as part of your submission.
● To stage your file, simply run git add again.
● If you run git status again you should see that it is once again staged for
your next commit.
● You can now commit your changes by running the git commit -m
command. Remember to enter a suitable commit message after the -m
switch.
● Running the git status command should show a clean working directory
once again.
● Now run the git log command. You should see your commit listed.
● Take a screenshot of the output and add it to the task folder. Name the
submitted image file: git_log.pdf or git_log.jpeg.
![](/static/compass_v2/shared-icons/check-mark.png)
Step by step
Solved in 3 steps with 3 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)