Git Tasks: Quick Reference

See Also

The following table describes common Git tasks.

To perform this task: Follow these steps:
Place a Project under Git Version Control
  1. Select the NetBeans project you wish to put under Git version control.
  2. Either choose Team > Git > Initialize from the main menu, or
  3. Choose Versioning > Initialize Git Repository from the right-click menu of a node in the Projects, Files or Favorites window.

The project is placed under Git control. You will then need to Commit the Project files.

Clone an External Repository
  1. Choose Team > Git > Clone from the main menu.
  2. In the Git Clone Repository wizard, specify the location of the Git repository, and click Next.
  3. In the Parent Directory, specify the location on your computer where you want the Clone to reside.
  4. In the Clone Name, specify the name of the Clone.
  5. Click Finish to Clone the remote repository.
Add Files to a Repository
  1. Select the file or directory that you want to add.
  2. Choose Team > Git > Add from the main menu.
Compare file revisions
  1. Select the file that you want to perform a diff on.
  2. Choose Team > Git > Diff from the main menu.
View versioning information
  1. Select the file or folder that you want to view the list of the changes made to.
  2. Choose Team > Git > Show Changes from the main menu.
Commit changes
  1. Select the file or directory that you want to commit.
  2. Choose Git > Commit from right-click menu.
Push to default
  1. Select the Cloned Git Project you want to Push changes to.
  2. Choose Git > Remote > Push from right-click menu.
    This will Push changes to the Clone's parent Repository.
Pull from default
  1. Select the Cloned Git Project you want to Pull changes into.
  2. Choose Git > Remote > Pull from the right-click menu.
    This will Pull changes from the Clone's parent Repository.
See Also
About Git

Legal Notices