-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: 📝 add exercises #24
base: main
Are you sure you want to change the base?
Conversation
::: callout-tip | ||
## See the history of changes | ||
|
||
If you want to see the history of changes to the file, go to the file | ||
and click the "History" button on the right side of the screen. This | ||
will show you all the changes that have been made to the file along with | ||
the commit messages. | ||
|
||
Since you have made two commits to the file, you should see two entries | ||
in the history. You can click on each entry to see the changes that were | ||
made in that commit. | ||
|
||
This also shows the importance of meaningful commit messages. Imagine if | ||
all the commit messages were "Update file.md". Then, it would be hard to | ||
know what changes were made in each commit. By contrast, if the commits | ||
have meaningful messages, it would be much more easy to get an overview | ||
of the changes that have been made. | ||
::: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought this was a nice addition - so they try actually looking at the history they made - but I think this exercise became quite/too long?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of a tip, make it an exercise! 😁
And more exercises are fine, it's easy to remove than it is to grow, and we can always put them to the side/use as extras.
|
||
{{< text_snippet sticky_up >}} | ||
|
||
## Exercise: Close your issue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made this a separate exercise so the fastest wouldn't start closing their issues before the rest had time to comment/interact.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could join the closing issue and delete file into one exercise called "cleaning up" or something.
First, we want to add a file to the repository. | ||
|
||
1. Go to the repository on GitHub. | ||
2. In the code tab, click "Add file" and then "Create new file". | ||
3. In the "Name your file..." field, type a name for your file. For | ||
simplicity, let's call it your name and make it a Markdown file. For | ||
example, "your-name.md". | ||
4. Click the green "Commit changes" button and fill in the commit | ||
message. For example, "Add file with my name". You don't need to | ||
fill in the extended description. Keep the "Commit directly to the | ||
`main` branch" option selected. | ||
5. When you have filled in the commit message, click the green "Commit | ||
changes" button. | ||
6. Go back to the repository and check that your file has been added. | ||
|
||
You have now made your first commit to the repository! :tada: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this could be a part of the code along instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, these steps could be, but the basic steps can stay the same. See comment above about "problem to solve"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice start! Some comments
## Exercise: Add a new file and modify the content | ||
|
||
First, we want to add a file to the repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Follow the format of the vscode snippet exercise
to match the other websites
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It helps that exercises have some problem to solve rather than "do this", "but why", "because". Maybe it could be like the exercises you thought of for git4cats, where we get them to find a recipe they like and put it on the repo as a new file.
::: callout-tip | ||
## See the history of changes | ||
|
||
If you want to see the history of changes to the file, go to the file | ||
and click the "History" button on the right side of the screen. This | ||
will show you all the changes that have been made to the file along with | ||
the commit messages. | ||
|
||
Since you have made two commits to the file, you should see two entries | ||
in the history. You can click on each entry to see the changes that were | ||
made in that commit. | ||
|
||
This also shows the importance of meaningful commit messages. Imagine if | ||
all the commit messages were "Update file.md". Then, it would be hard to | ||
know what changes were made in each commit. By contrast, if the commits | ||
have meaningful messages, it would be much more easy to get an overview | ||
of the changes that have been made. | ||
::: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of a tip, make it an exercise! 😁
And more exercises are fine, it's easy to remove than it is to grow, and we can always put them to the side/use as extras.
|
||
{{< text_snippet sticky_up >}} | ||
|
||
## Exercise: Close your issue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could join the closing issue and delete file into one exercise called "cleaning up" or something.
First, we want to add a file to the repository. | ||
|
||
1. Go to the repository on GitHub. | ||
2. In the code tab, click "Add file" and then "Create new file". | ||
3. In the "Name your file..." field, type a name for your file. For | ||
simplicity, let's call it your name and make it a Markdown file. For | ||
example, "your-name.md". | ||
4. Click the green "Commit changes" button and fill in the commit | ||
message. For example, "Add file with my name". You don't need to | ||
fill in the extended description. Keep the "Commit directly to the | ||
`main` branch" option selected. | ||
5. When you have filled in the commit message, click the green "Commit | ||
changes" button. | ||
6. Go back to the repository and check that your file has been added. | ||
|
||
You have now made your first commit to the repository! :tada: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, these steps could be, but the basic steps can stay the same. See comment above about "problem to solve"
Now that we have created a file, let's modify it: | ||
|
||
1. Go to the file on GitHub | ||
2. Click the pencil icon on the right side of the screen ("Edit this | ||
file") to edit the file | ||
3. Make a change to the file by adding a new line of text. For example, | ||
"This is a new line of text." | ||
4. Now, commit the changes as you did before by clicking the green | ||
"Commit changes" button and filling in the commit message. When you | ||
have filled in the commit message, click the green "Commit changes" | ||
button. | ||
5. Go back to the file on GitHub and check that your changes have been | ||
made. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Based on my experience and the feedback I've gotten, multiple part exercises don't work too well. Keep them smaller and shorter for intro sessions. Or rather, keep the exercise more targeted in scope. This exercise is doing several things.
Lastly, let's delete the file: | ||
|
||
1. Go to the file. | ||
2. On the same line as the file name, click the button with the three | ||
dots, saying "More file actions". Click it, scroll down and click | ||
"Delete file". | ||
3. Commit the changes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment below, this could be moved down.
Now it's time to make edits to the file itself. We want to rename the | ||
file and move it to a new location in the repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment above about "problem to solve"
## Exercise: Create an issue and interact with another's issue | ||
|
||
Let's create your first issue! | ||
|
||
1. In the repository on GitHub, click the "Issues" tab. | ||
2. Click the green "New issue" button. | ||
3. Fill in the title and the description. This could be anything you | ||
want to work on or discuss. For example, it could be about something | ||
you think should be added (a new file or a new section to a file) or | ||
something you think should be changed. It could also be a discussion | ||
issue where you ask for feedback on something. | ||
4. Click the green "Create" button, to create the issue. | ||
|
||
Now, you have created your first issue! :partying_face: | ||
|
||
Now, let's interact with another's issue: | ||
|
||
1. Go back to the "Issues" tab in the repository. | ||
2. Click on an issue that someone else has created. | ||
3. Read the issue and the comments that have been made. | ||
4. Scroll down to the bottom of the page and write a comment in the | ||
comment field. You can ask a question, give feedback, or suggest a | ||
solution to the issue. | ||
5. When you have written your comment, click the green "Comment" button | ||
to post the comment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could be a code-along, with the "cleaning up" exercise being the end.
Description
This PR adds exercises. Somehow, it ended up with four exercises, which might be too much. What do you think?
Closes #10
This PR needs an in-depth review.
Checklist
just run-all