Skip to content
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

Improved Git and GitHub documentation #79

Merged
merged 8 commits into from
Sep 10, 2021
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .github/workflows/config/.wordList.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,51 @@ allwpilib
AppData
CMD
Codecademy
Codespaces
config
Crtl
CTRE
Ctrl
declutter
drivetrain
Drivetrain
dropdown
else’s
exe
faq
frc
FRC
FRCteam
gifs
github
gitignore
gmail
html
https
JDK
JDK's
JDKs
Kanban
linter
markdownlint
md
MXP
NavX
octocat
OmniMount
OpenJDK
OpenMesh
orgs
PCM
PDP
py
README
README's
repo
reverified
roboRIO
RSL
Runtime
sexualized
socio
SparkMax
Expand All @@ -45,9 +57,18 @@ steelboot
Steelboot
TalonSRX
txt
UI
USERPROFILE
VCS
VictorSPX
visualstudio
VM
VRM
vscjava
vscode
VSCode
VSCode's
vsliveshare
weebly
wordList
WPILBJ
Expand Down
24 changes: 13 additions & 11 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,32 +1,34 @@
{
"cSpell.words": [
"CTRE",
"Codecademy",
"Crtl",
"Cteam",
"Kanban",
"Libj",
"OCTOCAT",
"Omni",
"WPILIB",
"WRRF",
"allwpilib",
"avto",
"avtodev",
"blockquote",
"calibreapp",
"Codecademy",
"codespaces",
"Crtl",
"Cteam",
"CTRE",
"declutter",
"gmail",
"Kanban",
"Libj",
"markdownlint",
"OCTOCAT",
"Omni",
"orgs",
"pyspelling",
"robo",
"rojopolis",
"socio",
"steelboot",
"vscjava",
"weebly",
"wordlists",
"wpilibsuite"
"WPILIB",
"wpilibsuite",
"WRRF"
],
"markdownlint.config": {
"MD013": false,
Expand Down
115 changes: 115 additions & 0 deletions Documents/TheBasicsOfGitHub.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
# :wave: The Basics of GitHub

## 🤓 Course overview and learning outcomes

The goal of this course is to give you a brief introduction to GitHub. We’ll also provide you with materials for further learning and a few ideas to get you started on our platform. 🚀

## :octocat: Git and GitHub

Git is a **distributed Version Control System (VCS)**, which means it is a useful tool for easily tracking changes to your code, collaborating, and sharing. With Git you can track the changes you make to your project so you always have a record of what you’ve worked on and can easily revert back to an older version if need be. It also makes working with others easier—groups of people can work together on the same project and merge their changes into one final source!

GitHub is a way to use the same power of Git all online with an easy-to-use interface. It’s used across the software world and beyond to collaborate and maintain the history of projects.

GitHub is home to some of the most advanced technologies in the world. Whether you're visualizing data or building a new game, there's a whole community and set of tools on GitHub that can get you to the next step. This course starts with the basics of GitHub, but we'll dig into the rest later.

## :octocat: Understanding the GitHub flow

The GitHub flow is a lightweight workflow that allows you to experiment and collaborate on your projects easily, without the risk of losing your previous work.

### Repositories

A repository is where your project work happens--think of it as your project folder. It contains all of your project’s files and revision history. You can work within a repository alone or invite others to collaborate with you on those files.

### Cloning

When a repository is created with GitHub, it’s stored remotely in the ☁️. You can clone a repository to create a local copy on your computer and then use Git to sync the two. This makes it easier to fix issues, add or remove files, and push larger commits. You can also use the editing tool of your choice as opposed to the GitHub UI. Cloning a repository also pulls down all the repository data that GitHub has at that point in time, including all versions of every file and folder for the project! This can be helpful if you experiment with your project and then realize you liked a previous version more.
To learn more about cloning, read ["Cloning a Repository"](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/cloning-a-repository).

### Committing and pushing

**Committing** and **pushing** are how you can add the changes you made on your local machine to the remote repository in GitHub. That way your instructor and/or teammates can see your latest work when you’re ready to share it. You can make a commit when you have made changes to your project that you want to “checkpoint.” You can also add a helpful **commit message** to remind yourself or your teammates what work you did (e.g. “Added a README with information about our project”).

Once you have a commit or multiple commits that you’re ready to add to your repository, you can use the push command to add those changes to your remote repository. Committing and pushing may feel new at first, but we promise you’ll get used to it 🙂

## 💻 GitHub terms to know

### Repositories

We mentioned repositories already, they are where your project work happens, but let’s talk a bit more about the details of them! As you work more on GitHub you will have many repositories which may feel confusing at first. Fortunately, your ["GitHub dashboard"](https://docs.github.com/en/github/setting-up-and-managing-your-github-user-account/about-your-personal-dashboard) helps to easily navigate to your repositories and see useful information about them. Make sure you’re logged in to see it!

Repositories also contain **README**s. You can add a README file to your repository to tell other people why your project is useful, what they can do with your project, and how they can use it. We are using this README to communicate how to learn Git and GitHub with you. 😄
To learn more about repositories read ["Creating, Cloning, and Archiving Repositories](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/about-repositories) and ["About README's"](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/about-readmes).

### Branches

You can use branches on GitHub to isolate work that you do not want merged into your final project just yet. Branches allow you to develop features, fix bugs, or safely experiment with new ideas in a contained area of your repository. Typically, you might create a new branch from the default branch of your repository—main. This makes a new working copy of your repository for you to experiment with. Once your new changes have been reviewed by a teammate, or you are satisfied with them, you can merge your changes into the default branch of your repository.
To learn more about branching, read ["About Branches"](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/about-branches).

### Forks

A fork is another way to copy a repository, but is usually used when you want to contribute to someone else’s project. Forking a repository allows you to freely experiment with changes without affecting the original project and is very popular when contributing to open source software projects!
To learn more about forking, read ["Fork a repo"](https://docs.github.com/en/github/getting-started-with-github/fork-a-repo)

### Pull requests

When working with branches, you can use a pull request to tell others about the changes you want to make and ask for their feedback. Once a pull request is opened, you can discuss and review the potential changes with collaborators and add more changes if need be. You can add specific people as reviewers of your pull request which shows you want their feedback on your changes! Once a pull request is ready-to-go, it can be merged into your main branch.
To learn more about pull requests, read ["About Pull Requests"](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/about-pull-requests).

### Issues

Issues are a way to track enhancements, tasks, or bugs for your work on GitHub. Issues are a great way to keep track of all the tasks you want to work on for your project and let others know what you plan to work on. You can also use issues to tell a favorite open source project about a bug you found or a feature you think would be great to add!

For larger projects, you can keep track of many issues on a project board. GitHub Projects help you organize and prioritize your work and you can read more about them [in this "About Project boards document](https://docs.github.com/en/github/managing-your-work-on-github/about-project-boards). You likely won’t need a project board for your assignments, but once you move on to even bigger projects, they’re a great way to organize your team’s work!
You can also link together pull requests and issues to show that a fix is in progress and to automatically close the issue when someone merges the pull request.
To learn more about issues and linking them to your pull requests, read ["About Issues"](https://docs.github.com/en/github/managing-your-work-on-github/about-issues).

### Your user profile

Your profile page tells people the story of your work through the repositories you're interested in, the contributions you've made, and the conversations you've had. You can also give the world a unique view into who you are with your profile README. You can use your profile to let future employers know all about you!
To learn more about your user profile and adding and updating your profile README, read ["Managing Your Profile README"](https://docs.github.com/en/github/setting-up-and-managing-your-github-profile/managing-your-profile-readme).

### Using markdown on GitHub

You might have noticed already, but you can add some fun styling to your issues, pull requests, and files. ["Markdown"](https://guides.github.com/features/mastering-markdown/) is an easy way to style your issues, pull requests, and files with some simple syntax. This can be helpful to organize your information and make it easier for others to read. You can also drop in gifs and images to help convey your point!
To learn more about using GitHub’s flavor of markdown, read ["Basic Writing and Formatting Syntax"](https://docs.github.com/en/github/writing-on-github/basic-writing-and-formatting-syntax).

### Engaging with the GitHub community

The GitHub community is vast. There are many types of people who use GitHub in their day to day—students like you, professional developers, hobbyists working on open source projects, and explorers who are just jumping into the world of software development on their own. There are many ways you can interact with the larger GitHub community, but here are three places where you can start.

#### Starring repositories

If you find a repository interesting or you want to keep track of it, star it! When you star a repository it’s also used as a signal to surface better recommendations on github.com/explore. If you’d like to get back to your starred repositories you can do so via your user profile.
To learn more about starring repositories, read ["Saving Repositories with Stars"](https://docs.github.com/en/github/getting-started-with-github/saving-repositories-with-stars).

#### Following users

You can follow people on GitHub to receive notifications about their activity and discover projects in their communities. When you follow a user, their public GitHub activity will show up on your dashboard so you can see all the cool things they are working on.
To learn more about following users, read ["Following People"](https://docs.github.com/en/github/getting-started-with-github/following-people).

#### Browsing GitHub Explore

GitHub Explore is a great place to do just that … explore :smile: You can find new projects, events, and developers to interact with.

You can check out the GitHub Explore website [at github.com/explore](https://github.com/explore). The more you interact with GitHub the more tailored your Explore view will be.

## 📝 Optional next steps

* Open a pull request and let your teacher know that you’ve finished this course.
* Create a new markdown file in this repository. Let them know what you learned and what you are still confused about! Experiment with different styles!
* Create your profile README. Let the world know a little bit more about you! What are you interested in learning? What are you working on? What's your favorite hobby? Learn more about creating your profile README in the document, ["Managing Your Profile README"](https://docs.github.com/en/github/setting-up-and-managing-your-github-profile/managing-your-profile-readme).
* Go to your user dashboard and create a new repository. Experiment with the features within that repository to familiarize yourself with them.
* [Let us know what you liked or didn’t like about the content of this course](https://support.github.com/contact/education). What would you like to see more of? What would be interesting or helpful to your learning journey?

## 📚 Resources

* [A short video explaining what GitHub is](https://www.youtube.com/watch?v=w3jLJU7DT5E&feature=youtu.be)
* [Git and GitHub learning resources](https://docs.github.com/en/github/getting-started-with-github/git-and-github-learning-resources)
* [Understanding the GitHub flow](https://guides.github.com/introduction/flow/)
* [How to use GitHub branches](https://www.youtube.com/watch?v=H5GJfcp3p4Q&feature=youtu.be)
* [Interactive Git training materials](https://githubtraining.github.io/training-manual/#/01_getting_ready_for_class)
* [GitHub's Learning Lab](https://lab.github.com/)
* [Education community forum](https://education.github.community/)
* [GitHub community forum](https://gh.neting.ccmunity/)

> From GitHub Classroom
3 changes: 3 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ include:
- advanced/characterization.md
- CODE_OF_CONDUCT.md
- CONTRIBUTING.md
- detailedSetup/genericVSCodeSetup.md
- Documents/TheBasicsOfGitHub.md
- gitHubAdmin/orgManagement/orgDiscount.md
- gitHubAdmin/orgManagement/orgOwners.md
- gitHubAdmin/orgManagement/teamCleanup.md
Expand All @@ -22,6 +24,7 @@ include:
- index.md
- quickStart/codingWorkflow.md
- quickStart/gitHubDesktopTut.md
- quickStart/introToGit.md
- quickStart/programingQuickStart.md
- quickStart/setupGitHub.md
- quickStart/setupGitHubDesktop.md
Expand Down
74 changes: 74 additions & 0 deletions detailedSetup/genericVSCodeSetup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# JDK and Visual Studio Code Setup

This tutorial will walk you through the installation of the Java Development, Kit (JDK) and Visual Studio Code (VSCode) on your machine.

> The generic version of VSCode is only used for learning basic Java. It is recommended that you use FRC VSCode for FRC development.

> You must be able to install programs on your computer to complete this tutorial. It is not possible to install the JDK in the school's VM at this time or on the school's Chromebooks. VSCode is compatible with the school's VM, but using GitHub codespaces will be easier to setup.

## Installing VSCode

1. Navigate to [code.visualstudio.com](https://code.visualstudio.com/).

1. Click the Download button. For instance, if you are on Windows, it should say "Download for Windows ... Stable Build".
> This will download the recommended installer, but it is possible to get more details if you click "Other platforms".

1. Run the installer.
> (Windows only) On the "Select Additionally Task Page, I would recommend selecting the two 'Add "Open with Code" action to Windows Explorer...'.

## Installing the JDK

> You must have administrator access to perform this step.

1. Open VSCode

2. Press [Crtl] + [Shift] + [P] on Windows to open the command pallet, or [Command] + [Shift] + [P] on Mac.

3. Begin typing "configure Java Runtime". When "Java: configure Java Runtime" pops up, select it.

4. Scroll down to "Install A JDK", use the default settings, and click "Download"

5. Run the installer and follow the prompts to install the OpenJDK on your machine.
> (Windows) IMPORTANT: If it asks you if you want to add Java to your system _path_ or asks about _environment variables_ (_JDK\_HOME_ and _JAVA\_HOME_, select yes or check the check box. You may want to check under for any advanced configuration options.

6. Restart VSCode.

7. Open the "Java: configure Java Runtime" page again.

8. Select the "Installed JDKs tab"

9. If there is a JDK listed in the "Detected JDKs", sections, you are good to go. If the JDK is not detected, but you know you installed it, you have the following options:
> Feel free to consult with someone who with more experience to figure out the easiest method to get it working, as some of these could break your computer.

> You must restart VSCode for the changes to take affect.
- Adjusting VSCode's Java settings to point to the JDK's location.
- Updating your system path to include the path to the JDK.
> This is for Windows only.
- Setting the JDK\_HOME and/or JAVA\_HOME environment variables with the JDK's directory.
> This is for Windows only.

## Installing VSCode Extensions

> Although some repositories will include configuration files that will prompt you to install these, go ahead and install them nwo.

> Related reading: [Official VSCode Docs - Extension Marketplace](https://code.visualstudio.com/docs/editor/extension-marketplace). This may help if you are having trouble in this section.

1. Open VSCode

2. Extensions can be installed in on of the following way:
- Navigate to the Extension Marketplace pane by pressing the keys [Ctrl] + [Shift] + [X] on Windows or [Command] + [Shift] + [X] on Mac at the same time.
- The Extension Marketplace pane can also be opened by clicking the Extension Marketplace icon.
You can also use the links provided in the next step and clicking install. This will prompt you to open VSCode.

3. Search for and install the following extensions:
- "Extension Pack for Java" by Microsoft. ID: [vscjava.vscode-java-pack](https://marketplace.visualstudio.com/items?itemName=vscjava.vscode-java-pack)

- "Live Share Extension Pack" by Microsoft. ID: [ms-vsliveshare.vsliveshare-pack](https://marketplace.visualstudio.com/items?itemName=ms-vsliveshare.vsliveshare-pack)

4. Restart VSCode.

<br>
[Index](https://frc6506.github.io/docs/index)

<br>
_Updated 20210909T1845 PDT_
6 changes: 4 additions & 2 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,15 @@ This section includes information about GitHub

- [Signing up for GitHub](quickStart/setupGitHub)
- [GitHub Desktop setup](quickStart/setupGitHubDesktop)
- [JDK and VSCode setup - For basic Javas](detailedSetup/genericVSCodeSetup)
- [GitHub Desktop Guide](quickStart/gitHubDesktopTut)

- [Workflow Explanation](quickStart/codingWorkflow)

- [GitHub Presentation (Covers most stuff here)](https://docs.google.com/presentation/d/e/2PACX-1vRZlrW9X5Tn2a9EdpZ2iVTtD4TPZJUqQlTI4D0ThXZwhgwMI8DkeJMmreyRZ4Eh2ZlNa5eA1I8kLV7d/pub?start=false&loop=false&delayms=3000)

[Official GitHub Classroom Introduction to git](Documents/TheBasicsOfGitHub)

## Introduction to FRC Coding in Java

Additional tutorials Coming Soon!
Expand Down Expand Up @@ -125,5 +128,4 @@ Assorted WPLib-j resources.

<br>

_Updated 20210804T1875 PDT_

_Updated 20210909T1745 PDT_
Loading