CAREFULLY READ ALL THE INSTRUCTIONS BEFORE STARTING THESE EXERCISES!
To start this assignment:
- Click the button in the upper right-hand corner that says Fork. This is now your copy of the document.
- Click the Edit button when you're ready to start adding your answers.
- To save your work, click the green button in the bottom right-hand corner. You can always come back and re-edit your gist.
Read this article on git commit messages
- Your key take-aways OR how you're going to implement specific points (minimum 2):
- [The commit message is about communicating context to either different devs or future you, a diff will tell you what changed but the commit message will tell you why it changed. Well written commit messages will show how well of a collaborator the dev is.]
- [maintaing a successful project comes down to different thing but mainly how well the project log is laid out and that comes back to commit messages]
What's the use of the staging area in git? on Stackoverflow (15 min)
The idea of the staging area is frequently one of the trickiest concepts to wrap your head around when you're first learning git. Read the question and answers (or do your own Googling on the git staging area). Then, create your OWN metaphor comparing the staging area to something in real life.
- Type your metaphor below: [The staging area with git is like planning a vacation with an itinerary, you are able to see all the plans and details to the vacation before "commiting" by bying the plane ticket and all other purchases and going to the vacation loaction. just like with Git, you are able to see the whole production of the project but are still able to make adjustments if needed to certain areas before the commit. ]
Follow the steps below to practice the git workflow. Be ready to copy-paste your terminal output as confirmation of your practice.
-
Create a directory called
git_homework. Inside of there, create a file calledthoughts.md -
Initialize the directory
-
Use
git statusto ensure you are set up for tracking using Git -
Add your
thoughts.mdto the staging area -
Check the
git status -
Create an initial commit (Note: Be sure to follow the correct message format for your first commit!)
-
Check the
git status -
Add two takeaways you've had from your first few classes of Mod 0 as it relates to success at Turing.
-
Check the
git status -
Check the changes you've made using
git diff -
Add the changes to the staging area
-
Commit the new changes (Note: Be sure to follow convention for commit messages!)
-
Check the status
-
Add two new strategies you are committed to trying during the rest of Mod 0 to
thoughts.md -
Add the changes to the staging area
-
Commit the new changes (Note: Be sure to follow convention for commit messages!)
-
Add at least one shoutout to someone who has helped you, supported you, or just been a positive presence in the last two weeks!
-
Add the changes to the staging area
-
Commit the new changes (Note: Be sure to follow convention for commit messages!)
-
Show the log of your work in
onelineformat usinggit log(This will likely require some Googling) [commit f0b0f8cd6a4580d16279922fe2db652a74e95bec (HEAD -> main) Author: Sam Iavri sammi80134@gmail.com Date: Thu Aug 26 15:10:52 2021 -0600Shout out
commit d48e2c9cfc9df1bf28b033fa8ab9eb98c83e58eb Author: Sam Iavri sammi80134@gmail.com Date: Thu Aug 26 15:08:59 2021 -0600
Two new stratigies to commit to
commit 4e1b3ecc3b5ad4a3cfd93cc9b6feabbead9406db Author: Sam Iavri sammi80134@gmail.com Date: Thu Aug 26 15:03:46 2021 -0600
Two take aways from Mod 0 so far
commit 1e583eb1fc9b60418fb01464af297df3b7053853 Author: Sam Iavri sammi80134@gmail.com Date: Thu Aug 26 14:26:10 2021 -0600
Initial commit
] Copy and paste all of the terminal text from this process below (not just the history):
/Users/samanthaivari $🍺pwd
/Users/samanthaivari
/Users/samanthaivari $🍺cd
/Users/samanthaivari $🍺ls
Creative Cloud Files Downloads Music cool_projects
Desktop Library Pictures to_do
Documents Movies Public
/Users/samanthaivari $🍺mkdir git_homework
/Users/samanthaivari $🍺ls
Creative Cloud Files Downloads Music cool_projects
Desktop Library Pictures git_homework
Documents Movies Public to_do
/Users/samanthaivari $🍺cd git_homework
/Users/samanthaivari/git_homework $🍺touch thoughts.md
/Users/samanthaivari/git_homework $🍺ls
thoughts.md
/Users/samanthaivari/git_homework $🍺git commit
fatal: not a git repository (or any of the parent directories): .git
/Users/samanthaivari/git_homework $🍺git commit git_homework
fatal: not a git repository (or any of the parent directories): .git
/Users/samanthaivari/git_homework $🍺.git commit
zsh: command not found: .git
/Users/samanthaivari/git_homework $🍺git init
Initialized empty Git repository in /Users/samanthaivari/git_homework/.git/
/Users/samanthaivari/git_homework main $🍺git status
On branch main
No commits yet
Untracked files:
(use "git add <file>..." to include in what will be committed)
thoughts.md
nothing added to commit but untracked files present (use "git add" to track)
/Users/samanthaivari/git_homework main $🍺git add git_homework
fatal: pathspec 'git_homework' did not match any files
/Users/samanthaivari/git_homework main $🍺git add thoughts.md
/Users/samanthaivari/git_homework main $🍺git status
On branch main
No commits yet
Changes to be committed:
(use "git rm --cached <file>..." to unstage)
new file: thoughts.md
/Users/samanthaivari/git_homework main $🍺git commit-m "Initial commit"
git: 'commit-m' is not a git command. See 'git --help'.
The most similar command is
commit-tree
/Users/samanthaivari/git_homework main $🍺git commit -m "Initial commit"
[main (root-commit) 1e583eb] Initial commit
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 thoughts.md
/Users/samanthaivari/git_homework main $🍺git status
On branch main
nothing to commit, working tree clean
/Users/samanthaivari/git_homework main $🍺Two take aways from session 1 of Mod 0 about sucess at Turing was, to be disciplined about time managment and to utilize google as a tool.
zsh: command not found: Two
/Users/samanthaivari/git_homework main $🍺[Two take aways from session 1 of Mod 0 about sucess at Turing was, to be disciplined about time managment and to utilize google as a tool.]
zsh: bad pattern: [Two
/Users/samanthaivari/git_homework main $🍺pwd
/Users/samanthaivari/git_homework
/Users/samanthaivari/git_homework main $🍺ls
thoughts.md
/Users/samanthaivari/git_homework main $🍺atom. Two take aways about being sucessful at Turing from Mod 0 so far are, be disciplined about your time managment and to utilize google as a tool
zsh: command not found: atom.
/Users/samanthaivari/git_homework main $🍺atom . Two take aways about being sucessful at Turing from Mod 0 so far are, be disciplined about your time managment and to utilize google as a tool
/Users/samanthaivari/git_homework main $🍺atom .
/Users/samanthaivari/git_homework main $🍺atom .
/Users/samanthaivari/git_homework main $🍺git status
On branch main
nothing to commit, working tree clean
/Users/samanthaivari/git_homework main $🍺git diff
/Users/samanthaivari/git_homework main $🍺git status
On branch main
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: thoughts.md
no changes added to commit (use "git add" and/or "git commit -a")
/Users/samanthaivari/git_homework main $🍺git diff
diff --git a/thoughts.md b/thoughts.md
index e69de29..61942db 100644
--- a/thoughts.md
+++ b/thoughts.md
@@ -0,0 +1 @@
+Two take aways about being successful at Turing from Mod 0 so far are, be disciplined about your time management and to utilize google as a tool.
/Users/samanthaivari/git_homework main $🍺git add
Nothing specified, nothing added.
hint: Maybe you wanted to say 'git add .'?
hint: Turn this message off by running
hint: "git config advice.addEmptyPathspec false"
/Users/samanthaivari/git_homework main $🍺git add .
/Users/samanthaivari/git_homework main $🍺git commit -m "Two take aways from Mod 0 so far"
[main 4e1b3ec] Two take aways from Mod 0 so far
1 file changed, 1 insertion(+)
/Users/samanthaivari/git_homework main $🍺git status
On branch main
nothing to commit, working tree clean
/Users/samanthaivari/git_homework main $🍺git add .
/Users/samanthaivari/git_homework main $🍺git commit -m "Two new stratigies to commit to"
[main d48e2c9] Two new stratigies to commit to
1 file changed, 1 insertion(+)
/Users/samanthaivari/git_homework main $🍺git add .
/Users/samanthaivari/git_homework main $🍺git commit -m "Shout out"
[main f0b0f8c] Shout out
1 file changed, 1 insertion(+)
/Users/samanthaivari/git_homework main $🍺git log
commit f0b0f8cd6a4580d16279922fe2db652a74e95bec (HEAD -> main)
Author: Sam Iavri <sammi80134@gmail.com>
Date: Thu Aug 26 15:10:52 2021 -0600
Shout out
commit d48e2c9cfc9df1bf28b033fa8ab9eb98c83e58eb
Author: Sam Iavri <sammi80134@gmail.com>
Date: Thu Aug 26 15:08:59 2021 -0600
Two new stratigies to commit to
commit 4e1b3ecc3b5ad4a3cfd93cc9b6feabbead9406db
Author: Sam Iavri <sammi80134@gmail.com>
Date: Thu Aug 26 15:03:46 2021 -0600
Two take aways from Mod 0 so far
commit 1e583eb1fc9b60418fb01464af297df3b7053853
Author: Sam Iavri <sammi80134@gmail.com>
Date: Thu Aug 26 14:26:10 2021 -0600
Initial commit
IMPORTANT: Do NOT remove this git_homework directory. You will be using this directory during the next session.
Your task: create a "Plan for Mod 0" documenting your gameplan for success in Mod 0, using Markdown.
Markdown (.md) is the format all of your homework gists are written in.
Using this markdown cheatsheet, create a new gist of your own by clicking the New Gist button in the upper right-hand corner of the screen.
Also, images can be a little tricky in gists and Github - be sure to check out the drag-n-drop shortcut from the first answer on this Stack Overflow post!
In the box to title your Gist, be sure to use follow this format: firstName_lastName_mod_0_plan.md
NOTE: Remember to add a .md file extension to filename of your new Gist. Otherwise it will not register as markdown.
In addition to documenting your gameplan for success in Mod 0, incorporate each of the following features into your Gist:
- at least two headings of different sizes
- at least one numbered list
- at least one bullet point list
- at least one bold word/phrase
- at least one italic word/phrase
- at least one code block (in Javascript for Frontend or in Ruby for Backend)
- at least one inline code block (greyed text)
- at least one image
- ⚡️ TURN THIS SENTENCE INTO A LINK TO YOUR GIST ⚡️
Using the rubric below, assess how you did with these exercises. These are the same metrics your instructors will use to determine if you are prepared for Mod 1!
- I read carefully read ALL directions
- I completed all parts of the exercises (not including Extensions) to the best of my ability
- I used correct syntax, spacing and naming conventions
- I followed ALL formatting instructions
- I pushed myself out of my comfort zone and experimented/broke things to try to learn
- I spent no longer than 20-30 mins Googling a specific problem before asking for help
- I went back to the lesson to search for clarification before asking for help
If you have any questions, comments, or confusions that you would like an instructor to address, list them below:
- Sorry about my Git practice being super messy! lots of trial an error, but I believe I understand things better now using Git!
Are you stuck on something? Here is the BEST way to ask for help:
- Start or reply in the thread with the problem you are facing. Be sure to follow the guidelines for asking questions below:
- I can explain what I am trying to do or accomplish
- I can what I have tried so far and/or what resources I've tried online
- I can describe specifically what I am stuck on
- I provided screenshots and/or code examples to give context
- If I provided short code examples, I used
inline code formattingfor single lines of code/error messages - If I provided larger blocks of code, I used a code snippet in the correct format (such as
.jsor.rb)
- If I provided short code examples, I used
- Usually, your classmates will be able to answer your question or point you in the right direction very quickly! If not, an instructor will reply within 24-48 hours
@samivari
Take a look at
2. markdown practice- I am not seeing a link to your practice gist there!Please message me here when you are able to get that in. Thanks!