Assume that you have an empty repository in GitHub and no project starter anywhere
- Open a local project
- Clone a repository into the local device (can use GitHub Desktop to do it)
- in Spring Tool Suite, Git perspective
click on add an existing local Git Repository to this view
- Select the local repository that you have cloned earlier
- Pull
- Go the the Java Perspective
- Right click on the project -> Team->share project
- Select the repository added to the view earlier
- make changes
- select unstaged changes and add to staged changes
- write commit message
- commit and push
Assume that your teammates have created some project starter for you
- Clone a repository into the local device (can use GitHub Desktop to do it)
- in Spring Tool Suite, Git perspective
click on add an existing local Git Repository to this view
- Select the local repository that you have cloned earlier
- Pull
- right click project in the Git Explorer ->Import Maven project
Once you make some changes to the code and want to upload:
- commit as many times as you want
- push/push upstream, if there is an error, pull then push/push upstream