Earlier we had a discussion on Overview of Git-Pane in WebIDE where we discussed various capabilities of Git Pane present in WebIDE.
Steps to be followed for sending changes made in WebIDE to GitHub:
- Branching: Decide which Branch you want to use for making changes. It may be a fair idea to use ‘feature’ branch than using ‘master’ branch directly. Create a branch if required for making changes. Branching is discussed in further part of the tutorial.
- Make changes: Start doing changes to various files and save them one by one
- Staging: On save, files start appearing in Staging table
- Once changes and saving files are complete, Click “Stage All” to commit all files
- Or Click individual checkboxes in front of files for selective commit
- Click Discard if any file change is not required and you want to retrieve old code
- Provide appropriate “Commit Description“. This is mandatory for Commit/Commit and Push operations. If ‘Amend changes’ is selected, Commit description is automatically fetched from the last commit.
- Amend Changes: It is a good practice to regularly commit local changes similar to the “Save” we do in any programming language. If we do commit to the same Project, again and again, it is good to mark “Amend Changes” as it creates a single snapshot to be Pushed to GitHub.
- Commit: Commit creates a snapshot to be pushed to GitHub for synchronization. This also removes staged files and adds them to the same snapshot.
- Push: Push replicates the Commit snapshot to GitHub. Push operation may give an error in case of discrepancy.
- Commit and Push: This button does Commit as well as Push in one shot. If any error is expected during this process, it is suggested to do Commit and Push separately as it gives a better idea of error tracing.
- Validation: Files are now replicated to GitHub. Open your GitHub account to verify the replication.