SlideShare une entreprise Scribd logo
1  sur  125
Télécharger pour lire hors ligne
Java for Hydrologists
Some useful applications of EGit
R. Rigon, F. Serafin
R.Rigon-IltavolodilavorodiRemoWolf
March 20, 2014
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Objectives
Some useful applications of EGit1
• Introduction to EGit and installation into Eclipse;
• Load local existing project into remote GitHub repository;
• Clone remote project into local repository.
1
All the instructions are taken from Lars Vogel’s blog
http://www.vogella.com/tutorials/EclipseGit/article.html
and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide.
Riccardo Rigon, Francesco Serafin
March 20, 2014 2 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Objectives
Some useful applications of EGit1
• Introduction to EGit and installation into Eclipse;
• Load local existing project into remote GitHub repository;
• Clone remote project into local repository.
1
All the instructions are taken from Lars Vogel’s blog
http://www.vogella.com/tutorials/EclipseGit/article.html
and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide.
Riccardo Rigon, Francesco Serafin
March 20, 2014 2 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Objectives
Some useful applications of EGit1
• Introduction to EGit and installation into Eclipse;
• Load local existing project into remote GitHub repository;
• Clone remote project into local repository.
1
All the instructions are taken from Lars Vogel’s blog
http://www.vogella.com/tutorials/EclipseGit/article.html
and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide.
Riccardo Rigon, Francesco Serafin
March 20, 2014 2 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Objectives
Some useful applications of EGit1
• Introduction to EGit and installation into Eclipse;
• Load local existing project into remote GitHub repository;
• Clone remote project into local repository.
1
All the instructions are taken from Lars Vogel’s blog
http://www.vogella.com/tutorials/EclipseGit/article.html
and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide.
Riccardo Rigon, Francesco Serafin
March 20, 2014 2 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Objectives
Some useful applications of EGit1
• Introduction to EGit and installation into Eclipse;
• Load local existing project into remote GitHub repository;
• Clone remote project into local repository.
For the complete guide visit
http://www.vogella.com/tutorials/EclipseGit/article.html
https://wiki.eclipse.org/EGit/User_Guide
1
All the instructions are taken from Lars Vogel’s blog
http://www.vogella.com/tutorials/EclipseGit/article.html
and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide.
Riccardo Rigon, Francesco Serafin
March 20, 2014 2 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Git and GitHub
What is Git?
In software development, Git is a distributed revision control and source code
management system2
.
2
Git was initially designed and developed by Linus Torvalds for Linux kernel development
Riccardo Rigon, Francesco Serafin
March 20, 2014 3 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Git and GitHub
What is Git?
In software development, Git is a distributed revision control and source code
management system2
.
Distributed revision control
In computer programming, a distributed revision control system (DRCS) or
distributed version control system (DVCS) keeps track of software revisions and
allows many developers to work on a given project without requiring that they
maintain a connection to a common network.
2
Git was initially designed and developed by Linus Torvalds for Linux kernel development
Riccardo Rigon, Francesco Serafin
March 20, 2014 3 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Git and GitHub
What is Git?
In software development, Git is a distributed revision control and source code
management system2
.
Distributed revision control
In computer programming, a distributed revision control system (DRCS) or
distributed version control system (DVCS) keeps track of software revisions and
allows many developers to work on a given project without requiring that they
maintain a connection to a common network.
Every Git working directory is a full-fledged repository with complete history
and full version tracking capabilities, not dependent on network access or a
central server.
2
Git was initially designed and developed by Linus Torvalds for Linux kernel development
Riccardo Rigon, Francesco Serafin
March 20, 2014 3 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Git and GitHub
What is GitHub?
GitHub is a web-based hosting service for software development projects that
use the Git revision control system. GitHub offers both paid plans for private
repositories, and free accounts for open source projects.
Riccardo Rigon, Francesco Serafin
March 20, 2014 4 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Git and GitHub
What is GitHub?
GitHub is a web-based hosting service for software development projects that
use the Git revision control system. GitHub offers both paid plans for private
repositories, and free accounts for open source projects.
The site provides social networking
functionality such as feeds, followers,
wikis and the social network graph to
display how developers work on their
versions of a repository.
Riccardo Rigon, Francesco Serafin
March 20, 2014 4 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
What is EGit
What is EGit?
EGit is an Eclipse plug-in which allows you to use the distributed version
control system Git directly within the Eclipse IDE.
EGit is based on the JGit library.
Riccardo Rigon, Francesco Serafin
March 20, 2014 5 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
What is EGit
What is EGit?
EGit is an Eclipse plug-in which allows you to use the distributed version
control system Git directly within the Eclipse IDE.
EGit is based on the JGit library.
JGit
JGit is a library which implements the Git
functionality in Java
Riccardo Rigon, Francesco Serafin
March 20, 2014 5 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Installation of EGit
The EGit plug-in can be installed into every Eclipse IDE installation.
Riccardo Rigon, Francesco Serafin
March 20, 2014 6 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Installation of EGit
The EGit plug-in can be installed into every Eclipse IDE installation.
Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in
their default configuration
Riccardo Rigon, Francesco Serafin
March 20, 2014 6 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Installation of EGit
The EGit plug-in can be installed into every Eclipse IDE installation.
Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in
their default configuration
No additional installation is required
Riccardo Rigon, Francesco Serafin
March 20, 2014 6 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Installation of EGit
The EGit plug-in can be installed into every Eclipse IDE installation.
Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in
their default configuration
No additional installation is required
If the EGit plug-in is missing in your Eclipse installation, you can install it via
the Eclipse Marketplace. Start this manager via the Help→Eclipse
Marketplace menu entry.
Riccardo Rigon, Francesco Serafin
March 20, 2014 6 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Installation of EGit
The EGit plug-in can be installed into every Eclipse IDE installation.
Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in
their default configuration
No additional installation is required
If the EGit plug-in is missing in your Eclipse installation, you can install it via
the Eclipse Marketplace. Start this manager via the Help→Eclipse
Marketplace menu entry.
Riccardo Rigon, Francesco Serafin
March 20, 2014 6 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Eclipse Marketplace
The dialog to install EGit is depicted in the following screenshot.
Riccardo Rigon, Francesco Serafin
March 20, 2014 7 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Installation of Git into Eclipse
Eclipse Marketplace
The dialog to install EGit is depicted in the following screenshot.
Riccardo Rigon, Francesco Serafin
March 20, 2014 7 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Eclipse preferences
Before using EGit you should:
• create a folder where store the projects you want to load on GitHub (the
Git default repository folder);
• configure your name used in Git;
• configure your email address used in Git3
;
• configure your Git default repository folder.
The Eclipse Git functionality allows you to configure your default user and
email address for a commit. Select
Window→Preferences→Team→Git→Configuration to set them up.
3
Git configuration settings can be configured using the EGit configuration preference page
but this configuration is not store in the Eclipse preferences store but in git configuration files
in order to ensure that native git sees the same configuration.
Riccardo Rigon, Francesco Serafin
March 20, 2014 8 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up name and email used in Git
You can add entries to your Git configuration by pressing the Add Entry button
on the Git Configuration preference page.
Riccardo Rigon, Francesco Serafin
March 20, 2014 9 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up name and email used in Git
You can add entries to your Git configuration by pressing the Add Entry button
on the Git Configuration preference page.
Riccardo Rigon, Francesco Serafin
March 20, 2014 9 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up name used in Git
To add your user, use the user.name as key and your real name as value.
Riccardo Rigon, Francesco Serafin
March 20, 2014 10 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up mail used in Git
Repeat the procedure for your email address, using user.email as key as shown
below.
Riccardo Rigon, Francesco Serafin
March 20, 2014 11 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up Git default repository folder
You can also enter the default folder for storing Git repositories via the
Window→Preferences→Team→Git and writing the correct path in Default
Repository Folder entry.
Riccardo Rigon, Francesco Serafin
March 20, 2014 12 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Setting up Git in Eclipse
Set up Git default repository folder
You can also enter the default folder for storing Git repositories via the
Window→Preferences→Team→Git and writing the correct path in Default
Repository Folder entry.
Riccardo Rigon, Francesco Serafin
March 20, 2014 12 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
New Java Project
Create a new Java project (we will work with a simple Hello World code).
• Right click in the white space of
the Package Explorer, after click
on New→Java Project;
• In the Dialog that appeared,
remove the tick in Use default
location;
• Click on Browse, in the Dialog
that appeared enter in your Git
default repository folder and create
a new folder named
JavaForHydrologists.example.
Enter in the new folder and click
OK.
• Thus Eclipse automatically sets
the Folder Name like Project
Name. Then click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 13 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
You must:
• Create a new package;
• Create a new class;
• Write the code.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
You must:
• Create a new package;
• Create a new class;
• Write the code.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
You must:
• Create a new package;
• Create a new class;
• Write the code.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
You must:
• Create a new package;
• Create a new class;
• Write the code.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create the Project
Hello World!
Now write a simple Hello World code in the newly created project.
You must:
• Create a new package;
• Create a new class;
• Write the code.
Once you have wrote the code, we are going to create a local Git Repository.
Riccardo Rigon, Francesco Serafin
March 20, 2014 14 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Git Repositories view
First we need to view the Git Repositories present in our Git default repository.
• Click on
Window→Show View→Other;
• In the Show view Dialog, expand
Git and click on Git Repositories.
Then click OK;
• Now you can see the Git
Repositories tab in your Eclipse
IDE.
Riccardo Rigon, Francesco Serafin
March 20, 2014 15 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Git Repositories view
First we need to view the Git Repositories present in our Git default repository.
• Click on
Window→Show View→Other;
• In the Show view Dialog, expand
Git and click on Git Repositories.
Then click OK;
• Now you can see the Git
Repositories tab in your Eclipse
IDE.
Riccardo Rigon, Francesco Serafin
March 20, 2014 15 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Git Repositories view
First we need to view the Git Repositories present in our Git default repository.
• Click on
Window→Show View→Other;
• In the Show view Dialog, expand
Git and click on Git Repositories.
Then click OK;
• Now you can see the Git
Repositories tab in your Eclipse
IDE.
Riccardo Rigon, Francesco Serafin
March 20, 2014 15 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Git Repositories view
First we need to view the Git Repositories present in our Git default repository.
• Click on
Window→Show View→Other;
• In the Show view Dialog, expand
Git and click on Git Repositories.
Then click OK;
• Now you can see the Git
Repositories tab in your Eclipse
IDE.
Riccardo Rigon, Francesco Serafin
March 20, 2014 15 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Share the Java Project
To create a new Git local Repository, we have to share the existing project.
• Right click on the
JavaForydrologists.example project
and then click to Team→Share
Project;
• Select the repository type Git and
click Next;
• To configure the Git repository
select Use or create repository in
parent folder of project;
• In the next Dialog select the
project and click to Create
Repository, after click Finish;
Riccardo Rigon, Francesco Serafin
March 20, 2014 16 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Share the Java Project
To create a new Git local Repository, we have to share the existing project.
• Right click on the
JavaForydrologists.example project
and then click to Team→Share
Project;
• Select the repository type Git and
click Next;
• To configure the Git repository
select Use or create repository in
parent folder of project;
• In the next Dialog select the
project and click to Create
Repository, after click Finish;
Riccardo Rigon, Francesco Serafin
March 20, 2014 16 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Share the Java Project
To create a new Git local Repository, we have to share the existing project.
• Right click on the
JavaForydrologists.example project
and then click to Team→Share
Project;
• Select the repository type Git and
click Next;
• To configure the Git repository
select Use or create repository in
parent folder of project;
• In the next Dialog select the
project and click to Create
Repository, after click Finish;
Riccardo Rigon, Francesco Serafin
March 20, 2014 16 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Share the Java Project
To create a new Git local Repository, we have to share the existing project.
• Right click on the
JavaForydrologists.example project
and then click to Team→Share
Project;
• Select the repository type Git and
click Next;
• To configure the Git repository
select Use or create repository in
parent folder of project;
• In the next Dialog select the
project and click to Create
Repository, after click Finish;
Riccardo Rigon, Francesco Serafin
March 20, 2014 16 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
Share the Java Project
To create a new Git local Repository, we have to share the existing project.
• Right click on the
JavaForydrologists.example project
and then click to Team→Share
Project;
• Select the repository type Git and
click Next;
• To configure the Git repository
select Use or create repository in
parent folder of project;
• In the next Dialog select the
project and click to Create
Repository, after click Finish;
Riccardo Rigon, Francesco Serafin
March 20, 2014 16 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create local Git Repository
But the decorator text “[NO-HEAD]” behind the project shows that this project
is not tracked in a repository and the question mark decorators show that the
.classpath, .project, the .settings files and the src content are not yet under version
control.
Riccardo Rigon, Francesco Serafin
March 20, 2014 17 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Create a remote repository on GitHub
Go to www.github.com and log in with your credentials. In your home click
like below.
Riccardo Rigon, Francesco Serafin
March 20, 2014 18 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Create a remote repository on GitHub
Go to www.github.com and log in with your credentials. In your home click
like below.
Riccardo Rigon, Francesco Serafin
March 20, 2014 18 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Create a remote repository on GitHub
Go to www.github.com and log in with your credentials. In your home click
like below.
Riccardo Rigon, Francesco Serafin
March 20, 2014 18 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Repository name: JavaFor Hydrologists.example
Riccardo Rigon, Francesco Serafin
March 20, 2014 19 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Repository name: JavaFor Hydrologists.example
Riccardo Rigon, Francesco Serafin
March 20, 2014 19 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Description of the repository: First GitHub repository to use with EGit
Riccardo Rigon, Francesco Serafin
March 20, 2014 20 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Description of the repository: First GitHub repository to use with EGit
Riccardo Rigon, Francesco Serafin
March 20, 2014 20 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Click to Create repository
Riccardo Rigon, Francesco Serafin
March 20, 2014 21 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
Click to Create repository
Riccardo Rigon, Francesco Serafin
March 20, 2014 21 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
After creation of your new repository, GitHub displays the information about
what you have to do if you want to connetc to this repository via the command
line.
Riccardo Rigon, Francesco Serafin
March 20, 2014 22 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
After creation of your new repository, GitHub displays the information about
what you have to do if you want to connetc to this repository via the command
line.
Riccardo Rigon, Francesco Serafin
March 20, 2014 22 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Create a remote repository on GitHub
After creation of your new repository, GitHub displays the information about
what you have to do if you want to connetc to this repository via the command
line.
As we are going to use EGit you can ignore this information, but don’t close
the window because we need the SSH or HTTP link.
Riccardo Rigon, Francesco Serafin
March 20, 2014 22 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
Now we have the link indispensable to establish the connection between local
and remote repository. Thus, in Eclipse in the Git Repositories tab, expand the
JavaForHydrologists.example and right click on Remote and then Create
Remote.
Riccardo Rigon, Francesco Serafin
March 20, 2014 23 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
• In the open Dialog the Remote
name must be origin, then click
OK;
• To Configure Push, in the next
Dialog click on Change;
• From your Git Remote Repository,
copy the https link and paste it in
the URI space. Eclipse
automatically will fill the other
fileds
• After you must only write your
GitHub credentials and the click to
Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 24 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
• In the open Dialog the Remote
name must be origin, then click
OK;
• To Configure Push, in the next
Dialog click on Change;
• From your Git Remote Repository,
copy the https link and paste it in
the URI space. Eclipse
automatically will fill the other
fileds
• After you must only write your
GitHub credentials and the click to
Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 24 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
• In the open Dialog the Remote
name must be origin, then click
OK;
• To Configure Push, in the next
Dialog click on Change;
• From your Git Remote Repository,
copy the https link and paste it in
the URI space. Eclipse
automatically will fill the other
fileds
• After you must only write your
GitHub credentials and the click to
Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 24 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
• In the open Dialog the Remote
name must be origin, then click
OK;
• To Configure Push, in the next
Dialog click on Change;
• From your Git Remote Repository,
copy the https link and paste it in
the URI space. Eclipse
automatically will fill the other
fileds
• After you must only write your
GitHub credentials and the click to
Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 24 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Set Remote in local repository
Create Remote
• In the open Dialog the Remote
name must be origin, then click
OK;
• To Configure Push, in the next
Dialog click on Change;
• From your Git Remote Repository,
copy the https link and paste it in
the URI space. Eclipse
automatically will fill the other
fileds
• After you must only write your
GitHub credentials and the click to
Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 24 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Basic operations
So we can prepare our local repository to push it to remote repository. The
most important operations are described below. Right click on the project in
the Package Explorer at every step:
• Team→Add to index
to add the selected resource(s) to the
index of Git
• Team→Commit
to open the commit dialog for
committing to your Git repository
Then click Commit
• Team→Push branch
only for the first time, beacuse you must
create the first master branch
• In this Dialog there is nothing to
do, click Next
• Insert your credentials of GitHub
• In this Dialog click Finish
• After push, click OK
Riccardo Rigon, Francesco Serafin
March 20, 2014 25 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Summary of the main steps
Our local repository is been now copied on remote repository.
But once you have create the first master branch, to push your modify you
need follow this basic sequence:
• Team→Add to index
• Team→Commit
• Team→Push to upstream
Riccardo Rigon, Francesco Serafin
March 20, 2014 26 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Summary of the main steps
Our local repository is been now copied on remote repository.
But once you have create the first master branch, to push your modify you
need follow this basic sequence:
• Team→Add to index
• Team→Commit
• Team→Push to upstream
Riccardo Rigon, Francesco Serafin
March 20, 2014 26 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Summary of the main steps
Our local repository is been now copied on remote repository.
But once you have create the first master branch, to push your modify you
need follow this basic sequence:
• Team→Add to index
• Team→Commit
• Team→Push to upstream
Riccardo Rigon, Francesco Serafin
March 20, 2014 26 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Summary of the main steps
Our local repository is been now copied on remote repository.
But once you have create the first master branch, to push your modify you
need follow this basic sequence:
• Team→Add to index
• Team→Commit
• Team→Push to upstream
Riccardo Rigon, Francesco Serafin
March 20, 2014 26 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Problems with basic operations
• After clicking Commit;
• If you cannot Push to Upstream;
• You can fix this problem in the
way shown before.
Riccardo Rigon, Francesco Serafin
March 20, 2014 27 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Problems with basic operations
• After clicking Commit;
• If you cannot Push to Upstream;
• You can fix this problem in the
way shown before.
Riccardo Rigon, Francesco Serafin
March 20, 2014 27 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Problems with basic operations
• After clicking Commit;
• If you cannot Push to Upstream;
• You can fix this problem in the
way shown before.
Riccardo Rigon, Francesco Serafin
March 20, 2014 27 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Problems with basic operations
• After clicking Commit;
• If you cannot Push to Upstream;
• You can fix this problem in the
way shown before.
Riccardo Rigon, Francesco Serafin
March 20, 2014 27 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
Right click on the project that you want to push and Team→Remote→Push
Riccardo Rigon, Francesco Serafin
March 20, 2014 28 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
Select Custom URI and paste in the URI tab the ssh link to your repository.
The ssh form is:
git@github.com:
username/project.git
In my case
git@github.com:francescoS/
JavaForHydrologists.example.git
Select the ssh protocol and
Eclipse will fill all tabs
automatically. After click Next
Riccardo Rigon, Francesco Serafin
March 20, 2014 29 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
In the window Push to: origin click on drop-down menu of the Source ref and
select master [branch] or the branch you want
Riccardo Rigon, Francesco Serafin
March 20, 2014 30 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
Click to Add Spec on the right and Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 31 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
Click to Add Spec on the right and Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 31 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push. . . with more settings
Click to Add Spec on the right and Next.
In the other windows you can see a small summary of the push operation, then
click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 31 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Basic operations in EGit
Push...with more settings
After Push operations, the appeared Dialog shows the Push Results.
Riccardo Rigon, Francesco Serafin
March 20, 2014 32 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Introduction
If we are arrived here, I suppose you have your Git Repositories view in the
Eclipse IDE, otherwise return to 15.
Using the Git Clone Wizard you may clone remote repositories using different
transport protocols. The wizard can be started by clicking on the botton Clone
a Git Repository and add the clone to this view
Riccardo Rigon, Francesco Serafin
March 20, 2014 33 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Repository Selection
Copy the URL from GitHub page of the searched project (in this case
https://github.com/francescoS/JavaForHydrologists.firstClone) and
paste it in the URI space of the Clone Git Repository Dialog.
The other fields (Host and Repository path) are filled automatically by Eclipse.Riccardo Rigon, Francesco Serafin
March 20, 2014 34 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Repository Selection
Copy the URL from GitHub page of the searched project (in this case
https://github.com/francescoS/JavaForHydrologists.firstClone) and
paste it in the URI space of the Clone Git Repository Dialog.
The other fields (Host and Repository path) are filled automatically by Eclipse.Riccardo Rigon, Francesco Serafin
March 20, 2014 34 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Repository Selection
You must fill the fields User and Password with your credentials of GitHub.
Riccardo Rigon, Francesco Serafin
March 20, 2014 35 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Repository Selection
You must fill the fields User and Password with your credentials of GitHub.
Riccardo Rigon, Francesco Serafin
March 20, 2014 35 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Branch Selection
Click Next, in the Open Dialog choose wich branches shall be cloned from the
remote repository (in this case there is only one branch).
If you are not sure which branches you
need, simply hit Select All. You can
filter the branches by their name by
typing using the text control above the
list.
Riccardo Rigon, Francesco Serafin
March 20, 2014 36 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Local Destination
Click Next, in the Open Dialog select the Directory where store the repository
on the local file system and define some initial settings. .
Riccardo Rigon, Francesco Serafin
March 20, 2014 37 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Local Destination
Click Next, in the Open Dialog select the Directory where store the repository
on the local file system and define some initial settings. .
Riccardo Rigon, Francesco Serafin
March 20, 2014 37 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Clone project
Local Destination
Click Next, in the Open Dialog select the Directory where store the repository
on the local file system and define some initial settings. Click Finish.
Riccardo Rigon, Francesco Serafin
March 20, 2014 37 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Import the project in the Package Explorer
Now, to modify the project that you cloned before, you have to import it in your
Package Explorer. Thus, right click on the view Package Explorer and Import.
Riccardo Rigon, Francesco Serafin
March 20, 2014 38 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Import the project in the Package Explorer
Select Git→Project from Git
Riccardo Rigon, Francesco Serafin
March 20, 2014 39 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Import the project in the Package Explorer
Select Git→Project from Git
Riccardo Rigon, Francesco Serafin
March 20, 2014 39 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Import the project in the Package Explorer
Select Git→Project from Git and click Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 39 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Import the project in the Package Explorer
Select Existing local repository and click Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 40 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Select the repository JavaForHydrologists.firstClone and click Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 41 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
Select Import existing projects and click Next.
Riccardo Rigon, Francesco Serafin
March 20, 2014 42 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Import the project in the Package Explorer
This is the last Dialog, that summarizes the projects that you are importing.
Then click Finish.
Now the project is visible in the Package Explorer and you can modify it.
Riccardo Rigon, Francesco Serafin
March 20, 2014 43 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
But first to modify a cloned repository, it’s important to examine the history of
the entire project. So we are going to open a new tab in our Eclipse IDE:
History.
• Click to
Window→Show View→Other;
• Search and expand Team;
• Then select History and click OK.
Riccardo Rigon, Francesco Serafin
March 20, 2014 44 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
But first to modify a cloned repository, it’s important to examine the history of
the entire project. So we are going to open a new tab in our Eclipse IDE:
History.
• Click to
Window→Show View→Other;
• Search and expand Team;
• Then select History and click OK.
Riccardo Rigon, Francesco Serafin
March 20, 2014 44 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
But first to modify a cloned repository, it’s important to examine the history of
the entire project. So we are going to open a new tab in our Eclipse IDE:
History.
• Click to
Window→Show View→Other;
• Search and expand Team;
• Then select History and click OK.
Riccardo Rigon, Francesco Serafin
March 20, 2014 44 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
But first to modify a cloned repository, it’s important to examine the history of
the entire project. So we are going to open a new tab in our Eclipse IDE:
History.
• Click to
Window→Show View→Other;
• Search and expand Team;
• Then select History and click OK.
Riccardo Rigon, Francesco Serafin
March 20, 2014 44 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
Now the History tab is open and you can examine all the history of the project
on which you are going to work.
Riccardo Rigon, Francesco Serafin
March 20, 2014 45 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
How to view Git History
Git History
Now the History tab is open and you can examine all the history of the project
on which you are going to work.
Riccardo Rigon, Francesco Serafin
March 20, 2014 45 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Introduction
Modify the JavaForHydrologists.firstClone project
Now you can modify the simple code that we just cloned.
Some tips:
• you can use the TextIO class rather than simple System.out.println();
• you can read the string from console, so you can create two simple
methods:
• Read from console;
• Write in console.
• COMMENT ALL NEW LINES!
Riccardo Rigon, Francesco Serafin
March 20, 2014 46 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Introduction
A useful tip: JAutodoc
If you want to have a good standard to comment your code, you can use
JAutodoc. It is an Eclipse Plugin for automatically adding Javadoc and file
headers to your source code. It optionally generates initial comments from
element name by using Velocity templates for Javadoc and file headers.
Riccardo Rigon, Francesco Serafin
March 20, 2014 47 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Introduction
A useful tip: JAutodoc
If you want to have a good standard to comment your code, you can use
JAutodoc. It is an Eclipse Plugin for automatically adding Javadoc and file
headers to your source code. It optionally generates initial comments from
element name by using Velocity templates for Javadoc and file headers.
First install it:
Help→Eclipse Marketplace and search
JAutodoc.
Riccardo Rigon, Francesco Serafin
March 20, 2014 47 / 48
Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project
Introduction
How to use JAutodoc
To use JAutodoc, right click on the code and JAutodoc→Add javadoc.
Riccardo Rigon, Francesco Serafin
March 20, 2014 48 / 48

Contenu connexe

Tendances

Using Git in Eclipse - Eclipse Summit Europe 2010-11-03
Using Git in Eclipse - Eclipse Summit Europe 2010-11-03Using Git in Eclipse - Eclipse Summit Europe 2010-11-03
Using Git in Eclipse - Eclipse Summit Europe 2010-11-03msohn
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comB1 Systems GmbH
 
Introducing Git and git flow
Introducing Git and git flow Introducing Git and git flow
Introducing Git and git flow Sebin Benjamin
 
Beginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitBeginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitRobert Lee-Cann
 
Git and GitHub - The beginning
Git and GitHub - The beginning Git and GitHub - The beginning
Git and GitHub - The beginning Gemma Catolino
 
Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects InfrastructureGunnar Hillert
 
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...Assign, commit, and review - A developer’s guide to OpenStack contribution-20...
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...OpenCity Community
 
How Git and Gerrit make you more productive
How Git and Gerrit make you more productiveHow Git and Gerrit make you more productive
How Git and Gerrit make you more productiveKarsten Dambekalns
 
Hacking Git and GitHub
Hacking Git and GitHubHacking Git and GitHub
Hacking Git and GitHubEdureka!
 
OpenTuesday: Agile Testautomatisierung und Continuous Integration
OpenTuesday: Agile Testautomatisierung und Continuous IntegrationOpenTuesday: Agile Testautomatisierung und Continuous Integration
OpenTuesday: Agile Testautomatisierung und Continuous IntegrationDigicomp Academy AG
 
Assign, Commit, and Review
Assign, Commit, and ReviewAssign, Commit, and Review
Assign, Commit, and ReviewZhongyue Luo
 
Git and GitHub
Git and GitHubGit and GitHub
Git and GitHubRick Umali
 
Github Case Study By Amil Ali
Github Case Study By Amil AliGithub Case Study By Amil Ali
Github Case Study By Amil AliAmilAli1
 
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison Dowdney
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison DowdneySetting up Notifications, Alerts & Webhooks with Flux v2 by Alison Dowdney
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison DowdneyWeaveworks
 
Evolution of Version Control In Open Source
Evolution of Version Control In Open SourceEvolution of Version Control In Open Source
Evolution of Version Control In Open SourceChris Aniszczyk
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginLuca Milanesio
 

Tendances (20)

Using Git in Eclipse - Eclipse Summit Europe 2010-11-03
Using Git in Eclipse - Eclipse Summit Europe 2010-11-03Using Git in Eclipse - Eclipse Summit Europe 2010-11-03
Using Git in Eclipse - Eclipse Summit Europe 2010-11-03
 
Git & git hub
Git & git hubGit & git hub
Git & git hub
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.com
 
Introducing Git and git flow
Introducing Git and git flow Introducing Git and git flow
Introducing Git and git flow
 
Beginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitBeginner's Guide to Version Control with Git
Beginner's Guide to Version Control with Git
 
Git and GitHub - The beginning
Git and GitHub - The beginning Git and GitHub - The beginning
Git and GitHub - The beginning
 
Spring Projects Infrastructure
Spring Projects InfrastructureSpring Projects Infrastructure
Spring Projects Infrastructure
 
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...Assign, commit, and review - A developer’s guide to OpenStack contribution-20...
Assign, commit, and review - A developer’s guide to OpenStack contribution-20...
 
How Git and Gerrit make you more productive
How Git and Gerrit make you more productiveHow Git and Gerrit make you more productive
How Git and Gerrit make you more productive
 
Hacking Git and GitHub
Hacking Git and GitHubHacking Git and GitHub
Hacking Git and GitHub
 
OpenTuesday: Agile Testautomatisierung und Continuous Integration
OpenTuesday: Agile Testautomatisierung und Continuous IntegrationOpenTuesday: Agile Testautomatisierung und Continuous Integration
OpenTuesday: Agile Testautomatisierung und Continuous Integration
 
Assign, Commit, and Review
Assign, Commit, and ReviewAssign, Commit, and Review
Assign, Commit, and Review
 
Git and GitHub
Git and GitHubGit and GitHub
Git and GitHub
 
Github Case Study By Amil Ali
Github Case Study By Amil AliGithub Case Study By Amil Ali
Github Case Study By Amil Ali
 
Intro to Git & GitHub
Intro to Git & GitHubIntro to Git & GitHub
Intro to Git & GitHub
 
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison Dowdney
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison DowdneySetting up Notifications, Alerts & Webhooks with Flux v2 by Alison Dowdney
Setting up Notifications, Alerts & Webhooks with Flux v2 by Alison Dowdney
 
Evolution of Version Control In Open Source
Evolution of Version Control In Open SourceEvolution of Version Control In Open Source
Evolution of Version Control In Open Source
 
Github
GithubGithub
Github
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub plugin
 
A prentation on github
A prentation on githubA prentation on github
A prentation on github
 

En vedette

Git, gitHub, Azure and Visual Studio
Git, gitHub, Azure and Visual StudioGit, gitHub, Azure and Visual Studio
Git, gitHub, Azure and Visual StudioSalvatore Sorrentino
 
Using the GitHub App to Connect to Bitbucket
Using the GitHub App to Connect to BitbucketUsing the GitHub App to Connect to Bitbucket
Using the GitHub App to Connect to BitbucketLiam Dempsey
 
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...Troy Bernier
 
Crop Et And Implications For Irrigation
Crop Et And Implications For IrrigationCrop Et And Implications For Irrigation
Crop Et And Implications For Irrigationcarterjfranz
 
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...Ramesh Dhungel
 
5 hydrology quantities-measures_instruments_activities
5   hydrology quantities-measures_instruments_activities5   hydrology quantities-measures_instruments_activities
5 hydrology quantities-measures_instruments_activitiesAboutHydrology Slides
 
Daily evapotranspiration by combining remote sensing with ground observations...
Daily evapotranspiration by combining remote sensing with ground observations...Daily evapotranspiration by combining remote sensing with ground observations...
Daily evapotranspiration by combining remote sensing with ground observations...CIMMYT
 
Python IDLE (Integrated Development and Learning Environment) for remote sens...
Python IDLE (Integrated Development and Learning Environment) for remote sens...Python IDLE (Integrated Development and Learning Environment) for remote sens...
Python IDLE (Integrated Development and Learning Environment) for remote sens...Ramesh Dhungel
 
Session I: Water Consumption – Evapotranspiration (ET) Case Study Tunisia
Session I: Water Consumption – Evapotranspiration (ET) Case Study TunisiaSession I: Water Consumption – Evapotranspiration (ET) Case Study Tunisia
Session I: Water Consumption – Evapotranspiration (ET) Case Study TunisiaNENAwaterscarcity
 

En vedette (20)

Git, gitHub, Azure and Visual Studio
Git, gitHub, Azure and Visual StudioGit, gitHub, Azure and Visual Studio
Git, gitHub, Azure and Visual Studio
 
Using the GitHub App to Connect to Bitbucket
Using the GitHub App to Connect to BitbucketUsing the GitHub App to Connect to Bitbucket
Using the GitHub App to Connect to Bitbucket
 
13.3 arno model
13.3 arno model13.3 arno model
13.3 arno model
 
Introduction to Git and GitHub
Introduction to Git and GitHubIntroduction to Git and GitHub
Introduction to Git and GitHub
 
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...
A sensitivity Analysis of Eddy Covariance Data Processing Methods for Evapotr...
 
11 modern-iuh
11   modern-iuh11   modern-iuh
11 modern-iuh
 
Crop Et And Implications For Irrigation
Crop Et And Implications For IrrigationCrop Et And Implications For Irrigation
Crop Et And Implications For Irrigation
 
6 measurement&representation
6   measurement&representation6   measurement&representation
6 measurement&representation
 
Water platform 2011-2014
Water platform 2011-2014Water platform 2011-2014
Water platform 2011-2014
 
Evapotranspiration Bed Wastewater Treatment and Gardening
Evapotranspiration Bed Wastewater Treatment and GardeningEvapotranspiration Bed Wastewater Treatment and Gardening
Evapotranspiration Bed Wastewater Treatment and Gardening
 
Introduction to post_gis
Introduction to post_gisIntroduction to post_gis
Introduction to post_gis
 
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...
TIME INTEGRATION OF EVAPOTRANSPIRATION USING A TWO SOURCE SURFACE ENERGY BALA...
 
5 hydrology quantities-measures_instruments_activities
5   hydrology quantities-measures_instruments_activities5   hydrology quantities-measures_instruments_activities
5 hydrology quantities-measures_instruments_activities
 
Daily evapotranspiration by combining remote sensing with ground observations...
Daily evapotranspiration by combining remote sensing with ground observations...Daily evapotranspiration by combining remote sensing with ground observations...
Daily evapotranspiration by combining remote sensing with ground observations...
 
14 snow hydrology-part1
14 snow hydrology-part114 snow hydrology-part1
14 snow hydrology-part1
 
Python IDLE (Integrated Development and Learning Environment) for remote sens...
Python IDLE (Integrated Development and Learning Environment) for remote sens...Python IDLE (Integrated Development and Learning Environment) for remote sens...
Python IDLE (Integrated Development and Learning Environment) for remote sens...
 
Session I: Water Consumption – Evapotranspiration (ET) Case Study Tunisia
Session I: Water Consumption – Evapotranspiration (ET) Case Study TunisiaSession I: Water Consumption – Evapotranspiration (ET) Case Study Tunisia
Session I: Water Consumption – Evapotranspiration (ET) Case Study Tunisia
 
10 water in soil-rev 1
10   water in soil-rev 110   water in soil-rev 1
10 water in soil-rev 1
 
RoccoPancieraMesiano sept25 2013
RoccoPancieraMesiano sept25 2013RoccoPancieraMesiano sept25 2013
RoccoPancieraMesiano sept25 2013
 
Introduction tohydrology c
Introduction tohydrology cIntroduction tohydrology c
Introduction tohydrology c
 

Similaire à EGit Tutorial: Load Projects into GitHub

KubeCon EU 2022 Istio, Flux & Flagger.pdf
KubeCon EU 2022 Istio, Flux & Flagger.pdfKubeCon EU 2022 Istio, Flux & Flagger.pdf
KubeCon EU 2022 Istio, Flux & Flagger.pdfWeaveworks
 
Git, github and the hacktober fest
Git, github and the hacktober festGit, github and the hacktober fest
Git, github and the hacktober festUtkarshRaj83
 
Hardening Your CI/CD Pipelines with GitOps and Continuous Security
Hardening Your CI/CD Pipelines with GitOps and Continuous SecurityHardening Your CI/CD Pipelines with GitOps and Continuous Security
Hardening Your CI/CD Pipelines with GitOps and Continuous SecurityWeaveworks
 
Introduction to GitHub, Open Source and Tech Article
Introduction to GitHub, Open Source and Tech ArticleIntroduction to GitHub, Open Source and Tech Article
Introduction to GitHub, Open Source and Tech ArticlePRIYATHAMDARISI
 
Hacktoberfest GDSC BBBDITM.pptx
Hacktoberfest GDSC BBBDITM.pptxHacktoberfest GDSC BBBDITM.pptx
Hacktoberfest GDSC BBBDITM.pptxArishAhmad9
 
Git Tutorial A Comprehensive Guide for Beginners.pdf
Git Tutorial A Comprehensive Guide for Beginners.pdfGit Tutorial A Comprehensive Guide for Beginners.pdf
Git Tutorial A Comprehensive Guide for Beginners.pdfuzair
 
Starting with Git & GitHub
Starting with Git & GitHubStarting with Git & GitHub
Starting with Git & GitHubNicolás Tourné
 
3DC Intro to Git Workshop
3DC Intro to Git Workshop3DC Intro to Git Workshop
3DC Intro to Git WorkshopBeckhamWee
 
Hacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginnersHacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginnersDeepikaRana30
 
Beginner Workshop for Student Developers - Tratech-presentation.pdf
Beginner Workshop for Student Developers - Tratech-presentation.pdfBeginner Workshop for Student Developers - Tratech-presentation.pdf
Beginner Workshop for Student Developers - Tratech-presentation.pdfGDSCKNUST
 
concordia hacktoberfest.pptx
concordia hacktoberfest.pptxconcordia hacktoberfest.pptx
concordia hacktoberfest.pptxAnkurVerma95745
 
CodeMontage CodeFlow 1
CodeMontage CodeFlow 1CodeMontage CodeFlow 1
CodeMontage CodeFlow 1CodeMontage
 
Increase the Velocity of Your Software Releases Using GitHub and DeployHub
Increase the Velocity of Your Software Releases Using GitHub and DeployHubIncrease the Velocity of Your Software Releases Using GitHub and DeployHub
Increase the Velocity of Your Software Releases Using GitHub and DeployHubDevOps.com
 
Introduction to git hub
Introduction to git hubIntroduction to git hub
Introduction to git hubNaveen Pandey
 
Introduction to github using Egit
Introduction to github using EgitIntroduction to github using Egit
Introduction to github using Egitmatz_twt
 
FooConf23_Bringing the cloud back down to earth.pptx
FooConf23_Bringing the cloud back down to earth.pptxFooConf23_Bringing the cloud back down to earth.pptx
FooConf23_Bringing the cloud back down to earth.pptxGrace Jansen
 

Similaire à EGit Tutorial: Load Projects into GitHub (20)

Giddy Up on GitHub
Giddy Up on GitHubGiddy Up on GitHub
Giddy Up on GitHub
 
KubeCon EU 2022 Istio, Flux & Flagger.pdf
KubeCon EU 2022 Istio, Flux & Flagger.pdfKubeCon EU 2022 Istio, Flux & Flagger.pdf
KubeCon EU 2022 Istio, Flux & Flagger.pdf
 
Git, github and the hacktober fest
Git, github and the hacktober festGit, github and the hacktober fest
Git, github and the hacktober fest
 
Hardening Your CI/CD Pipelines with GitOps and Continuous Security
Hardening Your CI/CD Pipelines with GitOps and Continuous SecurityHardening Your CI/CD Pipelines with GitOps and Continuous Security
Hardening Your CI/CD Pipelines with GitOps and Continuous Security
 
Introduction to GitHub, Open Source and Tech Article
Introduction to GitHub, Open Source and Tech ArticleIntroduction to GitHub, Open Source and Tech Article
Introduction to GitHub, Open Source and Tech Article
 
Hacktoberfest GDSC BBBDITM.pptx
Hacktoberfest GDSC BBBDITM.pptxHacktoberfest GDSC BBBDITM.pptx
Hacktoberfest GDSC BBBDITM.pptx
 
Git Tutorial A Comprehensive Guide for Beginners.pdf
Git Tutorial A Comprehensive Guide for Beginners.pdfGit Tutorial A Comprehensive Guide for Beginners.pdf
Git Tutorial A Comprehensive Guide for Beginners.pdf
 
Starting with Git & GitHub
Starting with Git & GitHubStarting with Git & GitHub
Starting with Git & GitHub
 
3DC Intro to Git Workshop
3DC Intro to Git Workshop3DC Intro to Git Workshop
3DC Intro to Git Workshop
 
Hacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginnersHacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginners
 
CICD_1670665418.pdf
CICD_1670665418.pdfCICD_1670665418.pdf
CICD_1670665418.pdf
 
Git
GitGit
Git
 
Beginner Workshop for Student Developers - Tratech-presentation.pdf
Beginner Workshop for Student Developers - Tratech-presentation.pdfBeginner Workshop for Student Developers - Tratech-presentation.pdf
Beginner Workshop for Student Developers - Tratech-presentation.pdf
 
concordia hacktoberfest.pptx
concordia hacktoberfest.pptxconcordia hacktoberfest.pptx
concordia hacktoberfest.pptx
 
CodeMontage CodeFlow 1
CodeMontage CodeFlow 1CodeMontage CodeFlow 1
CodeMontage CodeFlow 1
 
Increase the Velocity of Your Software Releases Using GitHub and DeployHub
Increase the Velocity of Your Software Releases Using GitHub and DeployHubIncrease the Velocity of Your Software Releases Using GitHub and DeployHub
Increase the Velocity of Your Software Releases Using GitHub and DeployHub
 
Hacktoberfest 2021
Hacktoberfest 2021Hacktoberfest 2021
Hacktoberfest 2021
 
Introduction to git hub
Introduction to git hubIntroduction to git hub
Introduction to git hub
 
Introduction to github using Egit
Introduction to github using EgitIntroduction to github using Egit
Introduction to github using Egit
 
FooConf23_Bringing the cloud back down to earth.pptx
FooConf23_Bringing the cloud back down to earth.pptxFooConf23_Bringing the cloud back down to earth.pptx
FooConf23_Bringing the cloud back down to earth.pptx
 

Plus de AboutHydrology Slides (17)

Luca Brocca seminario trento
Luca Brocca seminario trentoLuca Brocca seminario trento
Luca Brocca seminario trento
 
3b jf h-readingdatafromconsole
3b jf h-readingdatafromconsole3b jf h-readingdatafromconsole
3b jf h-readingdatafromconsole
 
3 jf h-linearequations
3  jf h-linearequations3  jf h-linearequations
3 jf h-linearequations
 
2 jfh-yourveryfirstprogram
2  jfh-yourveryfirstprogram2  jfh-yourveryfirstprogram
2 jfh-yourveryfirstprogram
 
1 jf h-getting started
1  jf h-getting started1  jf h-getting started
1 jf h-getting started
 
Introduction tohydrology b
Introduction tohydrology bIntroduction tohydrology b
Introduction tohydrology b
 
La piattaforma acqua
La piattaforma acquaLa piattaforma acqua
La piattaforma acqua
 
La convenzione delle alpi
La convenzione delle alpiLa convenzione delle alpi
La convenzione delle alpi
 
1 introduction to hydrology
1   introduction to hydrology1   introduction to hydrology
1 introduction to hydrology
 
9 precipitations - rainfall
9   precipitations - rainfall9   precipitations - rainfall
9 precipitations - rainfall
 
13 solar radiation
13   solar radiation13   solar radiation
13 solar radiation
 
15 Evapotranspiration
15   Evapotranspiration15   Evapotranspiration
15 Evapotranspiration
 
4 introduction to uDig
4   introduction to uDig4   introduction to uDig
4 introduction to uDig
 
3 introduction gis
3   introduction gis3   introduction gis
3 introduction gis
 
2 hydro-geomorphology
2  hydro-geomorphology2  hydro-geomorphology
2 hydro-geomorphology
 
0-RealBookStyleAndNotation
0-RealBookStyleAndNotation0-RealBookStyleAndNotation
0-RealBookStyleAndNotation
 
0-RealBooksOfHydrology
0-RealBooksOfHydrology0-RealBooksOfHydrology
0-RealBooksOfHydrology
 

Dernier

Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfAyushMahapatra5
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxVishalSingh1417
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingTeacherCyreneCayanan
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
General AI for Medical Educators April 2024
General AI for Medical Educators April 2024General AI for Medical Educators April 2024
General AI for Medical Educators April 2024Janet Corral
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...christianmathematics
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfchloefrazer622
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 

Dernier (20)

Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
General AI for Medical Educators April 2024
General AI for Medical Educators April 2024General AI for Medical Educators April 2024
General AI for Medical Educators April 2024
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 

EGit Tutorial: Load Projects into GitHub

  • 1. Java for Hydrologists Some useful applications of EGit R. Rigon, F. Serafin R.Rigon-IltavolodilavorodiRemoWolf March 20, 2014
  • 2. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Objectives Some useful applications of EGit1 • Introduction to EGit and installation into Eclipse; • Load local existing project into remote GitHub repository; • Clone remote project into local repository. 1 All the instructions are taken from Lars Vogel’s blog http://www.vogella.com/tutorials/EclipseGit/article.html and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide. Riccardo Rigon, Francesco Serafin March 20, 2014 2 / 48
  • 3. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Objectives Some useful applications of EGit1 • Introduction to EGit and installation into Eclipse; • Load local existing project into remote GitHub repository; • Clone remote project into local repository. 1 All the instructions are taken from Lars Vogel’s blog http://www.vogella.com/tutorials/EclipseGit/article.html and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide. Riccardo Rigon, Francesco Serafin March 20, 2014 2 / 48
  • 4. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Objectives Some useful applications of EGit1 • Introduction to EGit and installation into Eclipse; • Load local existing project into remote GitHub repository; • Clone remote project into local repository. 1 All the instructions are taken from Lars Vogel’s blog http://www.vogella.com/tutorials/EclipseGit/article.html and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide. Riccardo Rigon, Francesco Serafin March 20, 2014 2 / 48
  • 5. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Objectives Some useful applications of EGit1 • Introduction to EGit and installation into Eclipse; • Load local existing project into remote GitHub repository; • Clone remote project into local repository. 1 All the instructions are taken from Lars Vogel’s blog http://www.vogella.com/tutorials/EclipseGit/article.html and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide. Riccardo Rigon, Francesco Serafin March 20, 2014 2 / 48
  • 6. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Objectives Some useful applications of EGit1 • Introduction to EGit and installation into Eclipse; • Load local existing project into remote GitHub repository; • Clone remote project into local repository. For the complete guide visit http://www.vogella.com/tutorials/EclipseGit/article.html https://wiki.eclipse.org/EGit/User_Guide 1 All the instructions are taken from Lars Vogel’s blog http://www.vogella.com/tutorials/EclipseGit/article.html and from Eclipsepedia https://wiki.eclipse.org/EGit/User_Guide. Riccardo Rigon, Francesco Serafin March 20, 2014 2 / 48
  • 7. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Git and GitHub What is Git? In software development, Git is a distributed revision control and source code management system2 . 2 Git was initially designed and developed by Linus Torvalds for Linux kernel development Riccardo Rigon, Francesco Serafin March 20, 2014 3 / 48
  • 8. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Git and GitHub What is Git? In software development, Git is a distributed revision control and source code management system2 . Distributed revision control In computer programming, a distributed revision control system (DRCS) or distributed version control system (DVCS) keeps track of software revisions and allows many developers to work on a given project without requiring that they maintain a connection to a common network. 2 Git was initially designed and developed by Linus Torvalds for Linux kernel development Riccardo Rigon, Francesco Serafin March 20, 2014 3 / 48
  • 9. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Git and GitHub What is Git? In software development, Git is a distributed revision control and source code management system2 . Distributed revision control In computer programming, a distributed revision control system (DRCS) or distributed version control system (DVCS) keeps track of software revisions and allows many developers to work on a given project without requiring that they maintain a connection to a common network. Every Git working directory is a full-fledged repository with complete history and full version tracking capabilities, not dependent on network access or a central server. 2 Git was initially designed and developed by Linus Torvalds for Linux kernel development Riccardo Rigon, Francesco Serafin March 20, 2014 3 / 48
  • 10. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Git and GitHub What is GitHub? GitHub is a web-based hosting service for software development projects that use the Git revision control system. GitHub offers both paid plans for private repositories, and free accounts for open source projects. Riccardo Rigon, Francesco Serafin March 20, 2014 4 / 48
  • 11. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Git and GitHub What is GitHub? GitHub is a web-based hosting service for software development projects that use the Git revision control system. GitHub offers both paid plans for private repositories, and free accounts for open source projects. The site provides social networking functionality such as feeds, followers, wikis and the social network graph to display how developers work on their versions of a repository. Riccardo Rigon, Francesco Serafin March 20, 2014 4 / 48
  • 12. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project What is EGit What is EGit? EGit is an Eclipse plug-in which allows you to use the distributed version control system Git directly within the Eclipse IDE. EGit is based on the JGit library. Riccardo Rigon, Francesco Serafin March 20, 2014 5 / 48
  • 13. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project What is EGit What is EGit? EGit is an Eclipse plug-in which allows you to use the distributed version control system Git directly within the Eclipse IDE. EGit is based on the JGit library. JGit JGit is a library which implements the Git functionality in Java Riccardo Rigon, Francesco Serafin March 20, 2014 5 / 48
  • 14. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Installation of EGit The EGit plug-in can be installed into every Eclipse IDE installation. Riccardo Rigon, Francesco Serafin March 20, 2014 6 / 48
  • 15. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Installation of EGit The EGit plug-in can be installed into every Eclipse IDE installation. Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in their default configuration Riccardo Rigon, Francesco Serafin March 20, 2014 6 / 48
  • 16. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Installation of EGit The EGit plug-in can be installed into every Eclipse IDE installation. Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in their default configuration No additional installation is required Riccardo Rigon, Francesco Serafin March 20, 2014 6 / 48
  • 17. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Installation of EGit The EGit plug-in can be installed into every Eclipse IDE installation. Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in their default configuration No additional installation is required If the EGit plug-in is missing in your Eclipse installation, you can install it via the Eclipse Marketplace. Start this manager via the Help→Eclipse Marketplace menu entry. Riccardo Rigon, Francesco Serafin March 20, 2014 6 / 48
  • 18. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Installation of EGit The EGit plug-in can be installed into every Eclipse IDE installation. Most Eclipse 4.2 and Eclipse 4.3 downloads from Eclipse.org contain EGit in their default configuration No additional installation is required If the EGit plug-in is missing in your Eclipse installation, you can install it via the Eclipse Marketplace. Start this manager via the Help→Eclipse Marketplace menu entry. Riccardo Rigon, Francesco Serafin March 20, 2014 6 / 48
  • 19. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Eclipse Marketplace The dialog to install EGit is depicted in the following screenshot. Riccardo Rigon, Francesco Serafin March 20, 2014 7 / 48
  • 20. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Installation of Git into Eclipse Eclipse Marketplace The dialog to install EGit is depicted in the following screenshot. Riccardo Rigon, Francesco Serafin March 20, 2014 7 / 48
  • 21. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 22. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 23. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 24. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 25. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 26. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Eclipse preferences Before using EGit you should: • create a folder where store the projects you want to load on GitHub (the Git default repository folder); • configure your name used in Git; • configure your email address used in Git3 ; • configure your Git default repository folder. The Eclipse Git functionality allows you to configure your default user and email address for a commit. Select Window→Preferences→Team→Git→Configuration to set them up. 3 Git configuration settings can be configured using the EGit configuration preference page but this configuration is not store in the Eclipse preferences store but in git configuration files in order to ensure that native git sees the same configuration. Riccardo Rigon, Francesco Serafin March 20, 2014 8 / 48
  • 27. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up name and email used in Git You can add entries to your Git configuration by pressing the Add Entry button on the Git Configuration preference page. Riccardo Rigon, Francesco Serafin March 20, 2014 9 / 48
  • 28. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up name and email used in Git You can add entries to your Git configuration by pressing the Add Entry button on the Git Configuration preference page. Riccardo Rigon, Francesco Serafin March 20, 2014 9 / 48
  • 29. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up name used in Git To add your user, use the user.name as key and your real name as value. Riccardo Rigon, Francesco Serafin March 20, 2014 10 / 48
  • 30. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up mail used in Git Repeat the procedure for your email address, using user.email as key as shown below. Riccardo Rigon, Francesco Serafin March 20, 2014 11 / 48
  • 31. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up Git default repository folder You can also enter the default folder for storing Git repositories via the Window→Preferences→Team→Git and writing the correct path in Default Repository Folder entry. Riccardo Rigon, Francesco Serafin March 20, 2014 12 / 48
  • 32. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Setting up Git in Eclipse Set up Git default repository folder You can also enter the default folder for storing Git repositories via the Window→Preferences→Team→Git and writing the correct path in Default Repository Folder entry. Riccardo Rigon, Francesco Serafin March 20, 2014 12 / 48
  • 33. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 34. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 35. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 36. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 37. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 38. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 39. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project New Java Project Create a new Java project (we will work with a simple Hello World code). • Right click in the white space of the Package Explorer, after click on New→Java Project; • In the Dialog that appeared, remove the tick in Use default location; • Click on Browse, in the Dialog that appeared enter in your Git default repository folder and create a new folder named JavaForHydrologists.example. Enter in the new folder and click OK. • Thus Eclipse automatically sets the Folder Name like Project Name. Then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 13 / 48
  • 40. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 41. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. You must: • Create a new package; • Create a new class; • Write the code. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 42. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. You must: • Create a new package; • Create a new class; • Write the code. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 43. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. You must: • Create a new package; • Create a new class; • Write the code. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 44. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. You must: • Create a new package; • Create a new class; • Write the code. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 45. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create the Project Hello World! Now write a simple Hello World code in the newly created project. You must: • Create a new package; • Create a new class; • Write the code. Once you have wrote the code, we are going to create a local Git Repository. Riccardo Rigon, Francesco Serafin March 20, 2014 14 / 48
  • 46. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Git Repositories view First we need to view the Git Repositories present in our Git default repository. • Click on Window→Show View→Other; • In the Show view Dialog, expand Git and click on Git Repositories. Then click OK; • Now you can see the Git Repositories tab in your Eclipse IDE. Riccardo Rigon, Francesco Serafin March 20, 2014 15 / 48
  • 47. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Git Repositories view First we need to view the Git Repositories present in our Git default repository. • Click on Window→Show View→Other; • In the Show view Dialog, expand Git and click on Git Repositories. Then click OK; • Now you can see the Git Repositories tab in your Eclipse IDE. Riccardo Rigon, Francesco Serafin March 20, 2014 15 / 48
  • 48. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Git Repositories view First we need to view the Git Repositories present in our Git default repository. • Click on Window→Show View→Other; • In the Show view Dialog, expand Git and click on Git Repositories. Then click OK; • Now you can see the Git Repositories tab in your Eclipse IDE. Riccardo Rigon, Francesco Serafin March 20, 2014 15 / 48
  • 49. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Git Repositories view First we need to view the Git Repositories present in our Git default repository. • Click on Window→Show View→Other; • In the Show view Dialog, expand Git and click on Git Repositories. Then click OK; • Now you can see the Git Repositories tab in your Eclipse IDE. Riccardo Rigon, Francesco Serafin March 20, 2014 15 / 48
  • 50. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Share the Java Project To create a new Git local Repository, we have to share the existing project. • Right click on the JavaForydrologists.example project and then click to Team→Share Project; • Select the repository type Git and click Next; • To configure the Git repository select Use or create repository in parent folder of project; • In the next Dialog select the project and click to Create Repository, after click Finish; Riccardo Rigon, Francesco Serafin March 20, 2014 16 / 48
  • 51. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Share the Java Project To create a new Git local Repository, we have to share the existing project. • Right click on the JavaForydrologists.example project and then click to Team→Share Project; • Select the repository type Git and click Next; • To configure the Git repository select Use or create repository in parent folder of project; • In the next Dialog select the project and click to Create Repository, after click Finish; Riccardo Rigon, Francesco Serafin March 20, 2014 16 / 48
  • 52. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Share the Java Project To create a new Git local Repository, we have to share the existing project. • Right click on the JavaForydrologists.example project and then click to Team→Share Project; • Select the repository type Git and click Next; • To configure the Git repository select Use or create repository in parent folder of project; • In the next Dialog select the project and click to Create Repository, after click Finish; Riccardo Rigon, Francesco Serafin March 20, 2014 16 / 48
  • 53. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Share the Java Project To create a new Git local Repository, we have to share the existing project. • Right click on the JavaForydrologists.example project and then click to Team→Share Project; • Select the repository type Git and click Next; • To configure the Git repository select Use or create repository in parent folder of project; • In the next Dialog select the project and click to Create Repository, after click Finish; Riccardo Rigon, Francesco Serafin March 20, 2014 16 / 48
  • 54. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository Share the Java Project To create a new Git local Repository, we have to share the existing project. • Right click on the JavaForydrologists.example project and then click to Team→Share Project; • Select the repository type Git and click Next; • To configure the Git repository select Use or create repository in parent folder of project; • In the next Dialog select the project and click to Create Repository, after click Finish; Riccardo Rigon, Francesco Serafin March 20, 2014 16 / 48
  • 55. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create local Git Repository But the decorator text “[NO-HEAD]” behind the project shows that this project is not tracked in a repository and the question mark decorators show that the .classpath, .project, the .settings files and the src content are not yet under version control. Riccardo Rigon, Francesco Serafin March 20, 2014 17 / 48
  • 56. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Create a remote repository on GitHub Go to www.github.com and log in with your credentials. In your home click like below. Riccardo Rigon, Francesco Serafin March 20, 2014 18 / 48
  • 57. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Create a remote repository on GitHub Go to www.github.com and log in with your credentials. In your home click like below. Riccardo Rigon, Francesco Serafin March 20, 2014 18 / 48
  • 58. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Create a remote repository on GitHub Go to www.github.com and log in with your credentials. In your home click like below. Riccardo Rigon, Francesco Serafin March 20, 2014 18 / 48
  • 59. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Repository name: JavaFor Hydrologists.example Riccardo Rigon, Francesco Serafin March 20, 2014 19 / 48
  • 60. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Repository name: JavaFor Hydrologists.example Riccardo Rigon, Francesco Serafin March 20, 2014 19 / 48
  • 61. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Description of the repository: First GitHub repository to use with EGit Riccardo Rigon, Francesco Serafin March 20, 2014 20 / 48
  • 62. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Description of the repository: First GitHub repository to use with EGit Riccardo Rigon, Francesco Serafin March 20, 2014 20 / 48
  • 63. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Click to Create repository Riccardo Rigon, Francesco Serafin March 20, 2014 21 / 48
  • 64. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub Click to Create repository Riccardo Rigon, Francesco Serafin March 20, 2014 21 / 48
  • 65. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub After creation of your new repository, GitHub displays the information about what you have to do if you want to connetc to this repository via the command line. Riccardo Rigon, Francesco Serafin March 20, 2014 22 / 48
  • 66. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub After creation of your new repository, GitHub displays the information about what you have to do if you want to connetc to this repository via the command line. Riccardo Rigon, Francesco Serafin March 20, 2014 22 / 48
  • 67. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Create a remote repository on GitHub After creation of your new repository, GitHub displays the information about what you have to do if you want to connetc to this repository via the command line. As we are going to use EGit you can ignore this information, but don’t close the window because we need the SSH or HTTP link. Riccardo Rigon, Francesco Serafin March 20, 2014 22 / 48
  • 68. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote Now we have the link indispensable to establish the connection between local and remote repository. Thus, in Eclipse in the Git Repositories tab, expand the JavaForHydrologists.example and right click on Remote and then Create Remote. Riccardo Rigon, Francesco Serafin March 20, 2014 23 / 48
  • 69. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote • In the open Dialog the Remote name must be origin, then click OK; • To Configure Push, in the next Dialog click on Change; • From your Git Remote Repository, copy the https link and paste it in the URI space. Eclipse automatically will fill the other fileds • After you must only write your GitHub credentials and the click to Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 24 / 48
  • 70. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote • In the open Dialog the Remote name must be origin, then click OK; • To Configure Push, in the next Dialog click on Change; • From your Git Remote Repository, copy the https link and paste it in the URI space. Eclipse automatically will fill the other fileds • After you must only write your GitHub credentials and the click to Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 24 / 48
  • 71. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote • In the open Dialog the Remote name must be origin, then click OK; • To Configure Push, in the next Dialog click on Change; • From your Git Remote Repository, copy the https link and paste it in the URI space. Eclipse automatically will fill the other fileds • After you must only write your GitHub credentials and the click to Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 24 / 48
  • 72. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote • In the open Dialog the Remote name must be origin, then click OK; • To Configure Push, in the next Dialog click on Change; • From your Git Remote Repository, copy the https link and paste it in the URI space. Eclipse automatically will fill the other fileds • After you must only write your GitHub credentials and the click to Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 24 / 48
  • 73. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Set Remote in local repository Create Remote • In the open Dialog the Remote name must be origin, then click OK; • To Configure Push, in the next Dialog click on Change; • From your Git Remote Repository, copy the https link and paste it in the URI space. Eclipse automatically will fill the other fileds • After you must only write your GitHub credentials and the click to Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 24 / 48
  • 74. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 75. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 76. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 77. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 78. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 79. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 80. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 81. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 82. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 83. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Basic operations So we can prepare our local repository to push it to remote repository. The most important operations are described below. Right click on the project in the Package Explorer at every step: • Team→Add to index to add the selected resource(s) to the index of Git • Team→Commit to open the commit dialog for committing to your Git repository Then click Commit • Team→Push branch only for the first time, beacuse you must create the first master branch • In this Dialog there is nothing to do, click Next • Insert your credentials of GitHub • In this Dialog click Finish • After push, click OK Riccardo Rigon, Francesco Serafin March 20, 2014 25 / 48
  • 84. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Summary of the main steps Our local repository is been now copied on remote repository. But once you have create the first master branch, to push your modify you need follow this basic sequence: • Team→Add to index • Team→Commit • Team→Push to upstream Riccardo Rigon, Francesco Serafin March 20, 2014 26 / 48
  • 85. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Summary of the main steps Our local repository is been now copied on remote repository. But once you have create the first master branch, to push your modify you need follow this basic sequence: • Team→Add to index • Team→Commit • Team→Push to upstream Riccardo Rigon, Francesco Serafin March 20, 2014 26 / 48
  • 86. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Summary of the main steps Our local repository is been now copied on remote repository. But once you have create the first master branch, to push your modify you need follow this basic sequence: • Team→Add to index • Team→Commit • Team→Push to upstream Riccardo Rigon, Francesco Serafin March 20, 2014 26 / 48
  • 87. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Summary of the main steps Our local repository is been now copied on remote repository. But once you have create the first master branch, to push your modify you need follow this basic sequence: • Team→Add to index • Team→Commit • Team→Push to upstream Riccardo Rigon, Francesco Serafin March 20, 2014 26 / 48
  • 88. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Problems with basic operations • After clicking Commit; • If you cannot Push to Upstream; • You can fix this problem in the way shown before. Riccardo Rigon, Francesco Serafin March 20, 2014 27 / 48
  • 89. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Problems with basic operations • After clicking Commit; • If you cannot Push to Upstream; • You can fix this problem in the way shown before. Riccardo Rigon, Francesco Serafin March 20, 2014 27 / 48
  • 90. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Problems with basic operations • After clicking Commit; • If you cannot Push to Upstream; • You can fix this problem in the way shown before. Riccardo Rigon, Francesco Serafin March 20, 2014 27 / 48
  • 91. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Problems with basic operations • After clicking Commit; • If you cannot Push to Upstream; • You can fix this problem in the way shown before. Riccardo Rigon, Francesco Serafin March 20, 2014 27 / 48
  • 92. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings Right click on the project that you want to push and Team→Remote→Push Riccardo Rigon, Francesco Serafin March 20, 2014 28 / 48
  • 93. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings Select Custom URI and paste in the URI tab the ssh link to your repository. The ssh form is: git@github.com: username/project.git In my case git@github.com:francescoS/ JavaForHydrologists.example.git Select the ssh protocol and Eclipse will fill all tabs automatically. After click Next Riccardo Rigon, Francesco Serafin March 20, 2014 29 / 48
  • 94. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings In the window Push to: origin click on drop-down menu of the Source ref and select master [branch] or the branch you want Riccardo Rigon, Francesco Serafin March 20, 2014 30 / 48
  • 95. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings Click to Add Spec on the right and Next. Riccardo Rigon, Francesco Serafin March 20, 2014 31 / 48
  • 96. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings Click to Add Spec on the right and Next. Riccardo Rigon, Francesco Serafin March 20, 2014 31 / 48
  • 97. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push. . . with more settings Click to Add Spec on the right and Next. In the other windows you can see a small summary of the push operation, then click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 31 / 48
  • 98. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Basic operations in EGit Push...with more settings After Push operations, the appeared Dialog shows the Push Results. Riccardo Rigon, Francesco Serafin March 20, 2014 32 / 48
  • 99. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Introduction If we are arrived here, I suppose you have your Git Repositories view in the Eclipse IDE, otherwise return to 15. Using the Git Clone Wizard you may clone remote repositories using different transport protocols. The wizard can be started by clicking on the botton Clone a Git Repository and add the clone to this view Riccardo Rigon, Francesco Serafin March 20, 2014 33 / 48
  • 100. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Repository Selection Copy the URL from GitHub page of the searched project (in this case https://github.com/francescoS/JavaForHydrologists.firstClone) and paste it in the URI space of the Clone Git Repository Dialog. The other fields (Host and Repository path) are filled automatically by Eclipse.Riccardo Rigon, Francesco Serafin March 20, 2014 34 / 48
  • 101. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Repository Selection Copy the URL from GitHub page of the searched project (in this case https://github.com/francescoS/JavaForHydrologists.firstClone) and paste it in the URI space of the Clone Git Repository Dialog. The other fields (Host and Repository path) are filled automatically by Eclipse.Riccardo Rigon, Francesco Serafin March 20, 2014 34 / 48
  • 102. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Repository Selection You must fill the fields User and Password with your credentials of GitHub. Riccardo Rigon, Francesco Serafin March 20, 2014 35 / 48
  • 103. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Repository Selection You must fill the fields User and Password with your credentials of GitHub. Riccardo Rigon, Francesco Serafin March 20, 2014 35 / 48
  • 104. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Branch Selection Click Next, in the Open Dialog choose wich branches shall be cloned from the remote repository (in this case there is only one branch). If you are not sure which branches you need, simply hit Select All. You can filter the branches by their name by typing using the text control above the list. Riccardo Rigon, Francesco Serafin March 20, 2014 36 / 48
  • 105. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Local Destination Click Next, in the Open Dialog select the Directory where store the repository on the local file system and define some initial settings. . Riccardo Rigon, Francesco Serafin March 20, 2014 37 / 48
  • 106. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Local Destination Click Next, in the Open Dialog select the Directory where store the repository on the local file system and define some initial settings. . Riccardo Rigon, Francesco Serafin March 20, 2014 37 / 48
  • 107. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Clone project Local Destination Click Next, in the Open Dialog select the Directory where store the repository on the local file system and define some initial settings. Click Finish. Riccardo Rigon, Francesco Serafin March 20, 2014 37 / 48
  • 108. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Import the project in the Package Explorer Now, to modify the project that you cloned before, you have to import it in your Package Explorer. Thus, right click on the view Package Explorer and Import. Riccardo Rigon, Francesco Serafin March 20, 2014 38 / 48
  • 109. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Import the project in the Package Explorer Select Git→Project from Git Riccardo Rigon, Francesco Serafin March 20, 2014 39 / 48
  • 110. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Import the project in the Package Explorer Select Git→Project from Git Riccardo Rigon, Francesco Serafin March 20, 2014 39 / 48
  • 111. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Import the project in the Package Explorer Select Git→Project from Git and click Next. Riccardo Rigon, Francesco Serafin March 20, 2014 39 / 48
  • 112. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Import the project in the Package Explorer Select Existing local repository and click Next. Riccardo Rigon, Francesco Serafin March 20, 2014 40 / 48
  • 113. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Select the repository JavaForHydrologists.firstClone and click Next. Riccardo Rigon, Francesco Serafin March 20, 2014 41 / 48
  • 114. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer Select Import existing projects and click Next. Riccardo Rigon, Francesco Serafin March 20, 2014 42 / 48
  • 115. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Import the project in the Package Explorer This is the last Dialog, that summarizes the projects that you are importing. Then click Finish. Now the project is visible in the Package Explorer and you can modify it. Riccardo Rigon, Francesco Serafin March 20, 2014 43 / 48
  • 116. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History But first to modify a cloned repository, it’s important to examine the history of the entire project. So we are going to open a new tab in our Eclipse IDE: History. • Click to Window→Show View→Other; • Search and expand Team; • Then select History and click OK. Riccardo Rigon, Francesco Serafin March 20, 2014 44 / 48
  • 117. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History But first to modify a cloned repository, it’s important to examine the history of the entire project. So we are going to open a new tab in our Eclipse IDE: History. • Click to Window→Show View→Other; • Search and expand Team; • Then select History and click OK. Riccardo Rigon, Francesco Serafin March 20, 2014 44 / 48
  • 118. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History But first to modify a cloned repository, it’s important to examine the history of the entire project. So we are going to open a new tab in our Eclipse IDE: History. • Click to Window→Show View→Other; • Search and expand Team; • Then select History and click OK. Riccardo Rigon, Francesco Serafin March 20, 2014 44 / 48
  • 119. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History But first to modify a cloned repository, it’s important to examine the history of the entire project. So we are going to open a new tab in our Eclipse IDE: History. • Click to Window→Show View→Other; • Search and expand Team; • Then select History and click OK. Riccardo Rigon, Francesco Serafin March 20, 2014 44 / 48
  • 120. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History Now the History tab is open and you can examine all the history of the project on which you are going to work. Riccardo Rigon, Francesco Serafin March 20, 2014 45 / 48
  • 121. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project How to view Git History Git History Now the History tab is open and you can examine all the history of the project on which you are going to work. Riccardo Rigon, Francesco Serafin March 20, 2014 45 / 48
  • 122. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Introduction Modify the JavaForHydrologists.firstClone project Now you can modify the simple code that we just cloned. Some tips: • you can use the TextIO class rather than simple System.out.println(); • you can read the string from console, so you can create two simple methods: • Read from console; • Write in console. • COMMENT ALL NEW LINES! Riccardo Rigon, Francesco Serafin March 20, 2014 46 / 48
  • 123. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Introduction A useful tip: JAutodoc If you want to have a good standard to comment your code, you can use JAutodoc. It is an Eclipse Plugin for automatically adding Javadoc and file headers to your source code. It optionally generates initial comments from element name by using Velocity templates for Javadoc and file headers. Riccardo Rigon, Francesco Serafin March 20, 2014 47 / 48
  • 124. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Introduction A useful tip: JAutodoc If you want to have a good standard to comment your code, you can use JAutodoc. It is an Eclipse Plugin for automatically adding Javadoc and file headers to your source code. It optionally generates initial comments from element name by using Velocity templates for Javadoc and file headers. First install it: Help→Eclipse Marketplace and search JAutodoc. Riccardo Rigon, Francesco Serafin March 20, 2014 47 / 48
  • 125. Introduction Push new local project on remote Clone remote repo in your local Push modifies of cloned project Introduction How to use JAutodoc To use JAutodoc, right click on the code and JAutodoc→Add javadoc. Riccardo Rigon, Francesco Serafin March 20, 2014 48 / 48